Plex 2E

  • 1.  Validating Active Directory UserID

    Posted Jan 05, 2015 02:08 PM

    Hi,

     

    I've been developing in CA Plex for going on 2 years now. I am writing a program that needs to validate a userID against what we have in our active directory. Does anyone know an easy way to do this? At the moment I am using an API Start Executable program that runs this command " dsquery user domainroot -o samid -name &(3:) > checkuser.txt"   If the query finds the user it will write the name to the text file and allows the program to continue.

     

    Does anyone know an alternate way to validate a windows userid/active directory user from ca plex easily? Sorry I am a newbie.  I am using Plex r6.1



  • 2.  Re: Validating Active Directory UserID

    Posted Jan 05, 2015 04:58 PM

    Using an FSO and ReadFile VB Script... Thanks



  • 3.  Re: Validating Active Directory UserID

    Posted Jan 06, 2015 05:07 AM

    Wow a newbie..didn't think such people existed. Can I ask at what company? Welcome anyway

     

    use this link to search these plex communities for 'active directory'

    https://communities.ca.com/search.jspa?q=active+directory&place=%2Fplaces%2F1070

     

     

    the answer looks like Re: Active Directory



  • 4.  Re: Validating Active Directory UserID

    Posted Jan 06, 2015 12:55 PM

    another old resource for plex questions is Edge Forum Archive - [Edge] Advantage Plex Family - VB to Java Servlet

     

    Maybe Gavin can help as Bodo helped him back in 2002



  • 5.  Re: Validating Active Directory UserID

    Posted Jan 06, 2015 04:37 PM

    Hi Alex,

    Agree with you on using a low level API. In your case, by means of FSO. We are working with a Java variant, and used a java source code, a low level solution also (by means of javax.naming.* classes). Maybe you could explore Active Directory Services to review current Microsoft alternatives. I would suggest you on using source code, to document your solution (source of your solution, version of native language used, and grouping your related source code in subject areas, in order to locate them when required). Native APIs are out of the scope of Plex, and you need to review it when technology changes, both on the Plex side and on the native language side. Do not worry: important changes only happens very rarely, but better if you are aware about both worlds follow its own paths.

    Jorge Ubeda



  • 6.  Re: Validating Active Directory UserID

    Posted Jan 07, 2015 02:48 AM

    You could look at importing the Active Directory Service Interfaces via the component import wizard, having not used this component I cant tell you the pitfalls but when ever possible I use the component import as a solution instead of writing source

    AIDS.png

     

    BUT Plex IDE crashes when trying to Generate the Package: ActiveDs10 so I guess thats a bust idea..

    bust.png



  • 7.  Re: Validating Active Directory UserID
    Best Answer

    Posted Jan 26, 2015 05:02 PM

    haha yes definitely still a newbie!!! and I found a few different ways to go about it other than the way i said above.

     

    Can do the original way I had, which involves more than one API / VBscript call, or simply

     

     

     

    "

    Dim objFSO

    Dim objFile

     

    Set objFSO = CreateObject("Scripting.FileSystemObject")

    Set objFile = objFSO.GetFile("PARAMETER HERET")

    If objFile.Size > 0 Then

        Set objReadFile = objFSO.OpenTextFile("PARAMETER HERE", 1)

        strContents = objReadFile.ReadAll

        objReadFile.Close

                Response = MsgBox(strContents & "was found!")

    Else

                Response = MsgBox(&(1:) & "was not found!")

    End If

     

     

    set ObjFSO = Nothing

    Set objFile = Nothing

     

    "

     

     

    Thanks for the feedback none the less.