Ano Nimus Posted November 21, 2003 Posted November 21, 2003 Fields One, Two and Three can be put to either Yes or No. Create a valuelist to do that. It makes no sense, however, if all three are set to Yes, so I would like the user to be warned when he does this. So far, I have come up with a field called checkfield that calculates: If(One="Yes" and Two="Yes" and Three="Yes";"This can't be right!!";"OK") I was thinking about it giving a result of either 0 or 1, then creating yet another field (called validationfield with a selfrelationship and looked-up value to the checkfield, and have the result validated (or not: if not, validation gives me a nice pop-up, which is what I'm looking for). But no matter what I try, I can't make the looked up result from the checkfield fail the validation in the validationfield Am I under- or overcomplicating things? What I am looking for, in the end, is warning the user with a nice pop-up or something likewise impossible to ignore that he is doing something wrong.
zincb Posted November 21, 2003 Posted November 21, 2003 In the validation option for all three fields enter the following calculation: not(f1="YES" and f2="YES" and f3="YES") In the validation error message for all three fields, enter: Fields 1, 2 and 3 cannot all be YES.
Kundinger Posted November 21, 2003 Posted November 21, 2003 Hi 'Ano Nimus', Here are some ideas that I discussed in another post and I've found useful in the past... You could utilize any of the following or combinations thereof... A. a conditional background image that changes based on certain conditions or user privileges B. a conditional message area that displays warnings to users about certain conditions C. a conditional set of buttons that are active/inactive based on certain conditions or user privileges D. a conditional set of button names that are active/inactive or change based on certain conditions or user privileges These capabilities are accomplished with calc fields, repeating container fields, and scripts... - calc fields determine if a certain condition exists... then displays the appropriate text or image from a repeating container field - repeating container fields 'hold' all the text or image options that could be potentially displayed to the user - scripts have 'if' functions to determine if a condition exists based on the results of a calc field, then performs the appropriate actions EXAMPLES... I utilize a background color scheme to display a 'normal' color (green) when conditions are normal within a record or group of records... 'warning' color (red) when conditions are NOT normal within a record or group of records and require action on the users part. My project management solution has a 'Tasks' layout that will display a green background for typical tasks and a red background for tasks that are unassigned, over budget, etc. My calendar solution has a 'Month' layout that displays grey for normal work week days, pink for weekend days, and green for 'today'. I utilize 'warning messages' to display warnings to users about conditions that may exist and require action within records... typically displayed within a custom dialog box or blank area of the screen. My marketing management solution has a warning message on the 'Contacts' layout to warn users when they put a space or return character at the end of field contents such as a return character at the end of a first name. When it comes to buttons... I utilize button labels that display black letters for an active button and grey for inactive buttons. I also utilize buttons (attached to scripts) that determine if a 'BAD' condition exists or if a user has privileges to perform the function. My calendar solution has an 'Create Activity' layout with a grey 'POST' button that will change to black only when a user has entered ALL required data... if they click the grey 'POST' button (script), it will display a warning dialog to complete the required data fields before continuing. I hope these examples give you ideas for your solutions... let me know if you need any clarification or would like to see some samples... Good Luck! Bob Kundinger bob@kundinger.org
Ano Nimus Posted November 24, 2003 Author Posted November 24, 2003 Thanks, guys! Bob, could I indeed be so cheeky as to ask you for a sample of how exactly you would work out such a 'conditional colour-changing' setup? So far, I have created a fourth field in an unused corner of the record that displays in big bold red letters: Please check! 3 times 'Yes' can't be right.' This looks kinda sloppy IMO, and worse: the user can choose to ignore this, so this 'bad' record can be created and allowed to exist (and therefore will, of course). The validation (Not(conditions)) does the trick, by the way, but an extra look into how people solve this in other (elegant) ways is always very welcome to little new me Ano
Ano Nimus Posted November 27, 2003 Author Posted November 27, 2003 I got it done o/ Stealing from choppers example here I made a field that turns bright red when the user does something wrong
Recommended Posts
This topic is 7769 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