|
In this case it would be better, to take UserControls instead of Form1 and Form2.
1)MainForm creates the instances of panel1, panel2, UserControl1 and UserControl2.
2)Than place the panels at your Mainform.
Mainform.Controls.Add(panel1);
.....
3)place the Usercontrols in the panel you whant.
Mainform.panel1.Controls.Add(UserControl1);
4)In your case it could be possible to Use the 'Dock' Property of panel (Mainform.panel1.Dock = DockStyle.left;)
5)And 'Dock' for the UserControls as well (Mainform.UserControl1.Dock = DockStyle.Fill;)
Hope that helps you!
All the best,
Martin
|
|
|
|
|
Thanks.
I have no idea how controls work, will look into it.
still learning the language.
He who laughs last is a bit on the slow side
|
|
|
|
|
I'm putting on-line help into an application. What is the best way to compile a help file. I looked at Microsoft html help compiler, but it doesn't let me add word documents so I would need format everything into html. Ideally I just want to add my word documents. Thanks.
|
|
|
|
|
Couldn't you just save the Word document in html format and use that?
Glen Harvy
|
|
|
|
|
I think that will do the job, although I'm not sure if that will enable you to build an index and get hyperlinks in the help file...
WM.
What about weapons of mass-construction?
|
|
|
|
|
I want to develop a distributed architecture in .NET. The working of this architecture will be as follows:
Users will log in to the site, and voluntarily allow their Processor Cycles to be used, when ever it is free. For this the Users will have to download a component from the site, and this component will get installed in their PC.
This component will communicate with the Central component, which will distribute the tasks to the Users. This component will perform the assigned tasks, whenever, the User's processor cycles are free.
I have read about these architectures being implemented with VC++.
So I would like to know your comments regarding this, and how this architecture can be implemented in .NET(C#).
|
|
|
|
|
What you need is some kind of webservice that organizes the functionality of the server. The client computer can than invoke a method on the webservice to get a new job. To increase availability you will have to save the job on the client, so that it is still available after the client is shutdown. This also enables the client to send the results of the job back to the server at a later time, in case the server is down when the job is first done...
I have no idea how you can build an app that only uses idle cpu cycles, but this could be a general idea for the communication part of the solution.
The only difference with the VC++ solution is that these solutions make use of their own communication protocol, while the .NET solution typically uses a webservice.
WM.
What about weapons of mass-construction?
|
|
|
|
|
hai all,
is it possible to change the language of messagebox button..
for eg:
MessageBox.Show("hai", "MSG", MessageBoxButtons.YesNo);
can we change the language(german,french..) of "YesNo" . i.e while installing if we select the lanaguage as german is it possible to display the yes /no button of the messagebox in german..
Rohit
|
|
|
|
|
Hi,
The text on the messagebox i guess depends on the Operating system,
I had created an application, but when that app was executed on a Japanese XP OS the messageboxes displayed Yes/No in Japanese language by default.
Regards,
Pramod
|
|
|
|
|
Have a look at the System.Globalization namespace.
HTH
Jonny
|
|
|
|
|
Hi, I have a third party control DatePicker, it seems to work well in Internet Explorer but when I use Firefox it doesn't display anymore.
Is there a workaround here?
Thank you.
Gerri
|
|
|
|
|
Compare the Html source of your page generated in IE and Mozilla.
|
|
|
|
|
They're the same. But it just doesn't display in FIrefox
|
|
|
|
|
Hi Guys,
I need to write a C# program which should
1. Connect to SQL Server Database
2. Run a query
3. Publish the query results in a nice html page
4. Send the HTML page as attachment by email.
I'm VB programmer totally new to C#. I would appreicate any sort of help to achive the above task.
Thanks.
FIFA - Go Argentina
|
|
|
|
|
What parts of doing this are you having trouble with?
|
|
|
|
|
I am looking for a sequence of code that will retrieve the current selected text from any active window in the system.
For example if I select a paragraph in a Word document or Excel or IE and I run this code, it will capture the selected text.
Any help or direction will be greatly appreciated.
Thanks
|
|
|
|
|
I've done a tbAdapter.fill(DataSet.datatable);
How do I edit the datatable through code? I need to be able to add new rows to the table and I'm having trouble figuring out how. Anyone have a guide that demonstrates this though code? (IE, no interface for background processes).
-- modified at 19:59 Thursday 29th June, 2006
I dont understand how to use dataSet.DataTable.addTableRow() if anyone cares to explain this to me (if it is what I'm even looking for).
Thanks again.
|
|
|
|
|
Adding a row to the table is really quite simple. You are looking for datatable.NewRow();
To add a new row you would do something like this:
DataRow newrow = datatable.NewRow();
row[0] = "blah blah blah";
row[2] = ...
...
dataTable.Rows.Add(newrow);
Basically it creates a new row based on the columns that you have in the already constructed table.
You can also set values for different columns in the row like:
row["SomeColumn"] = "blah blah blah";
Thats really all there is to it
Hope that helps.
|
|
|
|
|
Thanks! worked like a charm...
|
|
|
|
|
I have a ConstextMenuStrip. It have 3 items that are Test1, Test2, Test3.
But i dont know how to catch event for three items.
Example.When i click on Test1, it raises a message "I love you"
Please help me.
Thanks alot
superdragon
|
|
|
|
|
Assuming you're using vs2005, please follow these steps:
1) Select one item
2) Go to property panel->event tab (that has a lightning icon)
3) Select a click event and double-click on it
4) Go to the source file and fill in the handler function body.
Best,
Jun
|
|
|
|
|
Thanks a lot, now i see how to do with it
superdragon
|
|
|
|
|
Ok. I have an app in C#. It uses a com object in main thread. Then there is a button which calls a method in that com object that takes a long time. So I added a thread (backgroundWorker) which calls that function on that COM object. Trouble is that while the worker thread is working the main still is not responsive! Why is that?!
Please help!
|
|
|
|
|
It will be easier for people to help if you post some relevant code snippets.
Josh
|
|
|
|
|
When you refer to your main thread are you meaning that the GUI is unresponsive? If that's the case then you need to use BeginInvoke from your second thread that calls a method on your main thread that updates the GUI. I am not an expert, but I have implimented it serveral times. I still sometimes have to refer to previous code. Check CP for articles on updating your GUI. This is where I found my information.
www.lovethosetrains.com
|
|
|
|