January 18, 200718 yr Hello, I have a table in a database that contains, user name, passwrod, and priveledge set. How can I have Filemaker use this, so I do not have to input all 400+ users manually?
January 18, 200718 yr You should use the built in Accts and & Privs functionality of FM. Why would you want to store that kind of data in a table? It is not secure. If the tediousness of manually entering all those 400 users is what is bothering you, then why not write a loop to do it for you? All you would have to do is create the priviledge sets that you need first. Then do a find for all users of each privilege set and run your loop script, referencing your user and password fields in conjunction with the Add Account script step.
January 18, 200718 yr Author That worked flawlessly! I did not explore the account script steps before. Is there a way to assign the privledge set through a script as well?
January 18, 200718 yr No, but if you create the privilege sets first, and then do the find for each privilege set, all you really have to do is change the option in the Add Account step to whatever Privilege set that you want. So when it runs the loops to create all those accounts, it will assign all thuose found records with the privilege set. This might take a few minutes, but its better than manually changing all 400 accounts' privilege set.
January 18, 200718 yr Author I can not believe I missed the obvious. If I use an IF statement referenceing the privledge set field, I can essentially script the assignment of privledge sets.
January 18, 200718 yr Oh that is right, you have a field in the table already that has a privilege set name. As long as the values match up then yes you technically can automate the entire thing. Good job.
January 18, 200718 yr Author I have a field set with Radio Buttons of the possible Privledge Sets, and if (IsEmpty) then it deletes the record and exits. Can you give me other examples of errors I should trap for?
January 19, 200718 yr You need to trap for duplicate Account Names and for failures of the script to execute. Steven
Create an account or sign in to comment