February 28, 200124 yr Hi, I was wondering if anyone knows how to seperate something like: 12:00-7:00pm MWTRF into 12:00-7:00pm as one field MWTRF as another field using a script. I'm new to Filemaker so I don't have alot of experiences with Scripmaker. Thanks [This message has been edited by Kermy (edited February 28, 2001).]
February 28, 200124 yr Hey Kermy, If the information entered will always be the same length - you could use the LEFT, MIDDLE and RIGHT functions. Have the information entered into a temporary field and use these commands to copy out the information and place it in the field you need. For example - using the data you gave 12:00-7:00pm MWTRF You could pull the "MWTRF" using the RIGHT function by saying RIGHT(<fieldname>,5). If the data is not always the same length, use the LENGTH function to find out how many characters are in the field. Hope this helps. Good Luck. Steven B
March 1, 200124 yr Author Actually it won't, the only difference between the 2 texts is that one is all capitals. Can I do something like that?
March 1, 200124 yr If the time will always end in am or pm, I would use that to figure out where to break the field. You can use: BreakPosition = Max( Position(InputField,"am ",1,1), Position(InputField,"pm ",1,1))+1 Field1 = Left(InputField,BreakPosition) Field2 = Middle(InputField,BreakPosition+1,100)
Create an account or sign in to comment