It's fairly simple to do with a script. First, the script uses insert file to insert the file into the container field. Set it up so the dialog box pops up so that the user can find the file they want to insert.
Script 2 uses export field contents to export the field to your specified location and then uses insert file to re-insert it from that new location with the "store by reference" option enabled.
I do that in several databases. I usually make the container field a button that runs the insert file script. Script 2 is set to run from a script trigger on that container field when it is modified. As a safety measure, to prevent like named files from being overwritten, I rename the file to the recordID & "-" & filename. (we get alot of attachments from customers with names like "Scan001.pdf")
Hi Phil and Mark ,
Thanks for your help, there is another one i would like to figure. This continer field should be able to access by 2 office. I share this database over internet using FM sever . Now should i create folder in server and add that folder path in to export location ? In this method will it be possible to see all the container data from both side ?
For it to be visible to both sites, they both have to map and mount to the shared folder wtih identical file paths.
Hi Phil, Thanks for your reply.
I am developing FM solutions which has lot of container images/ PDF. What i did was create 2 Files, 01 is for Data entry and one one is for Storing Files.
01. Order 02.ex files. so the all the container will go and store the file under "Ex Files" table.(using portals)
my problem is when i use it over Filemaker Server , this database is really slow. for the moemnt it has only 14 records . Ex files capasity about 10 MB. But the record navigation is bit slow. what is your suggestion to make it faster ?
I made indexing off and remove some of back gound graphics which i used , Then i saw there is good progress But still that need to tune up. I have attached few of png buttons which i download from internet but they are really small , will it caused this type of problem ?
thanks in advance
Can't really tell from here what might be the factor. Turning indexing off would be more likely to slow down performance rather than improve it. Where you see a signficant performance hit with indexing on is when you import large numbers of records and FileMaker has to update multiple indexes with every new/modified record during the import.
yes you were right i made all the indexing on now, i didnt see any much difference than last time. is this because of container fields ?