Security / Discount Override pt. 2
Visitors to VTC.com will be able to view all introductory videos for each training course.
Free Trial Members will gain access to first three chapters for each training course.
Full Access Members have full access to VTC.com’s entire library of video tutorials.
Learn More
Subtitles of the Movie
So let's say they successfully got through. It'll come down here to end loop and then go to the portal row that we remembered back up here. So we select that portal row, then we say set field because set field is context-sensitive to what row is selected, so we need to select the right row so we apply the discount to the right product that we sold and we simply say take the xdiscount, what we typed up here in this show custom dialog, put that into the Lines Discount field for the row that we have selected right now. Then we say, hey, was there an error? If the person who logged in up here, because they could log in with a password and get past this, even if they don't have the ability to change that discount field. If they get past that and they try to set the discount there and they don't have access to it, because remember, we secured that through limiting access to only certain accounts for that discount field, well, if they don't have access, it's going to give them an error and it's going to commit the records and halt the script again, but if they did have access, it'll get past that and it'll enter another loop. This will be the staff or employee log-in. It'll do exactly, or essentially, the same thing. We initialized the xaccount and xpassword. We have a similar dialog here with input fields, but we don't have the discount down here. We try to re-log in, xaccount and xpassword. If there's no error, then what will happen is it'll go to the end loop and the script will be done. If there is an error, it's going to say there was an error, please try again. It'll come back up to the top, initialize these, show the custom dialog. It'll keep on looping until they type that in, so they have to log back in with their lower level password. They'll never be able to cancel. As you can see, there's no cancel choice here. They can't cancel out of this and get out of this and keep the manager's password in the system. They have to log in with their lower level password or else they'll never get out of that loop. So again, this is a pretty complex little script, but I think it's well worth it. Go ahead and mess around with it, try it, try to write it from scratch, if you can. It'll really help you the most if you can write it from scratch.
Tutorial Information
| Course: | FileMaker Pro 10: Intermediate |
| Author: | John Mark Osborne |
| SKU: | 33926 |
| ISBN: | 1-935320-19-X |
| Release Date: | 2009-01-05 |
| Duration: | 15 hrs / 177 lessons |
| Work Files: |
Yes |
| Captions: | Available on CD and Online University |
| Compatibility: |
Vista/XP/2000, OS X, Linux QuickTime 7, Flash 8 |
VTC Sign up & Benefits
- Unlimited Access
- 98,729 Video Tutorials (23,265 free)
- Video Available as Flash or QuickTime
- Over 1026 Courses
- $30 for One Month Access
- Multi-User Discounts Available
United States 