Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
BeforeInsert return .F. and error descriptions
Message
De
24/04/2003 10:13:11
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
BeforeInsert return .F. and error descriptions
Divers
Thread ID:
00781101
Message ID:
00781101
Vues:
61
Hi!
1. When i'm trying to return FALSE in BeforeInsert event. How do i trap or suppress this error? I want to insert new value of PK in cursor from base table. ID field in base table is AutoInk.

For example:
LOCAL ARRAY lcFields[1, 18]
LOCAL lcOldReprocess as String
lcOldReprocess = SET("Reprocess")
SET REPROCESS TO 10
IF FLOCK([Products])
	AFIELDS(lcFields,  [Products])
	liRowNumber = ASCAN(lcFields, [nProduct_ID], -1, -1, 1, 15)
	liNextID = lcFields[liRowNumber, 17]
	REPLACE nProduct_ID WITH liNextID IN [ProductView]
	UNLOCK IN Products
ELSE
	*!* Error routine
	RETURN 0
ENDIF
DODEFAULT(Bla,Bla,Bla
Maybe there is another solution?

2. When message "The BeforeInsert event has failed" is occurs i'm call AERROR() to find error #, becaus if i press "Help" button start page in help is shown. Error # is 2089. In help is no description on this error number. On MSDN documentation too.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform