AnsweredAssumed Answered

Importing csv files into FM Go 16

Question asked by dsimonson on Sep 24, 2017
Latest reply on Sep 25, 2017 by skywillmott

I want to do the following to allow users of my FM Go 16 app to import a csv file into my app. 

 

  1. Have the user identify a .csv file to import
  2. Import the .csv file to a container field
  3. Export the container field to a .csv file in the Temp folder
  4. Use "Insert From URL" to insert the file contents into a text field.
  5. Parse the csv in the text field into new records

 

I have the import to container field done, easy.  But exporting to the temp folder and then using "Insert From URL" has me stumped.  Here's my problem script:

 

Set Variable [$tempFilePath; Value: Get(TemporaryPath)&"csvtest.csv"]

            (note: this creates a variable of "/MyHardDisk/var/folders/rr/cl9wnsmw8xjc1k0059b9sjhr0000gn/T/S10/csvtest.csv"

 

Export Field Contents [myTable::csv_container ; "$tempFilePath"]

 

Insert From URL [Select; With dialog On; myTable:csv_text_field; "File//"&tempFilePath ]

 

To this I get error 1631 "Connection failed".

 

Any ideas?  TIA!

Outcomes