How to keep the tree node sort order when adding/inserting node to a treeview...
Recently I was working on a treeview, which has a customized TreeViewNodeSorter. I found I could not keep the original tree node order if the TreeViewNodeSorter presented. I'm wondering how I code this...
View Articlemultiple partial class files cause problems with forms designer
As an experiment I've decided to try splitting Form code (event handlers and the functions they use) across a number of partial classes for my main Form, essentially placing the code supporting a...
View ArticleControls disappear from a form although they are still in the Designer code
I've tried searching for this problem but how do you describe it in search terms? I hope this rings a bell as I do not have a way to present a short code sample to reproduce it.I have a windows form...
View ArticleHow to debug Excel Addin project?
Hi,I have my application that basically designed in the VS 2008 that has VB project include along with the C# project. But i am using VS 2010 to run this application. And my application acts as an...
View ArticleI have a problem with painting controls in a contained Windows Form control.
The situation is this - I have a tabbed page control on a main Windows Form which is used as the main workspace for my application. Each tabbed page, which represents an open file, is created from a...
View ArticleMdi background image changing problem
Oh Come on! it just doesn't make sense!I'm ready to die to get the my MDI container background image changed!I just cannot believe none of the articles on the net does not work!Can anyone please tell...
View ArticleSendInput to a specific window
Hi, I have target window handle (ID), how I can generate mouse event such as (click) to specific location on that window, can use SendMessage ?, how?.If I use SendInput native API, i success, but if...
View ArticleCreateUniqueMethodName - capture double click or value change in eventname
Hi, I am developing a designer at runtime. In designer I have a PropertyGrid with the properties and events. When I double click an event, it generates the method name automatically. I need to open...
View ArticleRichTextBox Find the text and Highlight all text
Hi I am using RIchTextBox and i am done with find option for it. When find is pressed it shows only first find result .. i want it to Highlight all the text which are with that find text in the...
View ArticleRegistry key for default browser
Hi,I have an application that checks for the default browser in the registry key [HKEY_CLASSES_ROOT\http\shell\open\command]. I've seen on one computer where this key where gone and this caused my app...
View ArticleWhy is NMHDR.code always 0 for Virtual ListView messages on Win7 x64
I have the following C# code on Win7 64bit, Visual Studio 2008. The class is to implement a virtual ListView. protectedoverridevoid WndProc(ref Message m) { bool bHandled...
View ArticleKeeping a Windows Form dynamic at runtime
Hello All,I could use some advice, for I've been trying to solve this issue for a long time and with multiple Windows Forms.How can you keep a Windows Form dynamic and visually/audibly changing (e.g.,...
View ArticleHow to get name of file, currently open doucument applicationc in C#
Hi Friends!! I am beginer to C#. I am developing Password Pro application in that i want to automatically detect the password of currently opened file application from access database file . Generally...
View ArticleChange Images from within a loop
Hi All,I have an interesting idea where I am using a windows form(C#), in that form I have some controls, based upon some criteria, in the code, I have a for loop, what I want to do is change an image...
View ArticleA Custom Context Menu for Selected Text (in a TextBox) And Only For Selected...
I want to have a custom context menu for selected text in a TextBox. So, if text is selected, then when a right mouse click occurs within the selected text I want my context menu to appear. If the...
View ArticleCan I add windows media player in a commercial c# application ? what are...
is windows media player control free to use control in commercial applications ?If not what sort of costs are involved ?
View ArticleHow to determine if the horizontal scrollbar is visible in a listview control...
I am having difficulty trying to determine whether the horizontal scrollbar is visible in the listview control.I have tried using:foreach(c in Listview1.Controls) If (c.GetType() Is...
View ArticleHow can i color in Red also another text from the string in the listBox?
This is the code now:publicstaticvoidColorListBox(List<string> data,DrawItemEventArgs e){string url = data[e.Index].Substring(0,5);string keywords = data[e.Index].IndexOf using (Font f...
View Articlejit debugger
THIS ERROR HAS TAKEN A GOOD AMOUNT OF TIME.THE PROGRAMME WORKS FINE ON MY COMPUTER BUT IT SHOWS IMAGES INSTEAD OF COMMAND BUTTON TEXT ON 64 BIT WINDOWS 7 COMPUTER.IT WORKS FINE ON THE SYSTEM ON WHICH...
View ArticleChange text in other form
I have two forms for my app. I use this for form2 to get stuff from form1 Form1 owningForm = (Form1)this.Owner;Too open form2 i use this in form1Form2 f2 = new Form2(); f2.Show(this);But when i try to...
View Article