Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Cascading 1-many form
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
CodeMine
Divers
Thread ID:
01049589
Message ID:
01049694
Vues:
12
Hi Larry,

Make sure you haven't got the "lReleaseOnClose" property of the form set True. If you have, the form will be released automatically when it closes and therefore oDialog will be NULL by the time you try to call the ReturnValue() method of the (released) dialog form.

HTH

-=Gary

>Hi, Gary;
>
>I lashed this up but now have the following problem:
>
>
>Trying to create an additional 1-M data entry form, on an existing "child" form created from the formmodaldatachild class Upon running the button, the new child form comes up, and allows data to be entered, however, I then get an error message:
>=======================================
>Visual FoxPro 09.00.0000.2412 for Windows [Dec 13 2004 11:21:37] Product ID 76683-335-3957236-18390 CodeMine 8.0.B3 Error #1924 in Click line 9 "m.lStatus=m.oDialog.ReturnValue()"
>ODIALOG is not an object.
>
>Call Stack:
>2 Frmcgoal.Cmdnewdtl.Click (source\appforms.vct)
>1 Frmperson001.Pgfperson.Page6.Cmdeditdtl.Click (source\frmperson.sct)
>
>======================================
>
>Since the calling form is itself a child form, I'm wondering if the variables are stomping on each other, Based on the error message; oDialog does get instantiated, but then for some reason seems to be changed to .null.
>
>
>Here is the code in the [new] button which generates the above error
>
>PRIVATE oCallingForm
>m.oCallingForm=THISFORM
>
>LOCAL oDialog
>
>THISFORM.cmDataManager.New('lrnObjective')
>m.oDialog = CREATEOBJECT('frmclrno', THISFORM)
>m.oDialog.SHOW()
>m.lStatus=m.oDialog.ReturnValue()
>
>IF m.lStatus=.F. && User didn't want to add this record after all
> THISFORM.cmDataManager.Delete('lrnObjective')
>
>ENDIF
>
>
-=Gary
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform