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

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

Recommended Posts

Posted (edited)

Hi,

I have built a patient database for my practice.

I want to be able to select a folder where I store photos for the relevant patient (i.e. d:filesmedicalphotospoly_paparas) and store it within the relevant record.

I know this can be done using troifile, but is it possible to do something similar using scriptmaker?

Any help will be greately appreciated.

Edited by Guest
Posted

Probably the easiest way to do this is to create a global text field that contains the path to your image source folder.

"imagewin://d:/files/medical/photos/p oly_paparas/"

Join that together with your patient name field, for example John Doe.

Make sure that the images are named consistently.

For example if they are jpeg images they should be named: John Doe.jpg

Create a Calculation field with result being container.

Enter the following calculation:

Path & PatienName & ".jpg"

and the image will appear automatically.

I have attached a sample file to illustrate this.

To get the correct path reference insert an image manually.

NOTE: If you move the image folder you will have to adjust the path field accordingly.

SampleImageDisplay.fp7.zip

Posted

Thank you for your suggestion but this will not help.

Let me explain. I have a main storage folder called photos. For each of my patients I have a subfolder with the patient's name and each patient's subfolder can have any number of photos for that particular patient.

I use ACDSee to browse my photos and I have created a DDE execute to launch ACDSee (or any other photo viewer for that matter) and I need the pass the relevant path for the particular patient to the photoviewer, so that the program opens in the particular folder.

Posted

There is also the Import Folder command, which can be used with the (•) Matching records option, matching on either a unique File Name or File Path (both of which can be imported). You can import (•) As reference only.

The downside to this command is that it matches the found set. If you show all records, then it's going to be (very) slow. So you would want to have each patient's photos in their own folder, and you'd want to find only their photo records in FileMaker before matching; and the file names must be unique (which they'd have to be anyway, if they were in the same folder).

The photos should be in their own table, related to the Patient table by Patient_ID. Your import would need to be scripted, so it could Replace the Patient_ID into the import pictures (alternatively it could parse it from the File Path imported, if in the path and consistent). So, it's doable without a plug-in. But not easy. However, neither is a plug-in.

Another plug-in you might consider is SuperContainer. This seems to be a good solution for networked situations.

http://www.360works.com/supercontainer/

Also, while Troi File is awesome, there are cheaper alternatives, even a free one (which I haven't tried, but I believe its Folder Info could list a folder's files):)

http://mooplug.com/

And then there's always command line (geeky).

Posted

Thanks!

That was not exactly what I needed, but you gave me a great idea.

If I make sure the folders I store the photos are exactly the same as the patients' names, then I could just add the patient's name at the end of the global photos folder path (i.e. d:filesmedicalphotos + firstname_surname)

and get what I need.

Of course this means that I have to make sure I keep the names the same.

If there is another way though, I would prefer to be able to browse to the particular folder of interest and just select it...

Posted

Well, you could have another script that did not have [ ] Perform without dialog checked. Then it would ask you for the folder. Kind of messy though. I'd think that you'd want to keep those photo folders highly organized. At some point you're going to want to compare the folders' contents with the photo records in FileMaker, to answer the question, "Do I have all the photos in?"

Posted

Thanks Fenton

I will try what you suggested.

I don't think it is messy simply because all I want to store in my database is the folder where each patient's photos are.

I don't need any other information, nor any connections with the actual photo files.

These are stored separately from time to time independently of the database.

I just need to store the path for each patient's photos, so that I can launch the photo viewer program from within my database and get straight to the relevant folder.

Until now I just launch the photo viewer program manually and navigate to the relevant folder manually...

Posted

Also, while Troi File is awesome, there are cheaper alternatives

Hi Fenton,

Apart from MooPlug which has no documentation (yet), what would be the cheaper alternatives to Troi File you mentioned above?

Thanks

Posted

Thanks again for your time and effort.

What you show in your sample database is very useful, but I already know how to do that.

I think I have been misunderstood.

I have a folder or several different folders on my computer where I store the photos of my patients.

These files and folders have nothing to do with my fm database, except for the fact that the database concerns the same patients.

So, I thought, instead of having all these photos (thousands of photos) be linked or imported into the database, I could just have a reference of the path of where the photos for each patient are stored, and then when I want to see the photos of a particular patient, I could just use a DDE execute to open explorer in the particular folder. Or, better still, use the DDE execute to open an image browser like ACDSee to view the images.

The problem I need to solve is being able to tell the database where is the folder of each particular patient. I don't want to have the process automated, because I sometimes put the photos in different folders, or add a description next to the patient's name.

So far I have been using TroiFile to point to the folder for each particular patient and store that path in the database.

I have been using troifile with the following script

SetField[Patients::photo_folder; TrFile_SelectFolderDialog( "-Unused " ; " Please select the folder where you keep the patient's photos." ; "" )]

this would open a dialog, allow me to browse to the folder in question and then, after clicking OK, it would return the folder path to the relevant field.

Having this information stored in a field I can then call my external application

SendEvent["aevt";"odoc";Patients::photo_folder call acdsee]

So the question is can I do what troi file is doing by using just scriptmaker or some other (cheaper or free) plug-in?

Thanks for you patience

Posted

OK, I got it to work using MooPlug

the script is like this

SetField[Patients::photo_folder;Moo_DialogFolder]

It works great

Thank you for a great tool Dempsey!!!

  • Newbies
Posted

Ballycroy:

I picked up on this post because I am trying to do the same thing. Have Filemaker file to track design tasks and would like to be able to access supporting files, images, emails, etc. from the record without having to bring them into the file itself. Picked up on SampleImageDisplay2 file you sent and adapted it to my file. Seems to work other then I can not get it to open down to the actual folder that I want to access. Explorer window to my "My Documents" opens but not two levels down to the actual folder holding the files associated with the record. The OpenFilePath shows the correct (complete) path except lacking last "" between the last two folder names. Any additional advice / trouble shooting I can do to try to get it running right?

Thanks

Posted (edited)

Hi:

The test file is set up to display jpg files (note the calculation in the ImageDisplay field).

You can modify this by deleting the "jpg" reference in that field but then you must put the full image name in some other field.

As a test place an image manually from your source folder into the image container on the right-hand side of the layout making sure to check "Store only a reference to the file"

Note the result of the 3rd line of the GetInfoImage field should start with "imagewin".

Copy everything on that 3rd line up to and including the last "/" before the image name.

Paste into the FolderPath field.

Select the image name (except for ".jpg")

and paste into PatientName field.

The result in the FileOpenPath field should be the same as the 3rd line in the GetImageInfo field.

except that "filewin" is substituted for "imagewin"

Edited by Guest
  • Newbies
Posted

Works! Must have been the folder path name I was using. I opened up the folder in a window and copied the name from the address bar that did not have the imagewin prefix.

Thanks, now I can go back to being productive again!

This topic is 6150 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.