overrider Posted March 27, 2006 Posted March 27, 2006 Hello all, can someone tell me how i can use quotes such as --> "" in a calculation field, so i can actually display them in the output of the calculation? for example try to make a calulation which contains "" and it will not quite work. there must be a special way to quote the special characters, but i cant make it cooperate. thanks, overrider
overrider Posted March 27, 2006 Author Posted March 27, 2006 ok now of course after posting this i tried to enclose the " where filemaker complains with the character so " becomes " and now it works fine.
Fitch Posted March 28, 2006 Posted March 28, 2006 In addition to escaping the quote mark with a backslash, there are a couple of other options: one is to use the Quote() function, which returns what's inside the parentheses with quote marks around it. This would work well for example if, in the img tag above, the URL part of the tag was in a field. Another good option for you, since you have FM8 Advanced, is to make a custom function called QUOTE that takes no parameters and simply contains a quote mark. This makes it easy to use in your text calculations, and many developers swear by it. One advantage is it makes your code very easy to read, in case another developer ever has to work on your projects.
Fitch Posted April 19, 2006 Posted April 19, 2006 IMPORTANT: the Quote() function not only puts quotes around the expression, it also [color:red]escapes any special characters with a backslash ()! This may NOT return the results you're expecting, as I recently found out the hard way. My file path Quote(diskfolderfile) turned into "diskfolderfile" -- thanks for the extra slashes, Quote function! From the help file: "This function protects text from being evaluated by the Evaluate function." OK. So I'd now recommend only using Quote for that. Otherwise, the potential headache is not worth the small efficiency you gain.
Recommended Posts
This topic is 6855 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 accountSign in
Already have an account? Sign in here.
Sign In Now