Newbies thedkey Posted January 18 Newbies Posted January 18 (edited) I used FM since it wasn't an Apple-Claris app and I was always able to import in different records the various files ending with "TXT" e placing them in different field based on the tabs each file contained. The Carriage Return opened a new record and repeat the import based on the tabs. This until FMP found fies in the selected folder- Now I receve the options of 3 fields only: Content Name Path The content contains everything still I can read the various needed tabs but even if the first line has the correct names everything is just one enormous text file. The carriage return end the import and all other files remain in the original folder. How to import every file in a folder e allow fMP to place each data separated with tab into its specific field them continue with the next file til the end of the folder? Thanks. Yo me is a serious problem as to import files one by one takes forever and I have 350 students to take care off and they all send me their work I need to evaluate Edited January 18 by thedkey errors
comment Posted January 18 Posted January 18 This is difficult to read and hard to understand. 6 minutes ago, thedkey said: Now I receve the options of 3 fields only: Content Name Path I think I already answered this here: https://fmforums.com/topic/110054-fmp-on-sonoma-import-text-from-folder-problems/#findComment-491708
comment Posted January 19 Posted January 19 (edited) 11 hours ago, thedkey said: How to import every file in a folder To import every file in a folder individually you need to start with a list of the file paths. You can get such list by importing the folder (as you seem to be doing now) into another table. Alternatively you could use the BaseElements plugin. Next you need a script to loop over this list and import each file into the target table. If you have files from 350 students you will probably want to follow each import by populating a field with the file's name so that you know the origin of each record. Finally you will need some mechanism to prevent importing the same file twice. We don't have enough details to suggest the best method for this. Perhaps you could simply move the imported files manually out of the source folder. Edited January 19 by comment
Newbies thedkey Posted January 22 Author Newbies Posted January 22 (edited) On 1/19/2025 at 8:39 AM, comment said: To import every file in a folder individually you need to start with a list of the file paths. You can get such list by importing the folder (as you seem to be doing now) into another table. Alternatively you could use the BaseElements plugin. Next you need a script to loop over this list and import each file into the target table. If you have files from 350 students you will probably want to follow each import by populating a field with the file's name so that you know the origin of each record. Finally you will need some mechanism to prevent importing the same file twice. We don't have enough details to suggest the best method for this. Perhaps you could simply move the imported files manually out of the source folder. On 1/19/2025 at 8:39 AM, comment said: Thank you very much for your kinfness- However I only used FMP in a rather simple way, creatung simple scripts and connecting different files at the very most... therefore is hard for me to follow yoour suggestio as for using BaseElements because I am not familiar with the various options and language in that site. I imported the various files in a new table which took the name of the folder where I kept the files of my students work and this is the result just like before: I add here my FMP FILE and the zipped original folder. I removed all the text for privacy reasons. However as you will see each first file has the same fields name separated by tab. What shall I do to get the content of the tabbed files in the main or a new tanle or even a brand new FMP file keeping the varioujs fields separated? test.fmp12 lugòplj.zip Edited January 22 by thedkey erroros
comment Posted January 22 Posted January 22 (edited) The attached file does what I suggested, except the last part (prevent importing the same file again). ImportFilesInFoider.fmp12 Edited January 22 by comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now