db_tragic Posted December 3, 2013 Posted December 3, 2013 Hi folks, Am after help compiling a script to limit a demo iPad-based solution to 30days after first open. I have used a date-based script to similar effect, however, am after something more empirical. TIA
Fitch Posted December 4, 2013 Posted December 4, 2013 At the most basic level: 1. Create a single-record preferences table, with a "firstOpen" date 2. Each time the file is opened run a script: Go to layout( prefs ) If( IsEmpty( firstOpen )) .. Set Field( firstOpen ; Get(CurrentDate) ) Else If( Get(CurrentDate) > ( firstOpen + 30 ) ) .. Show custom dialog .. Close file End If
Steven H. Blackwell Posted December 5, 2013 Posted December 5, 2013 What is to prevent someone's opening the file without running the script? Steven
Rick Whitelaw Posted December 6, 2013 Posted December 6, 2013 On an iPad running FM Go how would it be possible to open a file without the script running? Although I suppose a person could perhaps move it to a computer running FM and start up the file without running the opening script.
Steven H. Blackwell Posted December 6, 2013 Posted December 6, 2013 Rick: Precisely. And also then possibly tamper with the flag field or otherwise disable the script. Steven
db_tragic Posted December 6, 2013 Author Posted December 6, 2013 Thankyou Fitch - just what I was after, just didn't know how to compile it. At the most basic level: 1. Create a single-record preferences table, with a "firstOpen" date 2. Each time the file is opened run a script: Go to layout( prefs ) If( IsEmpty( firstOpen )) .. Set Field( firstOpen ; Get(CurrentDate) ) Else If( Get(CurrentDate) > ( firstOpen + 30 ) ) .. Show custom dialog .. Close file End If Rick, I had thought of this too…but inexperience as far as security concepts, means I have yet to uncover a workaround for this…. On an iPad running FM Go how would it be possible to open a file without the script running? Although I suppose a person could perhaps move it to a computer running FM and start up the file without running the opening script. Steven, I thought you might chime in - thank you, ……I'm open to suggestions. When the file is distributed, I don't allow them full admin access, they have only limited access - I'm just not sure that if using this method generates enough security to avoid 'some' of these sorts of possibilities. Although, the impression I get is that using any form of scripting to restrict access is principally flawed because of the ability to pause the script/access it though a debugger> Rick: Precisely. And also then possibly tamper with the flag field or otherwise disable the script. Steven
Rick Whitelaw Posted December 7, 2013 Posted December 7, 2013 To be clear, I meant a person could move the file to a computer, open FM, open the Script Debugger, then open the file using the script debugger to cancel the opening script then do whatever they wanted to.
Fitch Posted December 9, 2013 Posted December 9, 2013 That's why I prefaced my example script with "At the most basic level" -- you gotta start somewhere.
Recommended Posts
This topic is 4352 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