Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > C# and C > C# 1.0 > C#
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
C# Programming questions specific to the Microsoft C# language. See also the forum Beginning Visual C# to discuss that specific Wrox book and code.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C# section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old November 7th, 2006, 05:24 AM
Authorized User
 
Join Date: Jun 2006
Location: , , .
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default parent form from child form - urgent plz

hi all,

im creating a windows application in C#.net.in that,

im having form1 with listbox.

im calling form2 from form1.

in form2 i want to populate the list box of form1 and activate form1


(if i use
form1 fn=new form1();
fn.show();
---> it creates a new instance of form1.that i dont want.i want to populate the listbox of already existing form1 and activate that form)
(ie)i want to access the parent form1 from child form2.
Reply With Quote
  #2 (permalink)  
Old November 8th, 2006, 05:59 PM
Friend of Wrox
 
Join Date: May 2006
Location: San Diego, CA, USA.
Posts: 643
Thanks: 0
Thanked 0 Times in 0 Posts
Default

There is no "already existing" form1 in C# like there was in VB6. You always need to create an instance of a form before using it.

However, once instantiated you can hold the reference to that form, and use it when and as needed. Displaying it and hiding it as needed.

Woody Z http://www.learntoprogramnow.com
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Posting asp form variables from child to parent aspless Javascript How-To 0 July 20th, 2007 10:36 AM
Submitting a parent form from a child window in IE livehed Other Programming Languages 0 February 15th, 2007 12:07 PM
Reload Parent form from Child form maulik33 ASP.NET 2.0 Basics 2 February 6th, 2007 11:53 AM
Reference to parent form from child prashantha Visual Basic 2005 Basics 2 November 15th, 2006 02:54 PM
parent child form data passing maddy137 ASP.NET 1.0 and 1.1 Basics 0 April 26th, 2006 01:00 PM



All times are GMT -4. The time now is 02:32 AM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.