|
You can either
1. Set the context menu individually for each node rather than for the entire treeview
or
2. Set the nodes tag property or something to indicate whether it should display the treevies's context menu (Or create your own and inherit from System.Windows.Forms.TreeNode and add a boolean property) and check that value in the events that fire before the comtext menu is shown to disable it.
|
|
|
|
|
In my project i use the system trace to trace error log.
but do someone help to know where is the path of the file that contain this trace.
best regards,
dghdfghdfghdfghdgh
|
|
|
|
|
The debug messages are sent to the Output window (Debug -> Windows -> Output) by default. If you want to capture those trace messages to a file, you will need to create a TraceListener and add it to the Debug Listener collection.
TextWriterTraceListener myTrace = new TextWriterTraceListener(File.CreateText(@"c:\Output.txt"));
Debug.Listeners.Add(myTrace);
|
|
|
|
|
Hello
I have the following problem. When I start my program I create an OleDbConnection to a DB2 and use this connection for different requests. But after about 8 minutes I get the following error: "OleDbException System.Data.OleDb.OleDbException: [DB2/6000] SQL0551N "xxx" does not have the privilege to perform operation "EXECUTE" on object "NULLID.yyy". SQLSTATE=42501". What does that mean???
Thanks for your help.
Greets
pkoeppe
|
|
|
|
|
For a work around I open a new connection for each request and close the connection after the request. But here the connection seems not to be closed really. The connection state is closed but the database says there is still a connection. After some request I get the error "Open Connection failed System.Data.OleDb.OleDbException: SQL1226N The maximum number of client connections are already started. SQLSTATE=57030". I don't unterstand this, I close each connection after the request. When I close my program then the connections are closed "really", what is the problem???
That's the way I do my requests:
public DataTable Request()<br />
{<br />
try<br />
{<br />
using (OleDbConnection connection = new OleDbConnection(Constants.DB2_CONNECTION_STRING))<br />
{<br />
using (OleDbDataAdapter da = new OleDbDataAdapter(request, connection))<br />
{<br />
using (DataTable dtResult = new DataTable())<br />
{<br />
da.Fill(dtResult);<br />
return dtResult;<br />
}<br />
}<br />
}<br />
}<br />
catch (Exception ex)<br />
{<br />
MessageBox.Show(ex.ToString());<br />
}<br />
return null;<br />
}<br />
|
|
|
|
|
hi i have a stored procedure which return the value of user name and i want to populate the ComboBox whit the written value how i do that
wasim khan
|
|
|
|
|
Set the display member to the name of the column you want to show, then bind to the dataset
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Do you have this working yet?
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
yes it wrok good and sory for asking thanks Sooo late
wasim khan
|
|
|
|
|
Thought I'd just drop you a line to see if all was well
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
Hello all,
i am working on .NET 2.0 DataGridView (winforms) sorting.
I want to add checkbox in the column header & i want to implement sorting also.
if i specify automatic then it was not working.
any sounds?
Ramana
|
|
|
|
|
Hello everybody,
i set the datasource of the DataGridView to an ArrayList (with Objects)
At the beginning the list is empty, then it gets a value.
So i need to update the Grid:
I set the datasource to null and re-set it to the arraylist.
The Grid has now one row, but in this case CurrentRow and CurrentCell is <null>
How can i set CurrentCell & CurrentRow to the first line?
BTW: Grid[0,0].Selected is true if CurrentCell == null
Big thanks in advance
|
|
|
|
|
hi.
I want to build an aboutBox DLL, which get any kind of project(project assembly) and show it on the aboutBox.
how do I do it?
|
|
|
|
|
You Can Easily Do it using Reflection !!!
There is a Assembly Class. Usign That you can retrive all inforamtion runtime.
You can also Check Assembly Values in Solluation Explorer > Properties > Assemblyinfo.cs
If any Query You can Ask me !!!!
Good Luck !!!
|
|
|
|
|
You can use AppDomain.GetAssemblies() to get a list of the Assemblies which have been loaded into the program.
Does anybody know how to get a list of the assemblies (dlls) which an application will use even if it hasn't loaded them yet?
|
|
|
|
|
Hi,
I am working on a windows application in which I have a MonthCalendar Control. Basically its a Reminder application. I want all the dates should be selected on which user has set reminder. if I have set reminder for 15th Dec, 18th Dec, 25th Dec then this dates should be selected in the MonthCalendar Control.
Can any one plz let me know how can I acheive this task.
Best Regards,
Chandan Kumar Gupta
|
|
|
|
|
|
Hi,
can someone tell me why setting Console.TreatControlCAsInput = true needs two times hitting the enter button to make the Console.ReadLine work. Is this really a bug and if yes, how can i simulate a useful ReadLine function that does work?
Regards
Kerem
-----------------------
Beste Grüsse / Best regards / Votre bien devoue
Kerem Gümrükcü
Microsoft Live Space: http://kerem-g.spaces.live.com/
Latest Open-Source Projects: http://entwicklung.junetz.de
-----------------------
"This reply is provided as is, without warranty express or implied."
|
|
|
|
|
hi,
how can i write a function to check if the value is in float format?
it should return true is the value is in float format.
thanks
|
|
|
|
|
Hi,
see here:
http://www.thescripts.com/forum/thread230544.html[^]
Maybe there is something that you can use. If the build-in functions given in the .NET do not saticfy you applications need then you can try the examples given in the link above,...
Regards
Kerem
-----------------------
Beste Grüsse / Best regards / Votre bien devoue
Kerem Gümrükcü
Microsoft Live Space: http://kerem-g.spaces.live.com/
Latest Open-Source Projects: http://entwicklung.junetz.de
-----------------------
"This reply is provided as is, without warranty express or implied."
|
|
|
|
|
return (value as float?) != null;
|
|
|
|
|
float.TryParse
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hai all,
I am new to the windows service.i have one doubt in the windows service deployment .
Is it possible to create one setup project for two different service that are in one windows service project?
Thanks in advance
Regards
|
|
|
|
|
you can !!!
if you open the program.cs file you will get that info !!!
static void Main()
{
ServiceBase[] ServicesToRun;
ServicesToRun = new ServiceBase[] { new Service1() };
ServiceBase.Run(ServicesToRun);
}
|
|
|
|
|
Thanks for reply.
Is it possible to switch the service during the insatllation so that the user can take which service he want? i tried this and found error during uninstallation .
|
|
|
|