General information
Category:
Coding, syntax & commands
>ThisForm.SaveAll()
>...numerous lines of associated set up...
>SELECT vpOrderItemsSupplier
>n=0
>BEGIN TRANSACTION
>SCAN
> n=n+1
> IF NOT TableUpdate(0,.T., "vpOrderItemsSupplier")
> MESSAGEBOX( "The Order Items table was not updated for" +CHR(13)+ ;
> "record "+str(n) +CHR(13)+ ;
> "Report_Nam "+vpOrderItemsSupplier.Report_Nam +CHR(13)+ ;
> "Report_Num "+vpOrderItemsSupplier.Report_Num, ;
> MB_ICONEXCLAMATION+MB_OK, ;
> "Omnia Background Search - Saving Order Information")
> lSuccess = .F.
> lRetVal = .F.
> ENDIF
>ENDSCAN
>END TRANSACTION
>
>At this point an inspection of the OrderItems.dbf shows that the records are unchanged... I'm at a loss and need help!
>
Two things offhand strike me.
Your tablupdate does not look right. The first parameter is to tell if you want to update allrows .T. or one row .F.
Unrelated problem. You are'nt issuing a rollback.
BEGIN TRANSACTION
llSuccessfulUpdate = TableUpdate(.T.,.T., "vpOrderItemsSupplier" )
IF llSuccessfulUpdate
END TRANSACTION
ELSE
ROLLBACK
ENDIF
* END TRANSACTION
<\TEXT>
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only