Results 1 to 8 of 8

Thread: Forms scope (resolved)

Threaded View

  1. #1

    Thread Starter
    Still learning kebo's Avatar
    Join Date
    Apr 2004
    Location
    Gardnerville,nv
    Posts
    3,762

    Resolved Forms scope (resolved)

    Hi all,
    I am having difficulties with form scope in my project. I have a main form that spawns a few indentical children form's (I use the term children loosely as the main form is not MDI.) The main form also spawns 2 forms ("Global1" and "Global2") that need to be accessed by the children and in some cases forms spawned by the children (grandchildren) and forms spawned by them (great grand children.) Each of the children counld reside in sepparate class libraries. My question is about setting a refence to the Global forms. If I invoke the Global form at the top of Mainfrm like this
    VB Code:
    1. Public Class Mainfrm
    2.     Inherits System.Windows.Forms.Form
    3.     Public GlobalOptions As New Systems_Class.GlobalOptionsStruct
    4.     Public StrategyManager As Strategies.ManageStrategiesfrm
    do I need to continually pass a Mainfrm reference to every subsequent child, grand child and great grandchild, or is there a way to declare the global forms globally and avoid the references

    Any input will be appreciated
    thanks
    kevin
    Last edited by kebo; May 12th, 2005 at 08:20 AM.
    Process control doesn't give you good quality, it gives you consistent quality.
    Good quality comes from consistently doing the right things.

    Vague general questions have vague general answers.
    A $100 donation is required for me to help you if you PM me asking for help. Instructions for donating to one of our local charities will be provided.

    ______________________________
    Last edited by kebo : Now. Reason: superfluous typo's

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width