471,334 Members | 1,398 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,334 software developers and data experts.

Control breaks when calling it from another class

I am trying to contola progress bar on a form from a method that is
located in annother class.
when I try and instantiate the form
Form1 frm = new Form1;
frm.ProgressBar1.PerformStep();

I get an error message "An unhandled exception of type
'System.StackOverflowException' occurred in WWEmail.exe"
It breaks at this line - Form1 frm = new Form1;

Dec 28 '05 #1
1 1109
Form1 frm = new Form1;
That shouldn't even compile. Please post your actual code.

I get an error message "An unhandled exception of type
'System.StackOverflowException' occurred in WWEmail.exe"
It breaks at this line - Form1 frm = new Form1;


Is this code inside (or in a method called from) a Form1 constructor?
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Dec 28 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by threecrans | last post: by
2 posts views Thread by John Lau | last post: by
4 posts views Thread by louise raisbeck | last post: by
5 posts views Thread by paul.hester | last post: by
11 posts views Thread by Brad Baker | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.