filepro INDIRECT function

Nancy Palmquist nlp at vss3.com
Tue May 23 10:45:02 PDT 2006


Enrique Arredondo wrote:
> Is there a function in filepro that will do the same thing as Excel's 
> INDIRECT function ?
> 
> Here's what I'm planning to do:
> 
> On a html page Have a couple of Radio buttons with Field names and field 
> numbers onthem. So when a user checks some of these radio button and 
> Sumbits them. My Unix system will run a cgi script that will DEURL that
> string of information and it will parse it within filepro and will export
> a Comma delimited Report back to the webpage Requestor based on the fields
> he wanted.
> So if the Radio button value is 1, then my export command will take that 
> number and make it field 1 so the export writes the value of field one 
> on the CSV file. and so on.... So the user using the web application can 
> decide by cecking some preshown fields which ones he wants on the report.
> 
> So can I do this :
> 
> export ascii out=("inv.csv") r=\n
> 
> 
> import ascii imp=(file_name)  f=~ r=\n
> 
> aa=imp(1){","{imp(2)
> 
> write out
> 
> 
> ------ cut here -----------------
> 
> Thanks
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> http://mailman.celestial.com/mailman/listinfo/filepro-list
> 
> 
Enrique,

If you want to take the field number and use it a a way to match to a 
filepro field number, just do this:

dim fields(XX):1	'where XX is the number of fields in the file.

Then use the field number as a subscript to the fields() Array and you 
will be accessing the filepro field number at the same time.

fields("5") is another name for 5 as a data storage location.

I do this all the time and it works with a lookup file also

dim fields(XX):lookup(1)

Does that help?  I am guessing this is what you want from the references 
and maybe I am way off.

Nancy
-- 
Nancy Palmquist 		MOS & filePro Training Available
Virtual Software Systems	Web Based Training and Consulting	
PHONE: (412) 835-9417		   Web site:  http://www.vss3.com



More information about the Filepro-list mailing list