- View New Content
- Home
- Site
-
Forums
- Community Resources
- FileMaker Security Management
- FileMaker Server Administration
- FileMaker on the GO
- Database Schema & Business Logic
- The Presentation Layer
- Brain Food
-
FileMaker and WEB 2.0 Technology
- 360 Works Official Product Support Forums
- FM Forums Affiliate Sponsors
- FileMaker Developers & User Groups
- Tools Of The Trade
- FileMaker Classifieds
- FileMaker Product Family
- The Water Cooler
- FM Forums Operations
- Blogs
- Social Groups
- Marketplace
- Chat
-
More
Trying to disable the Revert Record dialog
Started by sedek, Feb 28 2012 11:36 AM
revert field; revert record
7 replies to this topic
#1
novice
Posted 28 February 2012 - 11:36 AM
I have a date field in a customer order entry layout.
I have put a custom dialog in the field properties if validation fails. It is done by calculation which I guess explain why it is the only field that shows a ''Revert'' option in my custom dialog box.
As users don't have a clue what this is, I need to get rid of it.
My calculation to validate the date is as follows: DateCedule ≥ Get(CurrentDate) and DateCedule ≤ (Get(CurrentDate)+184
That translate to anywhere between today's date and no more than 6 months from today.
I read in forums that the common way to avoid the Revert in a dialog box is to include a formula that changes color of the field. Using examples, I now have this formula:
If(DateCedule ≥ Get(CurrentDate) and DateCedule ≤ (Get(CurrentDate)+184); TextColorRemove(DateCedule; RGB(200;0;0) ) ; TextColor(DateCedule; RGB(0;0;0)))
Obviously, it contains a huge (or dumb) error as it doesn't do anything!
Can someone help me? I have a hard time with formulas in general as I am still a novice.
I have put a custom dialog in the field properties if validation fails. It is done by calculation which I guess explain why it is the only field that shows a ''Revert'' option in my custom dialog box.
As users don't have a clue what this is, I need to get rid of it.
My calculation to validate the date is as follows: DateCedule ≥ Get(CurrentDate) and DateCedule ≤ (Get(CurrentDate)+184
That translate to anywhere between today's date and no more than 6 months from today.
I read in forums that the common way to avoid the Revert in a dialog box is to include a formula that changes color of the field. Using examples, I now have this formula:
If(DateCedule ≥ Get(CurrentDate) and DateCedule ≤ (Get(CurrentDate)+184); TextColorRemove(DateCedule; RGB(200;0;0) ) ; TextColor(DateCedule; RGB(0;0;0)))
Obviously, it contains a huge (or dumb) error as it doesn't do anything!
Can someone help me? I have a hard time with formulas in general as I am still a novice.
#2
novice
Posted 28 February 2012 - 11:45 AM
Update to my own topic:
In the properties of the field I could maybe use the ''in range'' option instead of a calculation.
But whatever entries I put there, It performs nothing in terms of validation.
What is the proper syntax to express ''between today and 183 next coming days'' in the ''in range'' option ?
Of course, the field has a Date format.
In the properties of the field I could maybe use the ''in range'' option instead of a calculation.
But whatever entries I put there, It performs nothing in terms of validation.
What is the proper syntax to express ''between today and 183 next coming days'' in the ''in range'' option ?
Of course, the field has a Date format.
#3
Independent Contractor
Posted 28 February 2012 - 11:53 AM
I think you were on the right track with a calculated validation. I don't know what you are trying to accomplish though. Do you want to validate the value of the field, or don't you? If you want to validate it, then the Revert button is there to stay.
Do you want to allow a value that is not in your specified range, and just show the user that it is not valid? If so, then you could use that same basic calculation (the first one) in conditional formatting, and apply red text (or whatever you want) if the value is out of the specified range.
Do you want to allow a value that is not in your specified range, and just show the user that it is not valid? If so, then you could use that same basic calculation (the first one) in conditional formatting, and apply red text (or whatever you want) if the value is out of the specified range.
#4
novice
Posted 28 February 2012 - 12:10 PM
I just want to force the user to correct his mistake.
If the revert field is pressed, it is then followed by a Revert Record dialog. If he presses it, he gets kicked out to the main menu and has to start over.
That is not elegant at all. So far my only option is to instructs users not to press it ...!!
Any idea about the proper syntax to express (''between today and 183 next coming days'') in the ''in range'' option of the field's properties?
If the revert field is pressed, it is then followed by a Revert Record dialog. If he presses it, he gets kicked out to the main menu and has to start over.
That is not elegant at all. So far my only option is to instructs users not to press it ...!!
Any idea about the proper syntax to express (''between today and 183 next coming days'') in the ''in range'' option of the field's properties?
#5
ChindoguMaker
Posted 28 February 2012 - 12:37 PM
Can someone help me?
Get rid of that validation formula and try this one.
1) Do not set any validation formula for that field
2) Create a new script:
If [ Get ( ActiveFieldContents ) < Get ( CurrentDate ) or Get ( ActiveFieldContents ) > Get ( CurrentDate ) + 183 ]
Show Custom Dialog [ "This date is wrong" ] // enable only the OK button
Clear [ Select ]
End If
3) Set that field to trigger the above script by OnObjectValidate
Daniele
--------------------------------
I'm sorry for my English
--------------------------------
I'm sorry for my English
#6
Independent Contractor
Posted 28 February 2012 - 12:52 PM
You can't. The "in range" option contains static values, "today" is a dynamic value. Also, I've never used that for anything other than numbers, so I don't even know if it works/how it works on a date field.Any idea about the proper syntax to express (''between today and 183 next coming days'') in the ''in range'' option of the field's properties?
That won't solve your problem anyways, the user will still get an option to revert. That option always exists if you use field validation. If you don't want it, you will need to use another method to validate data entry.
edit: I didn't see Raybaudi's post before I posted
Edited by dansmith65, 28 February 2012 - 12:53 PM.
#7
novice
Posted 28 February 2012 - 01:39 PM
Thank you for helping.
I tried that but the Revert still appears.
I will try again tomorrow and report back.
SD
I tried that but the Revert still appears.
I will try again tomorrow and report back.
SD
#8
novice
Posted 28 February 2012 - 05:30 PM
After checking carefully, I still have the Revert Field message.
However, the field does revert (which is fine) and the Revert Record dialog box does not appear now.
That means the user doesn't get kicked out to main menu anymore, this is what I needed.
Thanks for the help.
SD
However, the field does revert (which is fine) and the Revert Record dialog box does not appear now.
That means the user doesn't get kicked out to main menu anymore, this is what I needed.
Thanks for the help.
SD

































