• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

calling (VB)activex object from JSP

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am trying to call a ActiveX object from JSP using the ActiveXObject method in javascript. I have a dll filed named LPMSFunctions.dll which is registered and is being passed as an argument to the ActiveXObject method. Below is the code i am trying to execute..




When i write the above code and save it as an html file it works fine..the activex object is created and the methods are called , but when i copy the same code to a file and save it as jsp file under webapps folder under tomcat it doesnt work and reports a javascript error with the error being:

Automation server cant create the object at line :
var SSOObj = new ActiveXObject("LPMSFunctions72.LPFunctions72");

Please suggest how can I solve the problem. Your help would be sincerely appreciated.

Thanks
shravan
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
where are ou running the html file? On the desktop rather than on a web server?

If that is the case Automation server cant create the object nornally means that ActiveX is disabled. Check the settings for the Security Zone that you are in.

Eric
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Look at the output from your JSP and see if it is any different from what's in your static HTML file.

If there is no difference, it may be a security issue.
When you call the HTML file are you calling it as a local file?
For instance:
c:\my projects\testfile.html
?

If so, MSIE may be allowing local pages instanciate the activeX object but not pages generated from requests to outside servers (localhost would still count as an outside server as far as the browser is concerned).
 
shravan kodam
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank You for your replies....

Yes, I am runnning the .html file from my desktop.

But when i try it to deploy the .html file thru the app server. I am getting an alert message saying "ERROR".

Can you give me any way of how to resolve this.

Thanks,
Shravan
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by shravan kodam:
Thank You for your replies....

Yes, I am runnning the .html file from my desktop.

But when i try it to deploy the .html file thru the app server. I am getting an alert message saying "ERROR".

Can you give me any way of how to resolve this.

Thanks,
Shravan



Originally posted by Eric Pascarello:

If that is the case Automation server cant create the object nornally means that ActiveX is disabled. Check the settings for the Security Zone that you are in.



Look at the browser settings as I already mentioned before.

Eric
 
shravan kodam
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Eric,

Can you help me in getting the browser settings? Where should i exactly look at? Please help me. I have no idea abt this.

Thanks,
Shravan
 
reply
    Bookmark Topic Watch Topic
  • New Topic