Jump to content

Recommended Posts

I use _AD_Open() in a script and a strange thing happens. The first time I logon to a computer with an active directy user login the _AD_Open() function gives @error=4 with no description of the @extended error. It just says LDAP Provider generated the error. When I log off the workstation and than log on with the same user login name the function _AD_Open() works perfectly. It seems that if the workstation has a profile of the user on the local PC, _AD_Open() works correctly but if the profile of the login user does not yet exist it gives the error. Any suggestions? I would like to make it work the first time a user logs on on a not yet used workstation. Much thx in advance for your advice.

P.S. I love the AD-extensions to Autoit; they work prefectly in the (mostly logon ) tools I've written for our domain workstations.

Link to comment
Share on other sites

  • Moderators

@WalterBaeckelmans, Welcome to AutoIt, please be mindful of where you post in the future. I have moved your question from the Examples forum (which clearly states do not post questions here) to the General Help and Support forum. ;)

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Welcom to Autoit and the forum!
According to the help file this means:

Quote

4 - Creation of the RootDSE object failed. @extended returns the error code received by the COM error handler.
      Generated when connection to the domain isn't successful. @extended returns -2147023541 (0x8007054B)

You are sure that @extended = 0?

 

3 hours ago, WalterBaeckelmans said:

It just says LDAP Provider generated the error.

Can you please elaborate on this?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

On 20-5-2016 at 11:09 PM, water said:

Welcom to Autoit and the forum!
According to the help file this means:

You are sure that @extended = 0?

 

Can you please elaborate on this?

@error=4 and @extended=-2147016646 (not -2147023541) What causes this @extended error? Thx in advance for your reply.

Link to comment
Share on other sites

The decimal @extended value stands for hex 0x8007203A which means:The server is not operational.
Do you specify to which domain controller _AD_Opens should connect to?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

Maybe the wiki describes what's going on?

Does it work when you run your script from SciTE and do you see the error when running compiled?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

On 20-5-2016 at 11:09 PM, water said:

Welcom to Autoit and the forum!
According to the help file this means:

You are sure that @extended = 0?

 

Can you please elaborate on this?

 

30 minutes ago, water said:

The decimal @extended value stands for hex 0x8007203A which means:The server is not operational.
Do you specify to which domain controller _AD_Opens should connect to?

I do not specify the domain controller to which the client should connect to because we have 2 domain controllers. I shall specify a specific domain controller and than try again to see if the error still exists. Thx for your reply. I will get in touch later on.

Link to comment
Share on other sites

30 minutes ago, water said:

Maybe the wiki describes what's going on?

Does it work when you run your script from SciTE and do you see the error when running compiled?

The script runs perfectly when I run it from SciTE but it fails when I run it compiled, just the first time after it's been compiled.

Link to comment
Share on other sites

Can you copy the compiled script to another directory and execute it from there?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...