Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4319 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

hi all,

 

i have a straightforward file that points to some audio files (1 per record). i have it set up like this:

 

Main folder

-- audiofiles.fp7

-- Audio Folder (contains all the audio files)

 

i have imported all the audio files files with the import folder command. along with some text fields, the data file contains a playback button to preview the audio. works fine so far.

 

when i copy the main folder with everything to another machine, the links break (no audio is played back). something seems to still be in the container field, however, because double clicking does not do anything, where on a new record it puts up the 'record sound' dialog. also navigating to the record from a portal takes quite a bit of time compared to navigating to a record with no reference, but that's the same on the original set of files.

 

so the question is if container files expect the *absolute path* to be the same. if so, is there anything i can do short of performing the same procedure on the other machine over again?

 

thanks,

stefan

Posted

Hi Stefan,

 

container fields and references always mean trouble. ;)

 

Maybe I can suggest a completely other approach: Use a local webviewer to play the audio, it's quite simple and since HTML5 quite easy.

 

Let me know, I can give you some input if interested.

 

Best,

Alexander

Posted

something seems to still be in the container field, however

 

Yes, the container field still contains the path (or paths) to the original file. You can see exactly what it is by looking at =

 

GetAsText ( YourContainerField )
 

You can also replace a part of the path by a simple text manipulation of the container field e.g. by using Substitute(). Another option is to use a global text field for the path to the folder and a local text field for the file name - then make the container field calculate the entire path.

 

 

 

 

 

container fields and references always mean trouble. ;)

 

No, not always. Not even most of the time.

Posted

Hi Stefan,

 

container fields and references always mean trouble. ;)

 

Maybe I can suggest a completely other approach: Use a local webviewer to play the audio, it's quite simple and since HTML5 quite easy.

 

Let me know, I can give you some input if interested.

 

Best,

Alexander

hi alexander,

 

thanks for the tip - i'm afraid my HTML knowledge is frozen in 4 transitional :getlost:

 

did you mean a web viewer from inside FM or a web page without FM? i haven't used the web viewer features for anything besides checking them out.

 

stefan

Posted

 

Yes, the container field still contains the path (or paths) to the original file. You can see exactly what it is by looking at =

 

GetAsText ( YourContainerField )
 

You can also replace a part of the path by a simple text manipulation of the container field e.g. by using Substitute(). Another option is to use a global text field for the path to the folder and a local text field for the file name - then make the container field calculate the entire path.

didn't know about displaying the content as text - that's pretty cool. when i tried, the result was surprising, it said:

 

size:0,0

movie:<filename>

moviemac:/discname/path_to_audio_folder/filename

 

i find it surprising, because the filename appears twice and it works even if i remove the first two lines altogether. what are they for?

 

i tried what you suggested with the calc field and that works well. the only problem is that sending the files to someone else requires them to supply the proper path to be used in the calculation and not everyone understands as much as 'file path'.

 

thanks,

stefan

Posted

the filename appears twice and it works even if i remove the first two lines altogether. what are they for?

 

One is a relative path to the file, the other an absolute one. Filemaker will try all the supplied paths in succession and use the first one that turns out to be valid.

 

 

the only problem is that sending the files to someone else requires them to supply the proper path

 

Unless you use a relative path and take steps to control the installation. You should also explore the new container field features of version 12.

Posted

One is a relative path to the file, the other an absolute one. Filemaker will try all the supplied paths in succession and use the first one that turns out to be valid.

 

that's perfect - i was hoping to use a relative path. now i don't even need to know what the drive of another user looks like, as long as he doesn't mess around with the files within the folder, all is set.

 

thanks much!

This topic is 4319 days old. Please don't post here. Open a new topic instead.

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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