Article View: borland.public.csharpbuilder.language.csharp
Article #481Re: Newbe question
From: Marc Rohloff TeamB
Date: Sat, 22 Jan 2005 01:50
Date: Sat, 22 Jan 2005 01:50
25 lines
1548 bytes
1548 bytes
On Fri, 21 Jan 2005 19:12:11 +0100, Lars O. Soderstrom wrote:
> How do you refer to the main form?
Just save it in a static field somewhere.
class Startup {
public static frmMain main;
static void Main()
{
main = new frmMain();
Application.Run(main);
}
}
private void button2_Click(object sender, System.EventArgs e)
{
Startup.main.Text = "Some text";
}
--
Marc Rohloff [TeamB]
marc rohloff -at- myrealbox -dot- com
Technical Details
Message-ID:
<1e1tpld5n2og5.dlg@marcrohloff.40tude.net>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!proxad.net!194.117.148.138.MISMATCH!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<41f145f9@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 1efe35,96ed0e9698357d80 X-Google-Attributes: gid1efe35,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Marc Rohloff [TeamB]" <"on request"> Subject: Re: Newbe question Newsgroups: borland.public.csharpbuilder.language.csharp User-Agent: 40tude_Dialog/2.0.14.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit References: <41f145f9@newsgroups.borland.com> Date: Fri, 21 Jan 2005 20:50:50 -0500 Message-ID: <1e1tpld5n2og5.dlg@marcrohloff.40tude.net> X-Face: "huzh55Xi]!ZNni78>a*5+).`SK?<^q2MlHk-C]Z2M9T@\J5ZCB$95Ey+s"XQuhGFA[eutZ :0^AV!Q;t>gE`1-=8d;HZ6~*o1dH<X9\b$!|(}+I'!Xq)@3Op}%0ArW&nf'Qh*EwR NNTP-Posting-Host: 4.224.231.92 X-Trace: newsgroups.borland.com 1106358530 4.224.231.92 (21 Jan 2005 17:48:50 -0800) Lines: 25 X-Authenticated-User: mrohloff Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!proxad.net!194.117.148.138.MISMATCH!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail