dbTalk Databases Forums  

Changing Image Paths

comp.databases.filemaker comp.databases.filemaker


Discuss Changing Image Paths in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Denny
 
Posts: n/a

Default Changing Image Paths - 06-17-2005 , 02:35 PM






Yes, I understand that I can make a path in a field many ways, and in
this case it is even a lot simpler. The issue is how do I connect that
text field or calc field data to the picture. When you import a folder
of images, there are four pieces of data that can be imported, which
include File Name, Image, Image Thumbnail, and Path. But the problem
is that the path text that ends up in the imported field appears to be
only a reference that can be stored, because changing that path text
string does not change the path to the actual image. I have even
deleted the path field completely and the image still appears in the
image field, telling me that that data is only some reference data. I
have even tried changing it and pasting it in the image field as if
something was hidden there, and it either didn't paste or have any
affect.

Denny



Denny,

This is one I can answer... we do this with images on our server all
the time using FMPro 6. It sounds to me like you have a bunch of files
on a server in a particular folder, or several different folders?
Anyway, you CAN store the file path in a Calc field, in one of many
ways. If you have different folders for different types of files,
you'll have to either set up a way for the user to indicate which
folder the file will go to, or set up some type of standard so everyone
is putting the same type files in the same place. But all you need is a
field in the record that holds the file name of the file you're dealing
with and then a calc field that builds the path to the file. If you
ever need to change the path, all you have to do is change the root
string of the calc field. Here's my example....

text field- FileName: report.jpg
calc field- FilePath: "http://www.ugaphoto.alumni.uga.edu/news/" &
FileName

So your final calc field will look like this:
http://www.ugaphoto.alumni.uga.edu/news/report.jpg

I use this same method to build file paths via the web (above) or to
our internal Xserve via afp like this:
"afp:123.456.78.9:Photos:Photosfp5:"& FileName

If you need to change the root of the path often, or you need several
different root folders, you might even consider storing them in a
separate database or in a global field. I've got a script that looks at
each user's desktop, and if it doesn't find a particular folder on the
desktop, it creates the folder, plus 4 subfolders. I then use paths to
this folder and it's subfolders as the source and destination folders
for any files we're moving to or from the server. So if you're getting
files off the server, FMPro pulls them off the server and puts a copy
in the downloads folder, and if you've got files you need to put on the
server, you stick them in the uploads folder, then FMP knows to look in
that folder for a particular file name, and move it to a particular
folder on the server. I use the Troi File Plugin for all the file
handling.

Hope that helps.

Rick O¹Quinn


Reply With Quote
  #2  
Old   
Remi-Noel Menegaux
 
Posts: n/a

Default Re: Changing Image Paths - 06-18-2005 , 01:29 AM






This is not an answer, just 2 remarks.
- a common good practice is to hold the images on a separate folder,
which can be shared, and has a file per image such as 'Image001.jpg'.
Then in your FM record, in your Multimedia field, you'll record only its
'reference' ie its path to the image folder.
- I found that the only way to easily manipulate files from within
FileMaker was to use a plugin such as 'Troi File' at 'www.troi.com',
which has excellent examples attached. Particularly true for FMP
versions less than 6.
Remi-Noel

"Denny" <denny (AT) yourguess (DOT) de> a écrit dans le message de news:
170620051235460913%denny (AT) yourguess (DOT) de...
Quote:
Yes, I understand that I can make a path in a field many ways, and in
this case it is even a lot simpler. The issue is how do I connect
that
text field or calc field data to the picture. When you import a
folder
of images, there are four pieces of data that can be imported, which
include File Name, Image, Image Thumbnail, and Path. But the problem
is that the path text that ends up in the imported field appears to be
only a reference that can be stored, because changing that path text
string does not change the path to the actual image. I have even
deleted the path field completely and the image still appears in the
image field, telling me that that data is only some reference data. I
have even tried changing it and pasting it in the image field as if
something was hidden there, and it either didn't paste or have any
affect.

Denny



Denny,

This is one I can answer... we do this with images on our server all
the time using FMPro 6. It sounds to me like you have a bunch of files
on a server in a particular folder, or several different folders?
Anyway, you CAN store the file path in a Calc field, in one of many
ways. If you have different folders for different types of files,
you'll have to either set up a way for the user to indicate which
folder the file will go to, or set up some type of standard so
everyone
is putting the same type files in the same place. But all you need is
a
field in the record that holds the file name of the file you're
dealing
with and then a calc field that builds the path to the file. If you
ever need to change the path, all you have to do is change the root
string of the calc field. Here's my example....

text field- FileName: report.jpg
calc field- FilePath: "http://www.ugaphoto.alumni.uga.edu/news/" &
FileName

So your final calc field will look like this:
http://www.ugaphoto.alumni.uga.edu/news/report.jpg

