reusing arrays in 4.0.5

Richard D. Williams richard at appgrp.net
Wed Apr 27 07:03:07 PDT 2022


The answer is no, you can not reuse an array after you have set it.

But, you can create a different array and read those values back to the 
first array.

lookup item k=ku i=A -nx
not item
end

dim bom(8):item(3)

lookup new = item k=ky i=A -nx
not new
end

dim newbom(8):new(3)

Now, you can read values to and from the new item record into the first 
item record.

Richard
On 4/27/2022 8:03 AM, Cesar Baquerizo via Filepro-list wrote:
> Good morning,
>
>   
>
> I wonder if this can be done. Any help appreciated.
>
>   
>
> I create an array as such: dim bom(8):item(3), where item is the lookup
> alias. Later on I want to repopulate the same array based on another lookup
> to the same file using bom(8):newname(8), where newname is the original
> lookup file (or alias I guess). This generates an error that bom is already
> in use. Same thing happens if I use "item(3)".
>
>   
>
> set bom,newname(3) does not generate an error, but it seems to populate the
> lookup file with current values in bom (in this case empty), instead of
> filling the array bom with the values from newname. Is there anyway to reuse
> bom and repopulate bom with new values?
>
>   
>
> Thanks
>
>   
>
>   
>
> Regards
> ---------------------
>
>
>
>
>
>
> ********************************************************************
>
> This message and any attachments are solely for the intended recipient. If
> you are not the intended recipient, disclosure, copying, use or distribution
> of the information included in this message is prohibited. If you received
> this message in error, please notify the sender and permanently delete.
>
>   
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://mailman.celestial.com/pipermail/filepro-list/attachments/20220427/202e8ea9/attachment.html>
> -------------- next part --------------
> A non-text attachment was scrubbed...
> Name: image001.png
> Type: image/png
> Size: 20179 bytes
> Desc: not available
> URL: <http://mailman.celestial.com/pipermail/filepro-list/attachments/20220427/202e8ea9/attachment.png>
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list
>



More information about the Filepro-list mailing list