|
are you looking on form.show()?
|
|
|
|
|
Exually what i have are 6 forms,
and 6 buttons
what i'm looking for is :
button 1 > form 2 + backbutton
button 2 > form 3 + backbutton
button 3 > form 4 + backbutton
button 4 > form 5 + backbutton
button 5 > form 6 + backbutton
button 6 > form 7 + backbutton
button 1 when pressed opens form 2 ect.
that works with form.hide(); ? and form.show(); ?
|
|
|
|
|
I tryed to use
Form.ActiveForm.Hide();
Form2.ActiveForm.Show();
but that trows System.NullReferenceException was unhandled
|
|
|
|
|
You need to create an instance of the form you wish to show/hide, that's the exception you're seeing.
He who makes a beast out of himself gets rid of the pain of being a man
|
|
|
|
|
so i need to create 6 instanses, cause i got 6 forms?
|
|
|
|
|
yes. example,
form1 f1 = new form1()
f1.show();
hope this help you
|
|
|
|
|
it does thanks
|
|
|
|
|
Alternatively you could create user controls, one for each form you need, and populate them with the components that you need for each form and then use just one form in which you show one of the user controls and then switch it for another. This way the user controls works like different views in the same form.
/Ruben
RJJournal
|
|
|
|
|
For a project which I soon have to be involved in, we are looking to implement a graphic intensive application, but balk at using either MDX 1.1 or XNA to access the DirectX libraries. However, the development platform has to be C#. Is there any way to get to the DirectX libraries (and how on earth do use them) directly, through unmanaged calls?
|
|
|
|
|
Extrakun wrote: through unmanaged calls?
You could do, but then you'd only be doing what MDX does anyway.
Unless you are an expert at unmanged DirectX don't use it; it'll take you longer to write, be less managable, and won't really be much quicker. From personal experience it took me getting on for 100 lines of code to get keyboard input in unmanaged DirectX and 3 in managed.
On a final note, the extra cost of development will more than offset the cost of a new graphics card for the whole company if it's of any real complexity.
|
|
|
|
|
How to get the user Telephone Inputs into our C# application...??
Regards
|
|
|
|
|
Look into Interactive Voice Response applictions and maybe the Microsoft Speech SDK. They have ways to detect DTMF signals as input. You should also look into learning VXML as most of the IVR systems use that for the call flow.
|
|
|
|
|
i want to add new channel (alpha) on my png file like photoshop does. how can i do it using C#?
please help!
|
|
|
|
|
Good Morning Everyone
i have an application in VB.net and a Functionality(dll) written in C#.i have a DLL in C# Project and i have compiled my project with release and Fetch the DLL in the release folder and paste it in the VBProject. now i want to use that C# Functionality in vb project, i went to References and i tried to Add it as .NET reference and i got the following Error.
A Reference to Motherboard.dll could not be added.This is not a valid assembly or Com Component.Only Assemblies with extension 'dll' and Com components can be referenced.
Thanks
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
you c# assembly is probably not CLS compliant
|
|
|
|
|
Hi thanks for the Reply
i have created this DLL in C#.NET, and copied it to the other's application folder and tried to referenced it. doesn't Visual Studio automatically make it CLS Compliant?, because the DLL was created in VS2005 and am taking it to a Project in VS2003. is there a Problem there ?
Thanks
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
you have to add manually this [assembly: System.CLSCompliant(true)] in the AssemblyInfo.cs of your class library, visual studio is not doing it automatically
|
|
|
|
|
The DLL is corrupt, apparently. What happens when you try opening it with ILDASM?
Cheers,
Vikram.
The hands that help are holier than the lips that pray.
|
|
|
|
|
If the DLL is Corrupt, the i can delete it from the Release Folder and Compile the Problem to give me an output of a fresh DLL, then after that i do the Same thing by Copying the DLL to the VB Folder Project and go to VS and reference the DLL under .NET, still gives an Error, and do it under Com still Gives me an Error.
what wrong
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
I'm attempting to code a mini processor benchmarking program(For fun )
The problem is... Marks are always 0
marks is a global int variable
string myWord = "1234567890";<br />
StreamWriter sw = new StreamWriter(@"C:\benchMe.txt");<br />
for (int j = 0; j < 1000; j++)<br />
{<br />
sw.Write(myWord);<br />
}<br />
sw.Flush();<br />
sw.Close();<br />
timer1.Interval = 1;<br />
MessageBox.Show("Test Ready!");<br />
StreamReader sr = new StreamReader(@"C:\benchMe.txt");<br />
string bob = sr.ReadToEnd();<br />
sr.Close();<br />
timer1.Enabled = true;<br />
Console.WriteLine(bob);<br />
timer1.Enabled = false;<br />
MessageBox.Show("Marks on Test: " + marks);<br />
marks = 0;<br />
<br />
private void timer1_Tick(object sender, EventArgs e)<br />
{<br />
marks++;<br />
}
Any ideas?
I was thinking that maybe the "Lag" was canceling the increment on the timer, or something...
Any ideas, anyone?
|
|
|
|
|
have you started the timer? timer1.Start(), timer1.Stop()
|
|
|
|
|
:bashhead:
-_-
Ok, now it works (Once...)
Benchmark code modified to:
private void button2_Click(object sender, EventArgs e)<br />
{<br />
StreamReader sr = new StreamReader(@"C:\benchMe.txt");<br />
string bob = sr.ReadToEnd();<br />
sr.Close();<br />
timer1.Start();<br />
Console.WriteLine(bob);<br />
timer1.Stop();<br />
MessageBox.Show("Marks on Test: " + marks);<br />
marks = 0;<br />
}
First click displays marks, second click -> x click displays 0.
So close....
|
|
|
|
|
|
You have mentioned the timer interval as 1ms. If the interval is less than 15ms (sometimes this will be more according to the processor/hardware.) it is not going to perform correctly.
This article will explain it clearly.
Timer surprises, and how to avoid them[^]
*jaans
|
|
|
|
|
D:
Never knew that!
Thanks alot!!!
- Reelix
|
|
|
|