Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

Adding Users With a Web Component

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Adding Users With a Web Component

    OK, don't mean to be a pain, but I keep hitting my head up against a wall and I thought I'd ask my question again, in a different way.

    Is there anyone out there who has used the component described in the wiki page entitled "Adding Users With a Web Component" in conjunction with the a5ws_get..... web security functions?

    What I am seeing is that the dialog adds the users properly (I'm saving User ID, Groups and a Ulink), and creates a GUID. That is, when I use the Web Security Users and Groups dialog (after pulling the files from the web location) or when I add the websecurity tables and browse them, all the data is there. HOWEVER, when I try to use, for example, the a5ws_get_user_assignments function I empty string is returned (whether via Xbasic code in a page or with the interactive window). I understand about the various locations for the user tables but, as I say, I am looking essentially at BOTH locations (web and local) and the info is there. I also sometimes can't pull the ULINK via GUID. This problem does not exist if I add Users through the Users and Groups dialog or if I use that dialog to manually enter the data into the problematic users (i.e. the ones I added through the web component). I can't figure out WTH is going on.

    So if someone out there uses this "Web Component" dialog together with those functions, successfully, then I know it's me or my setup. I swear, looking at the user data either directly in the security tables or the Users and Groups dialog, everything LOOKS fine. The info just doesn't pull when using a5ws_get_....

    Thanks for any assistance.

    #2
    Re: Adding Users With a Web Component

    I will try to give you some things ideas to consider. I am not familiar with the procedure you are referring to. I am using MySql tables with active link dbf security tables. I had some issues with getting that set up.

    The security tables on the local machine get published to the servers web root. That is where the data is read and used in the security framework. So if you want to see changes immediately then you have to edit the security tables on the server. But keep in mind if you don't make the data in the local table match the data in the server tables and you republish, the security tables on the server is overwritten and any changes there will be lost.

    Then there is the issue of cache, great for serving data, bad for developing and troubleshooting. I had to stop and start the server often while I was sorting out the issues I was having.

    You probably already know all of that. I hope that gives you some help and not confusion.
    Win 10 64 Development, Win 7 64 WAS 11-1, 2, Win 10 64 AA-1,2, MySql, dbForge Studio The Best MySQL GUI Tool IMHO. http://www.devart.com/dbforge/mysql/studio/

    Comment


      #3
      Re: Adding Users With a Web Component

      I would be interested too in this.

      Thanks

      CJ

      Comment


        #4
        Re: Adding Users With a Web Component

        When working with security functions, the context is extremely important.

        A security function run on the desktop will give different results than the same function run from a web page or component. The desktop looks at the data in the local project, while the web looks at the data on the server.

        Most security function require that the system web variables "request", "session", and "response" are supplied to the function. If the web security functions are placed directly on a page, or in a dialog component server event, Alpha Five will automatically supply the variable values to the function, and the user does not have to add them. However, if the functions are run from a grid server event, they must be supplied.

        The V10 release notes for build 2515 show how to reference the variables correctly in grid events

        Comment


          #5
          Re: Adding Users With a Web Component

          This may not be of much help... but...

          I spent a LOT of time trying to use the approach that you are trying to implement.

          I just couldn't get it to work the way i wanted.

          So... i reexamined the application & decided that what i wanted to accomplish with the creation/deletion of users/passwords could be accomplished with simple filters and a User_Pwd table.

          One of the main things that i wanted to accomplish was to filter user records for the user currently logged on ie using Session.__protected__uLink as an argument in a filter for each relevant grid.

          I accomplished this by having all users of a particular category (in my case 'patients') log in with the same username & password. This allows the nav components to present only those menu items / pages that are relevant to all patients.

          After login i redirect the user to a page with a dialog component that allows input of a user number & password. The dialog code places these values in Session variables. i use these Session variables to filter the grids that the user has access to.

          The username & password entered in the dialog must exist in a table that stores these values... i check this in the validation code.

          The table with the username/password records may be populated by using a grid that you allow, all or a category of, users access to.

          It sounds a bit convoluted but it is really quite easy.

          Hope this helps.

          Comment


            #6
            Re: Adding Users With a Web Component

            Thanks to all who answered. Some specific responses:

            David: I actually needed to filter a grid based on the ULINK of the currently logged in user and display that user's username on the web page. I couldn't get it to work right until I spied a bit of code posted here by someone (sorry I forgot who, but thanks, maybe it was you?) called logincheck (or something like that) which retrieved user values and set the session variables. I've got that working fine.

            Jerry: I have the a5w_get_user_assignments() (I think that's the specific function) as well as a5ws_get_ulink_from_guid (ditto) on a web page, the same page with the web component. I add a user through the component and when the page redisplays the new user's ID IS listed but the remaining info (ULINK and Groups) appears only erratically. Sometimes the assignments will be returned (and display) but not the ULINK, sometimes the other way around, sometimes neither. I altered the table on the page to show the GUID as well and the new user's GUID always is returned, however. I added the security tables in the web root (not the local ones) to the project and when I open them up the new user is there along with the proper groups and ULINK. It just seems that the a5ws functions that return ULINK (via GUID) and assignments don't find the info in the security tables when the user is added through the web component (again, even though I've confirmed it's there by looking at the security tables in the webroot). I've even searched to see if there are ANY security tables other than in the web root or local folder and there aren't.

            Any help you can offer would be appreciated.

            Comment

            Working...
            X