canoevalley

File Extension showing up in file name

Discussion created by canoevalley on Apr 26, 2016
Latest reply on Feb 28, 2017 by canoevalley

I don't mean to ramble here but thought best to give you a good idea of what's going on.

 

My client is migrating from Excel to FileMaker. Nice! Their file is huge so I need to automate the import as much as I can. One issue I am haveing while performing some test imports is explained below.

 

I have a folder with images. The images are identified by numbers and some with a letter at the end of the number. 10-377.jpg, 10-585_s.jpg. There are over 1000 image files in this folder.

 

I have two tables. One called "Products" the other called "Images". In a table called  "Images", I have a two fields. The file number of the image will be called Style Number in FileMaker (Text Field) and there is a container field to receive the image.

 

I have set up a calculation in the container  (Calculated Value, "GetContainerAttribute ( Images ; Style_Number )". I tested the import and the image imported as well as the file. The issue is that the extension, .jpg was also imported as part of the file name. So now my Style Number looks like 10-377.jpg. I do not want to use a Number Text Field as there are some images with a letter at the end and I need this. I just want the file extension, .jpg to be deleted.

 

Is there some kind of function or calculation that could resolve this? I am not a really good coder so If you have some ideas, please explain in steps.

 

Thanks very much.

 

Bob

Outcomes