I use this same method to build file paths via the web (above) or to
our internal Xserve via afp like this:
"afp:123.456.78.9:Photos:Photosfp5:"& FileName

If you need to change the root of the path often, or you need several
different root folders, you might even consider storing them in a
separate database or in a global field. I've got a script that looks
at
each user's desktop, and if it doesn't find a particular folder on the
desktop, it creates the folder, plus 4 subfolders. I then use paths to
this folder and it's subfolders as the source and destination folders
for any files we're moving to or from the server. So if you're getting
files off the server, FMPro pulls them off the server and puts a copy
in the downloads folder, and if you've got files you need to put on
the
server, you stick them in the uploads folder, then FMP knows to look
in
that folder for a particular file name, and move it to a particular
folder on the server. I use the Troi File Plugin for all the file
handling.

Hope that helps.

Rick O¹Quinn




Reply With Quote
  #3  
Old   
Denny
 
Posts: n/a

Default Re: Changing Image Paths - 06-18-2005 , 01:12 PM




Manipulating files is pretty easy in FM 6 without any plugins, by using
the script command Send Message. For example, to clear out a folder you
simply send the message "CMD /C Erase C:\foldername /q". You can send
almost any DOS command that will move files, alter files, etc. My
problem is re-setting Filemaker to look at the new location of the
image file. The bottom line is that I don't know where FM keeps the
actual path that it uses to locate the image. As I mentioned, when you
import an image, you can import the file path at the sam time, but for
some reason that path is on a reference, and unfortunately altering
that path changes nothing. I am not sure where FM keeps the actual
path that it uses, but my thinking is that if Troi can make a plugin
that alters it, then FM should be able to alter it without any plugin.
I have learned that most of the stuff plugins do can be done either by
sending a DOS command to the OS, or by sending a command to activate a
little coded file. I have a feeling that FM holds the real path in the
actual image field, but I am not sure and don't know how to access it

Denny

Quote:
This is not an answer, just 2 remarks.
- a common good practice is to hold the images on a separate folder,
which can be shared, and has a file per image such as 'Image001.jpg'.
Then in your FM record, in your Multimedia field, you'll record only its
'reference' ie its path to the image folder.
- I found that the only way to easily manipulate files from within
FileMaker was to use a plugin such as 'Troi File' at 'www.troi.com',
which has excellent examples attached. Particularly true for FMP
versions less than 6.
Remi-Noel

"Denny" <denny (AT) yourguess (DOT) de> a écrit dans le message de news:
170620051235460913%denny (AT) yourguess (DOT) de...
Yes, I understand that I can make a path in a field many ways, and in
this case it is even a lot simpler. The issue is how do I connect
that
text field or calc field data to the picture. When you import a
folder
of images, there are four pieces of data that can be imported, which
include File Name, Image, Image Thumbnail, and Path. But the problem
is that the path text that ends up in the imported field appears to be
only a reference that can be stored, because changing that path text
string does not change the path to the actual image. I have even
deleted the path field completely and the image still appears in the
image field, telling me that that data is only some reference data. I
have even tried changing it and pasting it in the image field as if
something was hidden there, and it either didn't paste or have any
affect.

Denny



Denny,

This is one I can answer... we do this with images on our server all
the time using FMPro 6. It sounds to me like you have a bunch of files
on a server in a particular folder, or several different folders?
Anyway, you CAN store the file path in a Calc field, in one of many
ways. If you have different folders for different types of files,
you'll have to either set up a way for the user to indicate which
folder the file will go to, or set up some type of standard so
everyone
is putting the same type files in the same place. But all you need is
a
field in the record that holds the file name of the file you're
dealing
with and then a calc field that builds the path to the file. If you
ever need to change the path, all you have to do is change the root
string of the calc field. Here's my example....

text field- FileName: report.jpg
calc field- FilePath: "http://www.ugaphoto.alumni.uga.edu/news/" &
FileName

So your final calc field will look like this:
http://www.ugaphoto.alumni.uga.edu/news/report.jpg

I use this same method to build file paths via the web (above) or to
our internal Xserve via afp like this:
"afp:123.456.78.9:Photos:Photosfp5:"& FileName

If you need to change the root of the path often, or you need several
different root folders, you might even consider storing them in a
separate database or in a global field. I've got a script that looks
at
each user's desktop, and if it doesn't find a particular folder on the
desktop, it creates the folder, plus 4 subfolders. I then use paths to
this folder and it's subfolders as the source and destination folders
for any files we're moving to or from the server. So if you're getting
files off the server, FMPro pulls them off the server and puts a copy
in the downloads folder, and if you've got files you need to put on
the
server, you stick them in the uploads folder, then FMP knows to look
in
that folder for a particular file name, and move it to a particular
folder on the server. I use the Troi File Plugin for all the file
handling.

Hope that helps.

Rick O¹Quinn





Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.