March 31, 200520 yr Hi, Can we provide users with an export utility from where they can select the fields which they want to export. I understand we can do it by using the export script step and performing it without dialog but this would show all the fields and would also show field names to the users. Can we accomplish it using some other method? Thanks, Sanjai
April 1, 200520 yr Yes... but it requires the GetField() function. I know this is in FMP 5.5 and later but not sure about 5.0. The attached quick-and-dirty demo file shows how it could be done. ExportText.zip
April 1, 200520 yr Using Vaughams Example, replace the GetField(exportfield#) calcs by a nested SUbstitute() like this: Substitute( Substitute( Substitute( Substitute( Substitute( Export01Select; "FirstName";FirstName ); "LastName";LastName); "Street";Street); .... This worked since Version 3. However, the Number of nested substitutes is limited to about 24 - 64 in Versions below 7. You can use a lengthy CASE() statement for that ....
April 1, 200520 yr Author Thanks Vaughams and Christian. It is definitely a good idea but if we want to give users a choice of 20 to 30 fields, we have to create those number of global fields. Secondly, we cannot show the export dialog box to select which global fields they want to export because the export dialog box would also show other fields from the file. Could you please let me know how to implement the above solution and if I am not understanding correctly. Thanks, --Sanjai
Create an account or sign in to comment