Quote:
Originally Posted by mat41
Using windows scheduled tasks (or cron jobs is think they are called in unix) are the unattended way to fire things. It gets fired without user interaction on a schedule. E.G daily at 6pm. This is not an option if you need your batch file to fire based on an end user action. Your code/approach is what I would do if I had this requirement.
To be honest in all my years classic ASP I have never needed to use a .bat file for anything. Can you not achieve your objective in a .asp file? Why does it need to fire a .bat file.
Lastly - I cant help you with your code. It looks good to go to me. Without an error or a specific issue I doubt may could
|
Hi Matt,
Thanks for your reply.
I need actually to get some value from LDAP browser. For the one ASP page is using a batch file that calls Jar file to communicate and fetch data from LDAP. Batch file execution and getting value from LDAP was working fine in IIS 6 and Win 2003 sever, but may be some system update it stopped working. So, trying to find out the solution.
Now trying to communicate the LDAP server directly through ASp code:
var ldapurl = "LDAP://v******:**9/";
var ldapcontxt = "ou=***,ou=****,o=****,c=**";
var LDAPServerString = ldapurl + ldapcontxt;
var ldapuser = "cn=****,ou=****,ou=***, o=****,c=****";
var ldappwd = "********";
var objCommand = Server.CreateObject("ADODB.Connection");
objCommand.Provider = "ADsDSOObject";
objCommand.Properties("Encrypt Password") = 0;
objCommand.Open ("ADs Provider",ldapuser,ldappwd);
var strADOQueryString = "SELECT *****";
strADOQueryString += " FROM '"+Application("LDAPServerString")+"' ";
While running this piece of code is giving error:
Provider error '80040e37'
Table does not exist.
it's coming from this piece of code:
var strADOQueryString = "SELECT *****";
strADOQueryString += " FROM '"+Application("LDAPServerString")+"' ";
With the same properties and credentials I can see data through LDAP browser.
May you help?
Thanks,
senp