Stu412 Posted October 9, 2015 Posted October 9, 2015 Hi there I have a use case where it's necessary for FM to run a script which updates records - the script takes around 10 seconds to complete. I want to run this on an occasion when a user edits or adds to a portal set of records. I could just use a script trigger, but as I say, this would fire the user into a 10 second update quite frequently and get annoying very quickly. Instead, I want to run the script just once and update all records which are changed in one go. In order to do this, the user will click a button labelled 'Commit Changes' and it's this I want to draw their attention to. When the user edits or adds a record, I want a flashing box to appear around the button. Has anybody got any ideas on how to do this, or indeed, whether it can be done? Thanks
dwdata Posted October 9, 2015 Posted October 9, 2015 You could Set a GLOBAL, and populate a web viewer with HTML (javascript) when you need the flashing alert, then clear them after the routine is done.Please see attached file.Hope this helps! FlashAlert.fmp12
Raybaudi Posted October 9, 2015 Posted October 9, 2015 Hello Don,could you please explain why you have so many ¶ inserted in the calculation of the web viewer?I do not think there is any need.Even the escape of the quotes can be disposed of as you did in other parts of the calculation ( using the apostrophe char )Or is there a real reason that I can't see ?
dwdata Posted October 9, 2015 Posted October 9, 2015 In this filemaker calculation, if you need things to line feed, you need that ¶ character - otherwise hard returns are ignored and you get one line:For example:GreenRedin a calculation will result in - GreenRed (Try it)I chose to use QUOTES and not an apostrophe. Both results should be the same and not a deal breaker. QUOTES are reserved for wrapping text strings. The reason for escaping the quote is to just use that character NOT to end the text string. Try to uncomment the quotes and save my calculation. It should produce syntax error.Did the file I attached not work for you?Anyways, I hope this explanation helps!
Raybaudi Posted October 9, 2015 Posted October 9, 2015 Thank you Don. The file worked. "in a calculation will result in - GreenRed (Try it)" Maybe on a Mac, because on a pc the calculation displays exactly as you enter it "I chose to use QUOTES and not an apostrophe" My concern was the fact that you did not chose an unique way, in fact some part is escaped/quoted and some part is apostrophed. But ofcourse you can do what you wish, I was only asking why.
dwdata Posted October 9, 2015 Posted October 9, 2015 Hehe - Yes I like code CROSS PLATFORM conscientious ;-)Regarding QUOTES - I see your point. Thanks!
Recommended Posts
This topic is 3388 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