Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IS THIS AN EASY ONE?

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
0
0
I have two forms, a main one and a summary. The main form have a
label called amount due and text box called trade.

I need to show the results of the amount due label and the trade text box on the second form called summary.

I have to use a module and declare amount due and trade as global.

Please can you help me?

Thanks


 
If the main form is called frmMain then you could reference these controls from the summary form:

When the summary form opens you could in the load event, for example, set controls on that form to equal the values on the appropriate controls on the main form

frmSummary.label = frmMain.label
frmSummary.trade = frmMain.trade
 
Seems to me like you are referencing common values here.
You could actually declare variables in a basic module and have the forms in your project use/reference the values rather than pass them directly like
frmSummary.label = frmMain.label
 
Hi,

Another way is to create a property in your summary form to hold the value of the trade textbox and another property for tbe label. You can then assign the values into these summary form properties.

Have a good one!
BK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top