Assuming you are using Visual Studio.NET, open the solution explorer and right click on the "references" folder, select the "Add reference" menu choice, then click the browse button. Browse to your .DLL file, and click "OK". That will add a reference to your .DLL to the project. From there, just add a line at the top of your source file like this:
Who needs cyberspace when you have CP space?
I had a problem where I created an app that would not run on another system which didn't have VS.NET installed.
As long as the target machine has the .NET framework installed, you should be good to go. Ensure that the framework version on the target machine is the same as the one you compiled your application to.
I've got a semi working solution, tell me if i'm doing anything that could lead to problems later.
Form1 form = new Form1();
publicclass Form1 : System.Windows.Form
this.Visible = false;
This creates the notifyIcon in the system tray, but does not show the form. When the notifyIcon is double clicked, then the form pops up. When the form is disposed, i have it call Application.Exit() so that the Application quits properly...this is mostly what i'm concerned about, that the tread is terminating properly.
"If you can't beat your computer in chess, try kickboxing"
There is a property called AutoScrollPosition which contains the offset of the scrollwindow. I guess you have to manually account for this all the time...
But I really don't know cause I have the same problem.
you can do it through OnMouseDown (or OnMouseUp). That events have MouseEventArgs parameters X, Y which you can use in ListView GetItemAt method. GetItemAt gives you the clicked ListViewItem. And thanks to Index property you can obtain the column.
Hope it helped.
I have a panel with controls on it, that i want to draw to the printer. the controls consist of smaller panels with text inside them, and listboxes with lines of text inside as well.
(class diagram editor)
Now the problem is that when I print this i scale it to fit to A4 (or whatever specified) paper size. No problem scaling a simple bounding rectangle to the textboxes and listboxes, but now I want the text to be printed inside these components as well, so the print-out will appear as on screen. How can i fit the text into these boxes, i.e. apply a scaling to the bounding rectangle of the text?
I have thought of two things:
Either change font size until something that fits is found
Draw the text to a bitmap and scale this.
Is there any 'standard' way of doing things like this? Any suggestions?
I've made a UserContol for my app. for modifing records in my form! SO i have new, delete & ... buttons in my UserControl but I wanna fire the AddRecord, DeleteRecord & ... functions from my Form! I mean functions are in my form but I want to fire them by clicking UserContol buttons.
you can Add an custom events and delegates to your UserControl which will be trigged when user clicks button in your UserControl. In your Form you can register delegate method for the UserControl event which will be responsible for event processing.