I know how to do this in SQL but I must do it from C#. The DataTable is actually in memory (an xsd).
So I have some DataSet called "Converted" and in it is a Table called "Results" which has a relationship with another table called "Descriptions".
I am converting some data (thus the name) to an in memory table I have created. The problem is that I need the Primary Key of the "Results" last insert in order to populate the "Descriptions". How can I get the last inserted primary key?
The bellow code shows what I am doing. In the section Descriptions is where various paramaters from the raw data are then combined into multiple entries into the Descriptions table. I ofcourse need to link them back to the current row I am processing.
What sort of answer is that, he can have regions inside a method (NOT), how about nested regions and regions from the middle of one method to the middle of another method. I must admit I have never seen regions used inside a method
Never underestimate the power of human stupidity RAH
i m getting bezier approximation of ink stroke using stroke.GetFlattenedBezierPoints()where method is get flattened points. i do not know whether the method is using quadratic bezier approximation or cubic bezier approximation. is it possible anyway to find out the method used by microsoft. thanks
I'm trying to build a pop-up graph in c# using this.NotifyIcon.BalloonTipShown but it doesn't execute in Windows 7 . Is there any alternative way to open a form when the user hovers the mouse over the icon and close the form when the mouse is moved away ?
Im using the code below
//// NotifyIcon//this.NotifyIcon.BalloonTipIcon = System.Windows.Forms.ToolTipIcon.Info;
this.NotifyIcon.BalloonTipText = "RapidNAS Warez Made Easy ...";
this.NotifyIcon.BalloonTipTitle = "RapidNAS";
this.NotifyIcon.Icon = ((System.Drawing.Icon)(resources.GetObject("NotifyIcon.Icon")));
this.NotifyIcon.Text = "RapidNAS Warez Made Easy ...";
this.NotifyIcon.Visible = true;
this.NotifyIcon.BalloonTipClosed += new System.EventHandler(this.HideGraph);
this.NotifyIcon.BalloonTipShown += new System.EventHandler(this.ShowGraph);
privatevoid LaunchDownloadStatus(object sender, MouseEventArgs e)
Popup form = new Popup();
privatevoid HideGraph(object sender, EventArgs e)
I have a connectionstring that is a Application setting and not a user setting. I want the user to be able to change this, but the datasets seem to want an Application Setting. IS there a way to programmically change this setting?
Well, in XDocument, ToString() is overloaded to give you the XML string representing the document, so I think the answer is yes. If you want to remove unnecessary white spaces and carriage returns, you should use xDocument.ToString(SaveOptions.DisableFormatting);
You should also have a look to the Save() method, that can write the XML on a more general target (a file or a stream).
I'm looking for a simple tool to replace MSMQ, mainly because of the centralized, single point of failure nature of MSMQ. Currently, we have a web server farm and some of the sessions will have to communicate through MSMQ. The problem with this is that if the machine where the queue is defined is down, the messaging stops. Can anyone recommend a tool that is distributed among the servers so that I can send a message to a queue and if a session on another server is listening it will receive the message? The idea is not to be sending a message to a machine based queue such as in MSMQ, but more of a virtual queue that is alive as long as something is listening on it. I was hoping to find something like this so we don't have to write one ourselves.
I don't know if it's the right forum but it seems to me the most appropriate. I have an application developed in C# (VS 2005) that work fine on Windows XP. The application used the TFTP.exe installed on Windows. now I moved to Vista and discovered that TFTP.exe is not installed by default and some configuration are required. My question is: Is it possible to detect (when application setup is running) that the TFTP.exe is not installed and to install it during the setup of my application (to avoid the user to do this manually)? If yes, how can I do that?
Seems that it's a part of Windows itself. Windows XP would require the user to have his/her installation-media at hand - because your changing the configuration of the Windows-installation. I don't know if Vista has the same requirement.
In short; it's not a setting (it's not comparable to the screen-resolution setting) but a feature that may or may not be installed.
I am developing a C# application to send SMS using SMPP server and SMPP port that I took before from an sms service provider. I am looking for a API or a dll file. Can anyone help me? It is really important. It must also send sms to multiple recipients.
I have a problem, I have created app in Visual Studio 2008 in XP windows, with framework 3.5 but when I launch it on Windows Vista it dosent start. I get the Application Recovery screen. On XP is no problem, everything works.
I am re-posting this question with some more detail.
In my windows application I am using 'Zedgraph' dll for displaying graph. In my code I am not using multithreading anywhere. On some of the systems (Windows XP) it shows unhandled exception 'System.InvalidOperationException' (object is currently in use elsewhere). And the instead of graph it just shows RED CROSS.
At client side network, if the user is an Administrator then the application runs fine. But if the user is not an Administrator then after few seconds above error is being observed. That means non-admin user can view the graph only for few seconds during starting of the application. Any idea...
I have googled about this issue but I found that it may be due to Multithreading and I am not using it anywhere.
we often create a winform manually(project-->add-->winform),the created winform is template, then we create an instance of this winform with "new" word. Now I want to know how to create a new winform with code and have not template winform of this new winform(that is no need create a template winform by manually first).
there is no magic involved: all that Visual Designer does is put some code in a file called myForm.Desisgner.cs; you can open that file and have a look; then create similar code in your own file (don't edit the designer.cs files, your changes may get lost, and might confuse Visual Designer).
Luc Pattyn [Forum Guidelines][My Articles] The quality and detail of your question reflects on the effectiveness of the help you are likely to get. Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
i waz working on a c# project on windows 7......... when i run or debug the code ...... and if there is a compile time error, it will display the errors...........but after i correct this errors.......there will be a permanent error which says..........."Cant find C:\......\\ProjectName.pdb access denied".....pdb=program debug database.......but this error disappears only if i restart my laptop........ so please help me ppls....which save my time rather than restarting my pc if some error happens....tnx
This generally happens when you make changes to your code when the application is running in debug mode. Since the code has been modified, VS block access to the pdb file and you get a access denied to the .pdb file.
You have the following solutions to this problem 1. As Hariharan had said, do a Rebuild of the solution. This in most cases clears the lock on the pdb file. 2. Locate the pdb file using the windows explorer and delete it and then try build/rebuild from the VS. If you get file is being used error, check if there are any process that are using this file still running using the task manager / process explorer and kill it and re-try. 3. Do a build/rebuild of the solution in "Release" mode and then do a build in "Debug" mode. Not sure if this would work for C# Win Forms, I've done this only on my Web apps.
I had this same problem with Windows 7 beta, the problem was intermittent and I'm not sure what was causing it. Do you run Visual Studio as administrator? The problem seems to have been solved since Windows 7 release candidate.
I have a simple C# exe. It internally has some calls to custom interop. I dont have any problem in executing it manually by either double clicking the exe or thru command prompt, everything works as expected. But the moment i launch it using windows scheduled task it always fails.
Is this a know problem with interop calls, when an executable runs thru scheduled task? it fails at the point where i make a method call on the interop object. BTW i am using W2K.
Thanks in advance....
Last Visit: 31-Dec-99 19:00 Last Update: 23-Jan-17 3:05