- Ashutosh Varshney
- PowerBuilder
- Thursday, 19 March 2020 08:09 PM UTC
Hello Everyone,
I have an application with uses AD authentication to grant access. It does not work when the user is connected thru VPN. It fails when I call objADSI.UserName - "Error accessing object property username". Any idea how to make it work for VPN as well? Here is my code:
OleObject objADSI, objADUser
Try
objADSI = CREATE OleObject
li_Rtn = objADSI.ConnectToNewObject ('ADSystemInfo')
If li_Rtn = 0 Then
ls_UserDN = String (objADSI.UserName)
End If
Catch (oleRuntimeError l_Err)
ls_Err = 'AD Error~r~n~r~nSource: ' + l_Err.Source + '~r~n' + l_Err.Text
End Try
Return
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.