Calling methods located inside ActiveX objects from Java

Hi folks,
I understand that I can wrap ActiveX methods in C and call using JNI, but I am looking for an elegant way to call methods inside of Active X controls directly. There are a set of classes in com.ms.ActiveX package that allow this, but I am receiving a java.lang.UnsatisfiedLinkError: initPolicyEngine at runtime. I can't find any documentation from Microsoft on this (go figure). Has anyone ever used the com.ms packages, or does anyone know of an elegant solution avoiding wrappers and JNI? I have sucessfully used the neva objects vendor classes, but I find them too bulky for mainstream use. Any thoughts are appreciated. Thanks.

Hi,
- If you use the package com.ms.* You'll need to run your application in the Microsoft VM (jview.exe).
- If you run it inside the browser you cannot use the java plugin, and your applet needs to be signed.
If this doesn't help, please provide the version of your msjava.dll.
Regards,
Kurt.

Similar Messages

  • Calling inactive version of ABAP object from Java

    Hello,
    When I call an ABAP object from Java Program which version of ABAP object is called inactive or active ?
    Is there a mechanism to call the current inactive version or any other previous inactive /active versions ?
    Regards,
    Tarun

    Only the "active" version of ABAP code is active and runnable.
    You cannot run inactive versions. Like you have to compile a .java file to a .class file o make it runnable in the JVM.

  • Access to a method located in view object from JSP page?

    Hi,
    How can i access a public method which is loacted in view
    object "viewobjectImpl.java" from JSP page.

    Juan,
    Either via Data tags or/and Java embedded code.(<%...%>).
    This method, suppose to execute a stored procedure.
    Thanks

  • Calling (VB)activex object from JSP

    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..
    <html>
    <head>
    <title>Script Example</title>
    </head>
    <body>
    <br><br>
    <P align="center">
    <form action="" method="post">
    <script language="JavaScript">
    function comEventOccured()
    try{
    var myobject;
    myobject = new ActiveXObject("LPMSFunctions72.LPFunctions72");
    alert("Inside LPMSFunction72");
    alert(myobject.GetDocPath());
    catch(e)
    alert("Error");
    </script>
    </form>
    </body>
    </html>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

    You want to use the Variant to Data node, wiring in an ActiveX constant configured to the interface type you want.
    Brian Tyler
    http://detritus.blogs.com/lycangeek

  • Returning objects from Java stored procedures

    I need to pass an object from Java to a Java SP which updates the object and returns the object back. The Java SP will be calling a PL/SQL procedure which returns some nested tables that I want to stick into the passed object.
    I tried using "IN OUT" for the object in the call spec but got an error that it was not "appropriate for the parameter". So, the next option seems to be to pass it in and then return it from the Java SP. I'm just wondering though what the the best approach for accomplishing this? I've looked through some of the sample code on the OTN but haven't found anything yet that really helps.

    I am trying to use custom object classes. I have setup a type map for the connection and my custom class implements SQLData. Yet, when my client tries to call the Java SP, it gets ORA-00932 complaining of inconsistent data types (expected IN conversion failed).
    I turned on some debug info (i.e. oracle.jdbc.sql=true) but it didn't provide any useful info in regards to why I'm getting this error. Unfortunately, the JDBC Developer's Guide does not provide full examples of the code.

  • Nwdi-managed access of pcd-objects from java web dynpro

    Hi,
    im am trying to access portal pcd-objects from a java web dynpro component (namely getting and setting personalized iview properties). for locally managed web dynpro components this works fine with the code below.
    when i try the same with a nwdi managed web dynpro component i run into problems regarding references to used dcs. for instance, i need to reference used dc SAP_JTECHS/tc/epbc/pcm/adminapi/java because the build needs tcepbcpcmadminapijava.jar which is inside the mentioned dc. but access permissions of this dc don't allow the dependency. when i try to "add used dc ..." in nwds i get the error message: illegal dependency: access list does not allow use of ...
    has someone any solution for this problem? are there other ways of accessing pcd-objects from java web dynpro (nwdi managed!)?
    thanks
    heiko
    private static void savePersonalizationData(String value) {
         try {
              IAttributeSet attributeSet = (IAttributeSet) getIview(IVIEW);
              attributeSet.putAttribute(ATTRIBUTE, value);
              attributeSet.save();
         } catch (Exception e) {
    private static Object getIview(String pcdPath) throws Exception {
         Hashtable env = new Hashtable();
         env.put(
              com.sap.portal.directory.Constants.REQUESTED_ASPECT,
              com.sap.portal.pcm.admin.PcmConstants.ASPECT_SEMANTICS);
         env.put(
              Context.SECURITY_PRINCIPAL,
              WDClientUser.getCurrentUser().getSAPUser());
         env.put(
              IPcdContext.PCD_PERSONALIZATION_PRINCIPAL,
              WDClientUser.getCurrentUser().getSAPUser());
         InitialContext iCtx = new InitialContext(env);
         return iCtx.lookup(pcdPath);

    Hi Kust,
    To access the PCD objects the code you used looks ok for me but your main issues is related to the dc access permissions. This thread discussed about the similar issue. Please review this below thread.
    /message/979328#979328 [original link is broken]
    Regards
    Krishna Reddy

  • Error calling method of a PBNI object

    Dear All,
    We are facing issue of "Error calling method of a PBNI object". We are calling web services of WCF after some time to refresh data.We need help to solve this issue as we have to go live with client.
    It's really urgent!
    Regards
    Imran Zaheer

    Hi Chris,
    Thanks for your concern.
    1) PB version & Build?
         PB builder 12.5.2 build 5609
    2) MS-Window version?
         Windows 7 professional.
    3) Why are you using PBNI and what kind of class are you utilizing in that context?
         We are calling webservices through soap objects.
    4) What error(s) codes and messages are you getting?
        we get "Error calling method of a PBNI object"
    5) Why are you not using PB.net that supports WCF natively (I wish PB classic did)?
        For this we need to convert our whole application in PB.Net which is not feasible for us.
    6) Can you lightly describe your over-all architecture and application approach to Web Services?
         We have replace EASERVER with WCFserver and we are calling webservices for fetching( pulling) data from WCF server. It's a soft of 3 tier architecture.
    Regards .... Imran

  • Cannot Acccess Applet Object from Java Script

    Hi,
    I am using jRE1.5, and Kava Chart Applets. Those applet jars are compiled in jdk 1.5 version. I have created one jsp where I used ,<applet> tag. The problem is when ever I am going to access the applet object from java script it is not returning the actual java applet object, when put an alert message it shows [object]. So i am not able to access the methods or the applet class.and also the screen gets hung, nothing is coming.It get stuck at the point where i tried to access the applet method like document.getElementById(applet_id).<<<some method of the applet class>>.Also it is not showing any kind of javascript error or Applet class exceptions.
    But the strange thing is, when i use jdk 1.6, the page is running fine.Also when i try to print the applet object from javascript it is showing the proper class name.
    Please help me solving the problem.

    A number of changes and improvements were made between 1.5 and 1.6 - the entire plugin is new. You need to change to 1.6, as 1.5 goes EOL about November this year and future changes to this area in 1.5 are unlikely.

  • Call a function inside a package from a stored procedure

    Hello:
    I am kind of new to the stored procedure. Does anyone know how to call a function inside a package from another stored procedure?
    I have a existing function (func_b) inside a package (pack_a) and it returns a cursor. I want to call this function from a stored procedure (proc_c) so that I use the data inside the cursor.
    can I do the following in proc_c:
    my_cursor1 SYS_REFCURSOR;
    begin
    my_cursor1 := exec pack_a.func_b
    end
    It will be very helpful if anyone can point me to any reading or example. Thank you very much for your information.

    guys:
    Thank you for your information so far. I need some more help here. I was able to run the function in my stored procedure. However, I was not able to print the result on the screen to view the cursor result, although I am using dbms_output.put_line statement inside my stored procedure.
    I use the following statement to execute my stored procedure on sql*plus. I can tell the stored procedure is executed successfully, but I did see anything printed:
    DECLARE TEMP VARCHAR2(100);
    BEGIN PROC_LAWS_CAD_NAME_SEARCH('LPD', 'TEST DEVICE ID', 'TEST LAST NAME', 'TEST FIRST NAME', 'F', '11112009', TEMP); END;
    I tried to use 'set serveroutput on' and got the following error:
    ERROR:
    ORA-06502: PL/SQL: numeric or value error: host bind array too small
    ORA-06512: at line 1
    I am kind of confused now. thank you for your help.
    Jack
    Here is my procedure:
    create or replace
    PROCEDURE PROC_SEARCH
    ( AGENCY_ID IN VARCHAR2,
    DEVICE_ID IN VARCHAR2,
    L_NAME IN VARCHAR2,
    F_NAME IN VARCHAR2,
    SEX IN VARCHAR2,
    DOB IN VARCHAR2,
    CAD_NAME_SCH_RESULT_STR OUT VARCHAR2)
    AS
    v_agy_id varchar2(10);
    v_device_id varchar2(20);
    v_l_name varchar2(25);
    v_f_name varchar2(15);
    v_sex varchar2(1);
    v_dob date;
    -- this cursor is going to be used to store a list of warrant matching
    -- name search criteria
    cad_srch_cursor sys_refcursor;
    objSrch SEARCH_RESULT_TEMP%ROWTYPE;
    BEGIN
    cad_srch_cursor := SEARCH_PKG.SEARCH('TESTING', 'TESTER', null, null,null, null, getPhonetic('TESTING'));
    LOOP
    FETCH cad_srch_cursor INTO objSrch;
    EXIT WHEN cad_srch_cursor%NOTFOUND;
    --insert into SEARCH_RESULT_TEMP (name_last) values (objSrch.name_last);
    CAD_NAME_SCH_RESULT_STR := objSrch.name_last;
    dbms_output.put_line('First:'||objSrch.name_first||':Last:'||objSrch.name_last||':Middle:'||objSrch.name_middle);
    end LOOP;
    END PROC_LAWS_SEARCH;
    -----------------------------------------

  • Error: Permission denied for (document.domain has not been set) to call method Location.toString on (document.domain=).

    Why am I getting these errors Error: Permission denied for (document.domain has not been set) to call method Location.toString on (document.domain=).
    == URL of affected sites ==
    http://

    HOW DO YOU SET THIS??? I'M FRUSTRATED OVER THIS. ITS BEEN 2 MONTHS SINCE I HAVE BEEN ABLE TO PLAY ANY GAMES IN FACEBOOK DUE TO THIS PROBLEM! IT DOES NOT MATTER WHAT BROWSER I USE I STILL GET THIS SAME MESSAGE.

  • Call Windows COM/DCOM objects from Java on Linux

    Hello, is it possible to call COM/DCOM objects running on Windows from Java on Linux machine? Thank you.

    I don't know anything about it but it looks like EZ JCom in conjunction with the included Remote Access Service does what you're after. It's not free though.
    http://www.ezjcom.com/

  • Calling method of a custom infotype from ABAP

    Hi Experts,
    I am working on an application where i need to call a method of a custom defined infotype.
    I have done this -->
    1. Create a custom infotype 9111
    2. SAP creates a class of that infotype ZCL_HRPA_INFOTYPE_9111
    3. Inside this method there are few inherited method which provide me functionality of insert , update , delete
    i want to call methods IF_HRPA_INFTY_BL~MODIFY,
    IF_HRPA_INFTY_BL~INSERT
    However when i call these method from abap report this method does not work.
    where as when i try to insert an entry using PA30 transaction it works.
    Does anyone know why does this happen and what is the solution?
    Regards,
    Ashish Shah

    Had the same problem (probably copied from the same program). The answer is that you need to commit the work at the end using something like
    * Commit
    CALL METHOD busilog->flush
      EXPORTING
        no_commit = space.
    Here is an example of my code for IT0002 which works.
    *& Report  Z_TEST2
    REPORT  z_test2.
    DATA: a_masterdata_bl TYPE REF TO if_hrpa_masterdata_bl,
          p0002         TYPE p0002,
          lo_0002 TYPE REF TO cl_hrpa_infotype_0002,
          ls_p0002_ref TYPE REF TO data,
          container_tab    TYPE hrpad_infty_container_tab,
          container  TYPE REF TO if_hrpa_infty_container,
          message_handler TYPE REF TO cl_hrpa_message_list,
          infotype_logic TYPE REF TO if_hrpa_infty_bl,
          update_mode TYPE hrpad_update_mode VALUE 'XXX',
          lt_0002_container TYPE REF TO cl_hrpa_infotype_container,
          key TYPE pskey,
          l_is_ok          TYPE boole_d.
    FIELD-SYMBOLS <p0002> TYPE p0002.
    * get business logic from masterdata factory
    CALL METHOD cl_hrpa_masterdata_factory=>get_business_logic
      IMPORTING
        business_logic = a_masterdata_bl.
    * CATCH cx_hrpa_violated_assertion .
    *ENDTRY.
    *TRY.
    CALL METHOD a_masterdata_bl->read
      EXPORTING
        tclas           = 'A'
        pernr           = '508'
        infty           = '0002'
        begda           = sy-datum
        endda           = sy-datum
        no_auth_check   = 'X'
        message_handler = message_handler
      IMPORTING
        container_tab   = container_tab
        is_ok           = l_is_ok
    * CATCH cx_hrpa_violated_assertion .
    *ENDTRY.
    READ TABLE container_tab INTO container INDEX 1.
    lt_0002_container ?= container.
    TRY.
        CALL METHOD lt_0002_container->primary_record_ref
          IMPORTING
            pnnnn_ref = ls_p0002_ref.
      CATCH cx_hrpa_violated_assertion.
    ENDTRY.
    ASSIGN ls_p0002_ref->* TO <p0002>.
    MOVE-CORRESPONDING <p0002> TO key.
    break stantric.
    <p0002>-vorna = 'Rick'.
    container ?= lt_0002_container->modify_primary_record( <p0002> ).
    TRY.
        CREATE OBJECT lo_0002
          EXPORTING
            tclas = 'A'
            infty = '0002'.
      CATCH cx_hrpa_violated_assertion .
    ENDTRY.
    CREATE OBJECT message_handler.
    TRY.
        CALL METHOD lo_0002->get_specific_bl
          EXPORTING
            versionid      = '01'
            tclas          = 'A'
            pskey          = key
          IMPORTING
            infotype_logic = infotype_logic.
      CATCH cx_hrpa_violated_assertion .
    ENDTRY.
    TRY.
        CALL METHOD infotype_logic->modify
          EXPORTING
            old_container   = lt_0002_container
            massn           = space
            massg           = space
            update_mode     = update_mode
            no_auth_check   = 'X'
            message_handler = message_handler
          IMPORTING
            is_ok           = l_is_ok
          CHANGING
            container       = container.
      CATCH cx_hrpa_violated_assertion .
    ENDTRY.
    * Commit
    CALL METHOD a_masterdata_bl->flush
      EXPORTING
        no_commit = space.

  • Can u access Oracle9i Reports objects from Java Code?

    Hi,
    How can you access Oracle9i Reports (Rel 2) objects like Body, DataSource, Groups etc from Java Code?
    What are the available APIs?
    I went thru the APIs at http://otn.oracle.com/products/reports/htdocs/getstart/docs/Javadocs/oracle/reports/plugin/definition/package-summary.html
    However various constructors stated in these APIs are using classes from "oracle.reports.definition" package which are difficult for me to locate.
    For eg. Report constructor is using oracle.reports.definition.RWReport and there is no API documentation available for RWReport class.
    Please suggest me the site for the above APIs or the method to get a reference to "Report" instance.
    Thanks
    Rakesh.

    Thanks Tugdual for your quick reply.
    Thats exactly what I am trying to do. I want to develop a utility which can have a subset of Report Developer's functionality.
    Currently using Reports Developer & Report Wizard, I can create a report by providing SQL statement and few parameters (like Report Style, Calculated Fields, Template file etc). I want to put all these parameters in a XML file and run my java utility (based on the APIs which I am looking for) which will use these XML parameter file and generate a '.rdf' file.
    Also, could you please suggest me the site for oracle.reports.definition package API or the way to get a reference to oracle.reports.plugin.definition.Report instance.
    Thanks,
    Rakesh

  • Issues in mapping objects from java to flex - using flex4

    Hi,
    I have a class in java which i want to send to flex4 using BlazeDS as middleware. There are a few issues that i am facing and they are:
    When sending the object across (java to flex), the properties with boolean data type having value as true gets converted to properties with value as  false. Even after setting the value to true it still comes as false on flex side. Can't understand why this is happening.
    When sending the list of object containing property with boolean data type, the object on flex side does not show those properties at all. As of there were no boolean properties in that object.
    Last but not the least, When sending List<ContractFilterVO> contractFilterVOs to flex using remote call, the result typecasted to ArrayCollection does not show the holding objects as ContractFilterVOs but as plain default Object though having all the properties send, except the boolean one mentioned in above points. Basically it is not able to typecast the objects in arraycoolection but the same objects gets typecasted when sent individually.
    In all the above points i am using Remote Service through BlazeDS for connectivity with Java. I have done a lot of this stuff in Flex 3 but doing it for the first time in flex 4, is there anything that Flex 4 needs specific. Below is the pasted code for reference purpose.
    Flex Object
    package com.vo
         [RemoteClass(alias="com.vo.ContractFilterVO")]
    public class ContractFilterVO{
         public function ContractFilterVO(){
         public var contractCode:String;
         public var contractDescription:String;
         public var isIndexation:Boolean;
         public var isAdditional:Boolean;
    * Rmote Part of code
    var remoteObject:RemoteObject = new RemoteObject();
    remoteObject.destination="testService";
    remoteObject.addEventListener(ResultEvent.Result,handleResult);
    public function handleResult(event:ResultEvent):void{
         var contarctFilterVOs:ArrayCollection = event.result as ArrayCollection; //Point 2&3 probelem, if list sent form java
         var contarctFilterVO:ContractFilterVO= event.result as ContractFilterVO; //Point 1 probelem, if only single Object of type ContractFilterVO sent form java
    Java Object
    package com.vo
    public class ContractFilterVO implements Serializable 
         public function ContractFilterVO(){
         private static final long serialVersionUID = 8067201720546217193L;
         private String contractCode;
         private String contractDescription;
         private Boolean isIndexation;
         private Boolean isAdditional;
    I don't understand what is wron in my code on either side, it looks syntactically right. It would be great anyone could help me point out my mistake here. Waiting for right solutions...
    Thanks and Regards,
    Jigar

    Hi Jeffery,
    Thanks for your reply, it did solve my query @ point 3 as well as point 2 where the objects in arraycollection were not geting converted and boolean properties did not appear when list of an objects were received. And hey, i did have public functions for properties defined java class, just forgot to mention here in post, sorry for that.
    The solution you gave was right, but than what if i have a VO which has multiple List of objects coming from Java, than i would have to create an instance of each type of object on flex side this is too tedious, is'nt it? Is there any better solution... out there.
    And jeffery do you some tricks up your sleeve for this Boolean issues to that i am facing in point 1... Still struggling with this one...
    Anyone out there would be more than welcome to point my mistake, if any and provide tips/tricks or solutions...
    Thanks again to Jeffery...
    Waiting for more solutions sooner...
    thanks and Regards,
    Jigar

  • How can i store latitude and longitude (of registered user locations) in sql server and how can i query it for finding locations inside X radius from point y (or any user)?

    Hello
    In my app (WP 8.1) i have to store user location (lat,lon) in sql db so how can i store that location detail? And i also have to find all the location which are inside certain radius X from another user location, How can i do this?
    Any Sample project or code or any blog post?
    P.S. I use sql server 2012.

    If you need to do spatial queries like the one you mentioned you'd need to store it as a spatial geography type. For points, a simple SQL INSERT statement using the Point() method would do it. Example here:
    http://msdn.microsoft.com/en-us/library/bb933811.aspx For locations inside a radius, you'd use STDistance() method. All of the methods for the geography data type are documented here:
    http://msdn.microsoft.com/en-us/library/bb933802.aspx and can be used in ordinary T-SQL statements.
    If you need to use the SQL Server spatial library in your .NET application direct, Alastair has some nice blog posts, like this one:
    https://alastaira.wordpress.com/2011/08/19/spatial-applications-in-windows-azure-redux-including-denali/ , he even wrote a book. Or search the answers in this forum.
    Hope this helps, Bob

Maybe you are looking for