January 28, 201610 yr I'm struggling to remove quotation marks from a symbol/operator such as this: "<" I have tried Substitute (Text; "\""; ""), as well as Brian Dunning's custom function RemoveSmartQuotes (text). Both works in the field of question perfectly with normal text, such as {hello "world"} ends up being {hello world}, but ho matter what I run "<" through, the quotation marks remain untouched. Any ideas? Edited January 28, 201610 yr by artvault
January 28, 201610 yr Author Thank you Lee! "\<" returns \< Ok, then I just have to find a way to remove the backslash... LOL
January 28, 201610 yr Author Believe it or not, this is actually it: "<" From that I need to remove quotation marks, so that I simply wind up with < in the field. Seems simple...
January 28, 201610 yr Try Substitute(YourField;"\""; "") In your original post, you used a forward slash / instead of a backslash \ Edited January 28, 201610 yr by doughemi
January 28, 201610 yr Author 2 minutes ago, doughemi said: Try Substitute(YourField;"\""; "") First thing I tried, not working, see original post.
January 28, 201610 yr Author Just now, doughemi said: In your original post, you used a forward slash / instead of a backslash \ Sorry, my bad, should be a backslash (FM automatically converts """" to "\""). I'll fix it. I don't think I should be working that late... I created a new file, same technique (supposedly), and it works! Sorry for taking up your time. I'm posting the sample file. Maybe this will be helpful to someone. RemoveQuotations.fmp12.zip Just FYI: I'm not going totally crazy. Luckily! Where it FAILS is in Find Mode. In Browse Mode it works like charm. So that might very well be impossible to solve. I'm am curious to why this is the case though...
January 28, 201610 yr The > is an operator and needs to be escaped using the backslashed. This find work with your sample file Enter Find Mode \> perform find BTW this was the replace calculation I used Substitute ( YourField ; "\">\""; ">")
January 29, 201610 yr Author Thank you all for trying to help! I have taken the time today to separate all of the functionality that's related to this question and put it in a (new) sample file. I realize that the solution might consist of a work-around of sorts, so it's important to have the context. In the file attached you can see an attempt to emulate FileMaker "native" find mode within a user's UI (does not require visibility of status bar). A crucial part of this workflow is the insertion of search operators. Most search operators are not problematic. You can insert them by means of script without any issues. The problem exists with > or < operators. Filemaker immediately complains about "invalid find criteria". When wrapped in quotation marks, these are inserted into the field without any error messages. The challenge then is (that's what this thread was originally about) to remove the quotes. Unless there is a better way.... altogether? SearchOperators.fmp12.zip PS: use the "Enter Find Mode" button to get started - the rest should be obvious. Edited January 29, 201610 yr by artvault
Create an account or sign in to comment