Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Server change ... references to pictures???

Featured Replies

Hi,

I have stored all the pictures as references to the files, and now they are going to change the server. shocked.gif Once they move the files to the new server, I guess the links will be lost ... is there any way to avoid this, or a quick fix? smile.gif

Thanks a lot in advance!

The links shouldn't be lost if the file paths remain the same. If not, I don't know if there is a quick fix -- but you can convert your images to internally stored using applescript.

I don't know how you first inserted the pictures. Do you know about the Import Folder option, in the Import dialog (version 6)? It can bring in an entire folder of pictures, including subfolders, either as embedded or referenced.

If, however, embedded is what you want, use jfmcel's idea of AppleScript (or a plug-in, either ImageScan or Troi File can I believe do this, probably others also). Basically, FileMaker stores the referenced path in the container. So if you set a text field to the container you get the path.

I don't think you can use Troi after the fact --

  • Author

Thank you very much the feedback! smile.gif The images are too big to store them in the files by using applescript. Also they are "all over the place" (not in a certain folder), so I'll have a look at what the plug-ins can do ...

Also I like fenton's idea of getting the path by setting the text field to the container ... how can I do that? blush.gif (I would like to play with it) Please let me know.

Thanks again!

If the paths are still valid, i.e., before you move them. The container is "theImage," "thePath" is a text field. You should be on the layout with both.

Perform AppleScript [

tell current record of document 1

try

set m to cell "theImage"

set cell "thePath" to m as string

end try

end tell

]

As far as bringing the images in, AppleScript can insert an image file as a reference, by using a file reference. Here's an example from one of my files (you would likely not pick them one at a time like this, but use "list folder" to do a folder at once):

set theFile to (choose file with prompt "Choose the picture to import

  • Author

Thanks a lot Fenton! laugh.gif I tried the first part and worked perfectly. So now I know how to have the path in a text field.

However, I tried to bring the paths to a container field, but wasn't able to (I'm new to applescript). I have some questions about the second part, I apologize if they are too basic: blush.gif

set theFile to (choose file with prompt "Choose the picture to import ...")

If I wanted to insert the picture again with the same path (just for testing), can I refer to the "thePath" field where "(choose file with prompt "Choose the picture to import ...")". That is, can I do something like ...

set theFile to "thePath"

Thanks very much in advance

  • Author

Hi,

How can I modify the below applescript in order to get the file name instead of the file path? (in the text field) blush.gif

Thank you in advance!

Perform AppleScript [

tell current record of document 1

try

set m to cell "theImage"

set cell "thePath" to m as string

end try

end tell

]

Fenton answered your question. Use "info for" to get the file name.

From my earlier post:

set theFile to (choose file with prompt "Choose the picture to import

  • Author

Thanks very much, I'll try that. I don't have an easy access to a Mac to play with AppleScript ( blush.gifshame on me! ) .... so I got the file name by defining two new calculation fields, that refer to the "thePath" field:

thePathWSpaces = Substitute( thePath , ":" , " " )

FileName = RightWords( thePathWSpaces, 1 )

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.