June 20, 200718 yr Hi, I'm having a field which has file path's seperated by "return characters". I'd like to extract the actual filenames, so everything in between a "/" and a return character. Is there a function that can do this? Thanks Robin
June 20, 200718 yr Hi Robin, Try this in a new calculation field Right ( [color:red]Text ; Length ( [color:red]Text ) - Position ( [color:red]Text ; "/" ; 1 ; 1 ) ) Substitute your field for [color:red]Text. HTG Lee
June 20, 200718 yr Author Thanks, but how can I do this with different file paths, this will only work for the first one, right? Thanks
June 20, 200718 yr I'm confused by what you are looking for here. Is this a field in your file, then the calculation will show on each record. Are you importing records, and this is part of a larger text file? More detail on what you have now, and what you are trying to obtain will be helpful. Lee
June 20, 200718 yr Author Hi, It's for attachments, different attachments will be used with a "return character" in between, so I need to check for the return characters, put the different in soms sort of array (if this would be possible in FM) and then print the last characters of each line before the /, does anyone have an idea? Thanks Robin
June 20, 200718 yr If the number is not constant, a recursive calculation is required - so either a custom function, or a repeating calculation field, or a script. print the last characters of each line before the / I think you mean "the last characters of each line before the LAST /"?
June 20, 200718 yr Author If the number is not constant, a recursive calculation is required - so either a custom function, or a repeating calculation field, or a script. I think you mean "the last characters of each line before the LAST /"? Thanks guys, I actually meant after the last / The briandunning function is really nice, now I just have to check for the amount of "/"s. Robin
June 20, 200718 yr Author Oh I see, perfect, before I read your post, I already used patterncount, but yours is a lot easier. Thanks Robin
Create an account or sign in to comment