Alpha Video Training
Results 1 to 25 of 25

Thread: Desktop Login form and user access control

  1. #1
    Member
    Real Name
    Giovanni
    Join Date
    Oct 2008
    Posts
    18

    Default Desktop Login form and user access control

    Dear all,


    I wonder if anyone of you has a sample login form and access user control to use on a desktop application.
    The login has to check a user table and password

    I've seen the Web Security module and that's nice if you use a web application.
    What I need is something similar but dedicated to a desktop application.

    Please let me know any suggestion and where is possible to find it.

    Thanks
    Giovanni

  2. #2
    "Certified" Alphaholic Keith Hubert's Avatar
    Real Name
    Keith Hubert
    Join Date
    Jul 2000
    Location
    London, UK
    Posts
    6,930

    Default Re: Desktop Login form and user access control

    Hi Giovanni ,

    Have you looked at, from menu bar, Tools->Security.

    This will do almost everything you want.
    Regards
    Keith Hubert
    Alpha Guild Member
    London.
    KHDB Management Systems
    Skype = keith.hubert


    For your day-to-day Needs, you Need an Alpha Database!

  3. #3
    Member
    Real Name
    Giovanni
    Join Date
    Oct 2008
    Posts
    18

    Default Re: Desktop Login form and user access control

    Hubert,

    thanks so much. It seems there is all what I needed.
    Bye
    Daswunder

  4. #4
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    Please advise,
    How to add this menu in Desktop runtime version?

    Thanks
    RJ

  5. #5
    "Certified" Alphaholic
    Real Name
    Tom Cone Jr
    Join Date
    Apr 2000
    Location
    Florida
    Posts
    23,311

    Default Re: Desktop Login form and user access control

    RJ,

    I don't think the runtime is permitted to set the master password for the database, or to configure the security setup. This is done using the developer version.

    -- tom

  6. #6
    "Certified" Alphaholic
    Real Name
    Raymond Lyons
    Join Date
    Apr 2000
    Location
    Carlsbad, CA
    Posts
    2,143

    Default Re: Desktop Login form and user access control

    Quote Originally Posted by Tom Cone Jr View Post
    RJ,

    I don't think the runtime is permitted to set the master password for the database, or to configure the security setup. This is done using the developer version.

    -- tom
    While it is true that you can't initially setup security in the runtime nor do I think you change the the master password in the runtime, once security is initially setup one can use xbasic and the various security functions to do all most anything using the runtime (e.g., add groups, add users, change a user password, etc.). Of course these functions in the runtime should be restricted either to the administrator or to a specified user, like the boss (else what's the point!).

    Raymond Lyons

  7. #7
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    Lyons,
    Thank u for the +ve reply. Do you have any sample login screen/user management forms for run time to share in this forum?

  8. #8
    "Certified" Alphaholic Tim Kiebert's Avatar
    Real Name
    Tim Kiebert
    Join Date
    Jul 2004
    Location
    Geelong, Victoria, Australia
    Posts
    2,785

    Default Re: Desktop Login form and user access control

    Quote Originally Posted by Tom Cone Jr View Post
    RJ,

    I don't think the runtime is permitted to set the master password for the database, or to configure the security setup. This is done using the developer version.

    -- tom
    Quote Originally Posted by Raymond Lyons View Post
    While it is true that you can't initially setup security in the runtime nor do I think you change the the master password in the runtime, once security is initially setup one can use xbasic and the various security functions to do all most anything using the runtime (e.g., add groups, add users, change a user password, etc.). Of course these functions in the runtime should be restricted either to the administrator or to a specified user, like the boss (else what's the point!).

    Raymond Lyons
    Just tested this with a currently inuse app (a copy). You can set, change and remove the master password in a runtime version. And also manipulate the users and groups. This was from the control panel. Of course normally you would lock down the control panel so the developer would need to provide the user with the appropriate mechanisms (as Ray mentiond) to access the security stuff. What the runtime does not have access to is the security settings on the actual application objects such as tables and layouts etc. Which makes sense because these are accessed at the devlopment level.

    Hope this helps
    Tim Kiebert
    Eagle Creek Citrus
    A complex system that does not work is invariably found to have evolved from a simpler system that worked just fine.

  9. #9
    "Certified" Alphaholic
    Real Name
    Raymond Lyons
    Join Date
    Apr 2000
    Location
    Carlsbad, CA
    Posts
    2,143

    Default Re: Desktop Login form and user access control

    Quote Originally Posted by Tim Kiebert View Post
    Just tested this with a currently inuse app (a copy). You can set, change and remove the master password in a runtime version. And also manipulate the users and groups. This was from the control panel. Of course normally you would lock down the control panel so the developer would need to provide the user with the appropriate mechanisms (as Ray mentiond) to access the security stuff. What the runtime does not have access to is the security settings on the actual application objects such as tables and layouts etc. Which makes sense because these are accessed at the devlopment level.

    Hope this helps
    Ah yes, but of course only when logged on as the administrator (thanks Tim). When one uses the the various security functions you can designate any user or users to be one(s) that can make all kinds of changes from the runtime.

    And Jacobr, below is security management screen shot I developed years ago but it's just a screenshot. It's xdialog and a number of my own functions (500+ lines) but it it incorporates a staff data file (phones, email addresses, etc.) and to show how one would use it would require my putting together a sample DB and I am not up to doing that right now. Plus my xdialog was done a long time ago and I think I might be embarrassed to share it today (I could do better now!). Anyway, in my system each group had different access rights to various forms, tables, operations, fields, etc.

    Raymond Lyons
    Attached Images Attached Images

  10. #10
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    Thank u both Tim and Raymond for ur valuable advice.
    Tim could you please guide me how to include that Security Menu in the application?

    thank u.

  11. #11
    "Certified" Alphaholic Keith Hubert's Avatar
    Real Name
    Keith Hubert
    Join Date
    Jul 2000
    Location
    London, UK
    Posts
    6,930

    Default Re: Desktop Login form and user access control

    Put this on a button on a form.
    Code:
    'Execute menu command: '!a5_security_option("DefineUsersandGroups")'.
    a5_security_option("DefineUsersandGroups")
    You must set a Master password first and then log back in with that password.
    Last edited by Keith Hubert; 04-04-2012 at 07:16 AM.
    Regards
    Keith Hubert
    Alpha Guild Member
    London.
    KHDB Management Systems
    Skype = keith.hubert


    For your day-to-day Needs, you Need an Alpha Database!

  12. #12
    "Certified" Alphaholic Ted Giles's Avatar
    Real Name
    Ted Giles
    Join Date
    Aug 2000
    Location
    In the Wolds, Louth, Lincolnshire, UK
    Posts
    4,409

    Default Re: Desktop Login form and user access control

    Couple of comments Renny.
    I have apps running under RunTime and the user can change their own passwords.

    Admin have a separate set of forms in a Housekeeping Menu which are accessed by a password protected button. This is where the groups and users are managed - as well as backups etc.
    You can give anyone who has a login Admin Privileges and they can change all sorts of things, but if they change the master and screw up, you will have a problem on your hands. However the situation is recoverable.

    The Master Database Password is really something that you should keep safe and secret in my view to save you grief.
    Ted Giles
    Example Consulting - UK
    .

    http://ec12.example-software.com//
    See our site for Alpha Support, Conversion and Upgrade.

  13. #13
    "Certified" Alphaholic Keith Hubert's Avatar
    Real Name
    Keith Hubert
    Join Date
    Jul 2000
    Location
    London, UK
    Posts
    6,930

    Default Re: Desktop Login form and user access control

    I totally agree with Ted.

    The answers you have here are to your original question. You must develop your own strategy as to how best control as to who does what.
    Regards
    Keith Hubert
    Alpha Guild Member
    London.
    KHDB Management Systems
    Skype = keith.hubert


    For your day-to-day Needs, you Need an Alpha Database!

  14. #14
    "Certified" Alphaholic Ted Giles's Avatar
    Real Name
    Ted Giles
    Join Date
    Aug 2000
    Location
    In the Wolds, Louth, Lincolnshire, UK
    Posts
    4,409

    Default Re: Desktop Login form and user access control

    Renny, a few people have a problem with security.
    The attached shows a seldom used way of getting the processes onto a Form. I've attached a screencast to show how easy it is.
    All the buttons - except the URL link - have been created using Action Scripting.
    Attached Files Attached Files
    Ted Giles
    Example Consulting - UK
    .

    http://ec12.example-software.com//
    See our site for Alpha Support, Conversion and Upgrade.

  15. #15
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    Ted,
    Thank u for that attachment.
    What is the password for the DBF and also which is the screen cast file?

    Renny

  16. #16
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    Ted,

    Ignore my previous mail. I did not notice the password hint earlier.

    Thanks
    Renny

  17. #17
    "Certified" Alphaholic Ray in Capetown's Avatar
    Real Name
    Ray Hendler
    Join Date
    Jan 2009
    Location
    South Africa
    Posts
    2,036

    Default Re: Desktop Login form and user access control

    Ted
    I had a look at you example, neatly put on one form.

  18. #18
    "Certified" Alphaholic Ted Giles's Avatar
    Real Name
    Ted Giles
    Join Date
    Aug 2000
    Location
    In the Wolds, Louth, Lincolnshire, UK
    Posts
    4,409

    Default Re: Desktop Login form and user access control

    Thank you Ray. Are you over the Virus now?

    Quote Originally Posted by Ray in Capetown View Post
    Ted
    I had a look at you example, neatly put on one form.
    Ted Giles
    Example Consulting - UK
    .

    http://ec12.example-software.com//
    See our site for Alpha Support, Conversion and Upgrade.

  19. #19
    "Certified" Alphaholic Ray in Capetown's Avatar
    Real Name
    Ray Hendler
    Join Date
    Jan 2009
    Location
    South Africa
    Posts
    2,036

    Default Re: Desktop Login form and user access control

    Ah! do you mean my hiatus from making a nuisance of myself here on the message board? If so...
    I got about two months behind with my own admin, no more have I a secretary, and having passed the FYE (finacial year end) at end Feb, and VAT submissions not done and a corkup of some magnitude that I created for myself and...hell, it was all Alpha's fault for keeping me distracted.
    If not what virus?

  20. #20
    "Certified" Alphaholic Ted Giles's Avatar
    Real Name
    Ted Giles
    Join Date
    Aug 2000
    Location
    In the Wolds, Louth, Lincolnshire, UK
    Posts
    4,409

    Default Re: Desktop Login form and user access control

    Nope. You said you were sufferin Man Flu or some such in a post just before you installed at the farm.
    Ted Giles
    Example Consulting - UK
    .

    http://ec12.example-software.com//
    See our site for Alpha Support, Conversion and Upgrade.

  21. #21
    "Certified" Alphaholic DaveM's Avatar
    Real Name
    Dave Mason
    Join Date
    Jul 2000
    Location
    Hudson, FL
    Posts
    6,026

    Default Re: Desktop Login form and user access control

    Remember, I wrote my own security before alpha had one!
    This portion may help someone get an idea of what is entailed.

    My LogIn that may help someone:
    Preface it with a pic of the information gathered into global variables at beginning of app start:
    Users information:
    Attachment 31654
    Company information:
    Attachment 31655
    Each user record is gleaned into memory along with the company needed.

    This code is run to get the user name and password:
    DIM global scode as C
    DIM global pword as C
    DIM global PrintDailyReport as C
    DIM SHARED varC_result as C
    printlist = "N"
    footer_string = "Check the print box if you want to print the reports."
    ok_button_label = "&OK"
    cancel_button_label = "&Cancel"
    varC_result = ui_dlg_box("Startup Check",<<%dlg%
    {region}
    User Code:| [.25scode];
    password:| [%p%.25pword];
    {region}Print List Daily Reports?:{endregion}|
    {region}(PrintDailyReport:Y)
    (PrintDailyReport:N){endregion};
    ;
    {endregion};
    {region}
    {text=30,2:footer_string};
    {endregion};
    {line=1,0};
    {region}
    <15=ok_button_label!OK> <15=cancel_button_label!CANCEL>
    {endregion};
    %dlg%)

    The passwords are checked to see if real person and they go in or they go out.
    Dave Mason
    dave@aldausa.com
    Skype is dave.mason46

  22. #22
    "Certified" Alphaholic
    Real Name
    Jetson Lilibeth
    Join Date
    Dec 2011
    Posts
    1,093

    Default Re: Desktop Login form and user access control

    Dave, do you have a sample of your log in and security control, that is exactly what i want to implement so that the admin of the end user or client can assign add and assign permissions to new and existing users or groups, I know this can be done in the control panel but i don't want the user to do that in the control panel, I think it is better to be in a form like the one you did.Thanks!

  23. #23
    Member
    Real Name
    Renny Jacob
    Join Date
    Mar 2012
    Location
    Dubai
    Posts
    117

    Default Re: Desktop Login form and user access control

    How do I Enable/Disable (Show/Hide) a button in form depends on the group of the login user?

  24. #24
    "Certified" Alphaholic Stan Mathews's Avatar
    Real Name
    Stan Mathews
    Join Date
    Apr 2000
    Location
    Bowling Green, KY
    Posts
    25,119

    Default Re: Desktop Login form and user access control

    Code the onactivate event for the form something like (having gotten the user group into a global variable when they logged in)

    Code:
    dim global user_group as C
    if user_group = "A"
    	button1.object.visible = .F.
    else
    	button1.object.visible = .T.
    end if

  25. #25
    "Certified" Alphaholic DaveM's Avatar
    Real Name
    Dave Mason
    Join Date
    Jul 2000
    Location
    Hudson, FL
    Posts
    6,026

    Default Re: Desktop Login form and user access control

    I do not use the alpha security system since I had already made my own and still prefer mine. I did have a bit of help from people on this forum to get it right.

    Dave, do you have a sample of your log in and security control, that is exactly what i want to implement so that the admin of the end user or client can assign add and assign permissions to new and existing users or groups, I know this can be done in the control panel but i don't want the user to do that in the control panel, I think it is better to be in a form like the one you did.Thanks!
    It is for sale on the site www.lotrun.com . Download the one for single sales person and open it up. This is version 7 right now, but has been transferred to v10.5 without any changes.

    Call, email or pm me if you need more help.
    Dave Mason
    dave@aldausa.com
    Skype is dave.mason46

Similar Threads

  1. Control Panel as Desktop
    By burtnco in forum Archived Wishlist
    Replies: 2
    Last Post: 12-08-2006, 09:06 AM
  2. USER or ADMIN LOGIN ?
    By den1s in forum Web Application Server v7
    Replies: 17
    Last Post: 03-03-2006, 04:12 PM
  3. Specify user login
    By Imran Ahmad in forum Alpha Five Version 5
    Replies: 2
    Last Post: 06-05-2003, 06:39 AM
  4. User login with runtime
    By Robert Mann in forum Alpha Five Version 5
    Replies: 3
    Last Post: 10-25-2002, 11:51 AM
  5. User Login
    By Sean Tucker in forum Alpha Five Version 4
    Replies: 5
    Last Post: 11-07-2001, 05:43 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •