Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Determining if record found in scan
Message
De
26/03/2003 17:41:37
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00770498
Message ID:
00770507
Vues:
11
if you don't want to use the seek command try this:
>
>SELECT lv_x_emp_itc
>SCAN
>	DO CASE
>	
>		CASE lv_x_emp_itc.upd_status == 'A' 	&& add
>		
>		
>		CASE lv_x_emp_itc.upd_status == 'C'		&& change
>			SELECT rv_udfield
			FoundIt = .f.
                                SCAN FOR rv_udfield.ssno == lv_x_emp_itc.ssno
>			
>			--------->>>>??? how do I know if my find was successful
                                   FoundIt = .t.
                                   exit
>       
>			ENDSCAN
                                if FoundIt = .t.
                                   * *** alright - we got the first match
                                endif
>				
>		CASE lv_x_emp_itc.upd_status == 'D' 	&& delete			
>			SELECT rv_udfield
			FoundIt = .f.
>			SCAN FOR rv_udfield.ssno == lv_x_emp_itc.ssno
>			
>				--------->>>> ??? how do I know if my find was successful
                                   FoundIt = .t.
                                   exit
>			
>			ENDSCAN
                                if FoundIt = .t.
                                   * *** alright - we got the first match
                                endif
>	ENDCASE
>ENDSCAN
>ENDWITH
>
>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform