Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
OpenModalForm parameters
Message
De
16/10/2002 15:14:54
 
 
À
16/10/2002 14:57:21
Information générale
Forum:
Visual FoxPro
Catégorie:
CodeMine
Divers
Thread ID:
00711542
Message ID:
00711915
Vues:
12
>I think I need to take another approach to this. I think what I need is a global Crystalreports object that exists independently of any form.

Well thats a design decision you will have to make. However, see my reply to your initial response for an alternative.

Best

>
>Thanks anyway:
>Mike
>>Gary:
>>Thanks for your response.
>>I'm trying to instantiate a frmModalDataChild form using the parent forms OpenModalForm method. I want to pass an object created in the parent for the child to use.
>>My calling code looks like this:
>>
>>WITH Thisform
>>	loReport = .CrystalReports.OpenReport(.cReport)
>>	.openmodalchild('frmCrystalViewer',loReport)
>>Endwith
>>
>>
>>The init of the child form already has a lparameter statement with oCaller.
>>When I add oReport in the hope that this will receive the object it evaluates to .F. I have a feeling that it is my understanding of parameters that is faulty here.
>>
>>>Hi Mike:
>>>
>>>>The OpenModalForm passes additional parameters by reference to the init of the child form. What does the code look like to receive those parameters?
>>>
>>>The first argument is the class name or the form name you actually want to open. The second and subsequent arguments are passed to the form or class Init method (as specified in the first argument). So ...
>>>
>>>
>>>cmStateManager.OpenModalForm('MyForm.scx', 'Hello', 'World')
>>>
>>>
>>>Then, in MyForm.scx ...
>>>
>>>
>>>Function Myform.Init(tcParm1, tcParm2)
>>>   *-- Do what you want with the parameters.
>>>   this.cMsg1 = m.tcParm1   && Receives "Hello"
>>>   this.cMsg2 = m.tcParm2   && Receives "World"
>>>Endfunc
>>>
>>>
>>>HTH
>>>
>>>Best
-=Gary
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform