Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Combobox causes skip in master table
Message
De
20/10/1998 01:38:21
 
 
À
19/10/1998 19:10:24
Nancy Folsom
Pixel Dust Industries
Washington, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00148279
Message ID:
00148389
Vues:
22
Hi Nancy:

No offense taken -- I'm at the 'basics' level now on VFP stuff... Incidentally, this is VFP-5.0a, last build, Win95-Release A SP1.

Per your query:

1. Controlsource is linked to the field, but Bound = .F. (default)
2. Rowsource is drawn from a different (lookup) table - Yes
3. Rowsource is type 6 - fields - in the other table
4. Code in methods: I started with none except to re-select the right work area, but currently it looks like this (nAtAdd is a property that is the record number of the newly added record in the master table):
*********************************************************************************
* CombocComp_ID - Valid
DODEFAULT()
* be sure the desired table is active...
SELECT wCalForm
IF .NOT. THISFORM.llEdit && ie: in ADD mode...
IF BETWEEN ( THISFORM.nAtAdd, 1, RECCOUNT() )
GOTO THISFORM.nAtAdd
ENDIF
ENDIF
* the following re-sets initial values for the next field (combobox, too...)
PRIVATE ALL LIKE j*
jRetVal = .T.
IF THISFORM.CombocComp_ID.VALUE <> [Z]
THISFORM.CombocZone.VALUE = [9]
THISFORM.CombocZone.ENABLED = .F.
THISFORM.CombocZone.REFRESH
ELSE
THISFORM.CombocZone.ENABLED = .T.
ENDIF
RETURN (jRetVal)
********************************************************************************
* CombocComp_ID - LostFocus
DODEFAULT()
* be sure the desired table is active...
SELECT wCalForm
IF .NOT. THISFORM.llEdit && ie: in ADD mode...
IF BETWEEN ( THISFORM.nAtAdd, 1, RECCOUNT() )
GOTO THISFORM.nAtAdd
ENDIF
ENDIF
ThisForm.Refresh
********************************************************************************
5. Add master record before selection from cbo? This application uses Recycled deleted() records, so the answer is Yes.

Sorry this is so long, but I wanted to give you all the poop, in case I overlooked something simple & stupid...

TIA

Rob
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform