cherilync's Q&A profile
Visual Basic Printer Compatibilty Power Pack Source or PrintDocument Interface
Someone already asked for the source code. It would be great if you could release the source code. But if it is not possible, maybe you can open some internal objects like the internal PrintDocument Interface, so we can further influence the printing process! Is this possible Hi Mike, If I understand you correctly, you want to print to the Microsoft XPS Document Writer. Then, I can use below code to print the form background image to that printer. Dim printers As New PrinterCollection Dim printer As New Printer Dim p As Printer For Each p In printers If p.DeviceName = "Microsoft XPS Document Writer" Then printer = p End If printer.PaintPicture( Me .Back ...Show All
SQL Server Recovering from Deadlocks: retrying the query
I'm having some deadlocking issues in my ASP.Net 2.0 web application with SQL Server 2000. One solution I've come across involves catching the the deadlock error (at the application level) and then retrying the query again, in the hopes that whatever was causing the deadlock is no longer locked. I've tried to implement such a solution, where I catch the deadlock exception, then try to execute the same query again. Only now I'm getting a "The transaction is in doubt" exception. So am I going about this wrong Am I supposed to retry the entire transaction, or is valid to just try to redo the one query that it failed on Is there some way around the transaction being in doubt You should determi ...Show All
Smart Device Development Prevent standby/keep app running in standby?
Hi All I'm currently writing my diploma thesis and as a part thereof i am writing a WM based application to constantly log some data (various sensor input via Serial, picture capturing, audio recording and GPS via Bluetooth) which will later on be used for some data mining/context awareness stuff. It is absolutely crucial that i have a constant stream of incoming data that is not interrupted by e.g. standby, be it system or user initiated... And that is exactly where i am stuck now... :-( Does anyone know how i can prevent my wm 2005 PPC device from going into standby, even if the user clicks on power off button However, if this is possible, will the keys and the touchscreen still be locked (not a must, but would be nice) (Btw.We ...Show All
SQL Server Select Case, Custom Code to Select Field
Hi, I am moving from Crystal Reports to Reporting Services and need a bit of help with a Profit and Loss Report; I have a table in my accounting software with the following fields: Account Name, Balance01, Balance02, Balance03,..........Balance12; I am writing a monthly profit and loss report; I've created a Report Paramater called "Month" I want to the user to select the month they want to run a Profit and Loss Statement for; Where January would be Balance01, February Balance02 etc. I have written the following custom code: Function Balance(Month as String) Select Case Month Case "January" Return Fields!BalanceThis01.Value Case "February" Return Fields!BalanceThis02.Value End Select ...Show All
Visual Studio Express Editions Making Drawing.Color by seting RGB values
Hello, I'd like to know how to configure new System.Drawing.Color by seting RGB values. I need to make color from 3 ASCII converted chars. Following: sam = 115, 97, 109 to clolor is color.r=115 color.g=97 color.b=109 then I can set to the bitmap pixel with color made that way Now the only problem is, that r,g,b parameters are only readable :/. Is there any way to SET values of color.r, g & b You should try to get R, G and B values in a different way. All colors have those values so you can get them by doing this: txttext.Text = System.Drawing.Color.Black.R In the same whay you can get G, B values. Instead of R there must be G or B. There's also A which means Alpha, but it's no ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Drawing a primitive without a texture
I am trying to draw a masking square in front of my application's display. The display uses VertexPositionTexture format vertexes. I was hoping to draw the square using a VertexPositionColor vertex, but it looks like Vertex types cannot be mixed on a single device. While I can create a single-color texture in code and throw it on the square, it looks pretty bad when it expands. A very noticable ring appears around the edges. Without a texture, it will not draw while TextureEnabled is set to true. Is there a means to draw a primitive without a texture when using VertexPositionTexture Whenever you want to render a primitive with another type of Vertex Format/Declaration you will need to set the vertex ...Show All
Visual Studio Express Editions No RX Data problem
Hi, I'm having a little trouble with my serial data program, it only works whilst there is data coming in. I am sure that I require something between opening my port and setting my variable = comport.readbyte, can anyone suggest the short statement required I thought maybe a do loop and something which looks at the port and allows it to continue if there is incoming data but I don't know the functions Many thanks, do you think you might be able to give me an example of the code required as the help in VB 2005 Express isnt very helpful ...Show All
Smart Device Development Receiving SMS Problem?
Hi, I want to give notification for received messages through my applicaton. I tried the following code which did not work on all emulators. . using Microsoft.WindowsMobile.PocketOutlook.MessageInterception; private void Form1_Load(object sender, EventArgs e) { // MessageInterceptor interceptor; // This instance will go out of scope if defined here interceptor = new MessageInterceptor(); interceptor.InterceptionAction = InterceptionAction.NotifyAndDelete; interceptor.MessageReceived += new MessageInterceptorEventHandler(OnSmsReceived); } when I run my completed code with Pocket PC WM 5.0, It works properly. But when I run with with Pocket PC 2003 or Treo7 ...Show All
Visual Basic Adding root and child treenodes
Hi, i'm a little confused with this subject. i'd like to add nodes to a form where the root nodes are my section code and the child nodes all the items under my section code. i'm retrieving this from a database so my code is something like this: while reader.read mytreeview.node.add(reader.getvalue(0).tostring()) end while that's just the main node, any code you can share for the child thanks a bunch dave. Hi, hmmm i've solved the problem. it turned out to like this: root: tviev.nodes.add("root node") then for the child it was: tview.nodes(0).nodes.add("child") and for grandchild: tview.nodes(0).nodes(0).nodes.add("grandchild") looks the same with yours but longer lol. i was using for loops f ...Show All
Windows Forms Running ClickOnce app clears DOM document object in IE7
Hi, I have a javascript method that launches a ClickOnce application from a portal front page in our web application. It does this by launching the *.application file. The Launching Application window comes up as expected and the application launches fine. However, once the application is launched, the "document" object is set to "undefined" in the containing web page. This has the effect of rendering any javascript that needs to access the document object useless, and the user can not continue to use the portal page. No javascript is running after the application has been launched. This only happens while using Internet Explorer 7. Does anybody have any idea why the document object is effectively being clea ...Show All
Visual C# Advice Troubleshooting Memory Leaks Using PInvoke
I have made an application in C# that uses a lot of PInvokes to the Win32 that create shared memory using VirtualAllocEx and more. I have a pretty bad memory leak now. Surprise! I have no experience dealing with this problem. What is the best way to find memory leaks in NET Or do i simply try random things and cross my fingers Basically, manually trace through everything you do to that pieve of memory, and make sure that nothing in your code will cause it to leak, or somehow be overlooked by your deallocation code. ...Show All
Visual Studio Team System Feature request
When importing database schema from an existing database, it would be nice if the file names were prepended with the schema name (e.g., dbo.<tablename>...sql). I have a database with multiple schemas, and some of the objects in various schemas share their names. As a result, the files/directories in my project become difficult to organize (think about AdventureWorks db - i have a similarly organized db) Another feature that i think is missing, is scripting out custom error messages. If you have particular error messages registered using sp_addmessage, those error messages do not become a part of your project. Diagrams and Intellisense would be high on my list of requests as well, but i know they're not going to happen in this ...Show All
Visual Studio Tools for Office Word 2007 exception - elements and attributes in restricted namespaces are not allowed
I am getting an error when trying to open a docx with an xml schema attached. It works on two pcs but not a third and I am trying to troubleshoot the issue. Word displays that: ' The Microsoft Office Open XML file <docname>.docx cannot be opened because there are problems with the contents.' Details: 'Elements and attributes in restricted namespaces are not allowed' Location: 'Part: /word/fontTable.xml, Line: 2, Column: 158' Thoughts Hi Bart This forum is not for supporting Office 2007 beta questions. Office 2007 is only on-topic when VSTO 2005 SE beta is involved. There is no official on-line support for Office 2007 beta, but you can get discussions going in the newsgroups in this ...Show All
SQL Server Unlock account from Management Studio does not work!
Hi, I recognized that I cannot unlock an locked account with Managament Studio for SQL Server 2005 SP1 (Login properties). I need to use 'ALTER LOGIN'-command from a query window. I found old forum entries mentioned the same problem. Is there a time frame to fix this problem Maybe in SP2 or SP3 Wolfgang Kunk Hi, you are right the way you do it. But I had the strange behaviour when I execute ALTER LOGIN ... ENABLE from a query window and the login was locked out (not disabled). Wolfgang Kunk ...Show All
Smart Device Development How to display Open Folder dialog ??? in smart app
How can I display the Open Folder dialog in Win32 Smart Device project is there any function to do it Gurgen There is no class OpenFileDialog in win32 API, I think this is a .NET Framework class I don't need it. I've tryed to use SHBrowseForFolder function, but some error occured during linking unresolved external symbol SHBrowseForFolder referenced in function "void __cdecl ...... I've added the lib Ceshell.lib, but no changes, error still remains. Anybody please help me...:( ...Show All
