Changing Records, How-To

Bill Randall wrandall at fptech.com
Mon Nov 19 11:43:09 PST 2012


Stanley,

Use

     lookup -

or lookup dash in the manual


On 11/19/2012 2:38 PM, Stanley - stanlyn-com wrote:
> Hi,
>
>   
>
> I'm sort of embarrassed to ask such a question after the hundreds of
> thousands of filepro coding I've written.  I guess the old saying "If you
> don't use it, you'll lose it" is true.  So anyway here goes.
>
>   
>
> 1.
>
> I'm in the customer table and after copying the current record to a new one,
> I now want to move to that record with it shown on the screen (or the focus
> moved to it).  I can get the record # of the newly created record and do a
> lookup with the record #.  I've tried that and added a display after the
> lookup and it doesn't change to the new record.  Here is some code.
>
>   
>
> @keyT
>
> .         I'm in the cust table
>
> .         I created a new customer record and saved its record number to a
> declared variable "lnRecNum"
>
>   
>
> If:
>
> Then:  yi=lnRecNum
>
>   
>
> If:
>
> Then: lookup cust = customer  r=yi   -n
>
>   
>
> If:
>
> Then: display
>
>   
>
> If:
>
> Then: End            '  the @KeyT processing
>
>   
>
> The record I was on when pressing the T key is still there as it did not
> change.
>
>   
>
>   
>
> 2.
>
> One other thing,  I declared the variable "lnRecNum", but cannot use it with
> the lookup statement, hence me writing it to a new variable "yi".  Why
> cannot the declared variable be used with the lookup statement.
>
>   
>
> Works: lookup cust = customer  r=yi   -n
>
> Fails: lookup cust = customer  r=lnRecNum   -n
>
> Thanks,
>
> Stanley
>
>   
>
>   
>
>   
>
>   
>
>   
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: http://mailman.celestial.com/pipermail/filepro-list/attachments/20121119/03b5644c/attachment.html
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.celestial.com/pipermail/filepro-list/attachments/20121119/c682626a/attachment.html 


More information about the Filepro-list mailing list