Possible problem calling java from Windows DLL

I'm am developing on Windows NT 4.0 using JDK 1.3.1.
What I want to do is to create a DLL that calls into java using the Invocation APIs.
I am able to successfully create a JVM inside my DLL and find the java classes that i need. The problem is if one of those java classes happens to perform a JNDI function (e.g. InitialDirContext), my DLL doesn't ever return from a call to that class's method.
Does anyone have any suggestions?

Thanks for your reply.
All my JNI functions return ok with out error/exception. The problem is, the one function never returns so that I can check for errors/exceptions.
I found a work around for the problem. For some reason if I wrap the JNI code in a C++ class, the call hangs. But if I pull that code outside a C++ class, it works like it is supposed to. Not sure why this would be the problem.
Thanks again for your reply

Similar Messages

  • Problem calling java from vb via activex bridge

    I am trying to call java from vb via ActiveX Bridge and I am running into problems. I would appreciate any help.
    I am using Visual Basic 2010 express, and Java JDK 1.6.0_16. I have used the http://download.oracle.com/javase/1.4.2/docs/guide/beans/axbridge/developerguide/index.html page as a guideline. To try to make it work I took the following steps:
    1. Wrote a very simple java class (below):
    package xxx;
    import java.io.Serializable;
    public class axb implements Serializable {
    public int get_axb_Handle() {
    int Address = 12345678;
    return Address;
    2. After I compiled, and created the jar file. I built the dll using the following command:
    "C:\Program Files\Java\jdk1.6.0_16\bin\packager" -out "C:\Program Files\Java\jdk1.6.0_16\jre\axbridge\bin" E:\axb\dist\axb.jar xxx.axb
    3. I then registered using: regsvr32 axb.dll
    4. In Visual Basic Express IDE I use Project -> Add Reference to add Iterop.axb (dump below), and axb namespace
    5. In my basic code I use the following lines
    Dim axb1 As axb.axb
    axb1 = New axb.axb <== Crash here with AccessViolationException ( full exception below)
    What am I missing? Any help would be greatly appreciated
    Thanks
    Iterop.axb partial dump
    ___[MOD] C:\Documents and Settings\Elie A. Cohen.USINC022\My Documents\Visual Studio 2010\Projects\Repo API Example\Repo API Example\obj\x86\Release\Interop.axb.dll
    | M A N I F E S T
    |___[NSP] axb
    | |___[INT] axb.axb
    | | | .class interface public abstract auto ansi import /*02000006*/
    | | | implements axb.axbDispatch/*02000003*/
    | | | implements axb.axbSource_Event/*02000005*/
    | | | .custom /*0C000018:0A000001*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.GuidAttribute/*01000002*/::.ctor(string) /* 0A000001 */ = ( 01 00 24 34 45 36 44 30 44 41 38 2D 36 41 45 44 // ..$4E6D0DA8-6AED ...
    | | | .custom /*0C000019:0A000007*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.CoClassAttribute/*01000009*/::.ctor(class [mscorlib/*23000001*/]System.Type/*01000007*/) /* 0A000007 */ = ( 01 00 0C 61 78 62 2E 61 78 62 43 6C 61 73 73 00 // ...axb.axbClass. ...
    | |
    | |___[CLS] axb.axbClass
    | | | .class public auto ansi import /*02000004*/
    | | | implements axb.axbDispatch/*02000003*/
    | | | implements axb.axb/*02000006*/
    | | | implements axb.axbSource_Event/*02000005*/
    | | | .custom /*0C00000F:0A000008*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.ClassInterfaceAttribute/*0100000A*/::.ctor(int16) /* 0A000008 */ = ( 01 00 00 00 00 00 ) ...
    | | | .custom /*0C000010:0A000009*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.ComSourceInterfacesAttribute/*0100000B*/::.ctor(string) /* 0A000009 */ = ( 01 00 0F 61 78 62 2E 61 78 62 53 6F 75 72 63 65 // ...axb.axbSource ...
    | | | .custom /*0C000011:0A000001*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.GuidAttribute/*01000002*/::.ctor(string) /* 0A000001 */ = ( 01 00 24 43 44 42 46 36 42 33 33 2D 45 32 33 46 // ..$CDBF6B33-E23F ...
    | | | .custom /*0C000012:0A000002*/ instance void [mscorlib/*23000001*/]System.Runtime.InteropServices.TypeLibTypeAttribute/*01000003*/::.ctor(int16) /* 0A000002 */ = ( 01 00 02 00 00 00 ) ...
    | | |___[MET] method .ctor : void()
    | | |___[MET] method equals : bool(object)
    | | |___[MET] method getClass : object()
    | | |___[MET] method get_axb_Handle : int32()
    | | |___[MET] method hashCode : int32()
    | | |___[MET] method notify : void()
    | | |___[MET] method notifyAll : void()
    | | |___[MET] method toString : string()
    | | |___[MET] method wait : object(object,object)
    AccessViolationException exception
    System.AccessViolationException was unhandled
    Message=Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
    Source=mscorlib
    StackTrace:
    at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck)
    at System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache)
    at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean fillCache)
    at System.Activator.CreateInstance(Type type, Boolean nonPublic)
    at System.Activator.CreateInstance(Type type)
    at WindowsApplication1.Form1.getPatientHandle_Click(Object sender, EventArgs e) in C:\Documents and Settings\Elie A. Cohen.USINC022\my documents\visual studio 2010\Projects\Repo API Example\Repo API Example\Repo API Example.vb:line 13
    at System.Windows.Forms.Control.OnClick(EventArgs e)
    at System.Windows.Forms.Button.OnClick(EventArgs e)
    at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
    at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
    at System.Windows.Forms.Control.WndProc(Message& m)
    at System.Windows.Forms.ButtonBase.WndProc(Message& m)
    at System.Windows.Forms.Button.WndProc(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
    at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
    at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
    at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
    at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
    at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
    at System.Windows.Forms.Application.Run(ApplicationContext context)
    at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun()
    at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel()
    at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String[] commandLine)
    at WindowsApplication1.My.MyApplication.Main(String[] Args) in 17d14f5c-a337-4978-8281-53493378c1071.vb:line 81
    at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
    at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
    at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
    at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()
    InnerException:

    In case you haven't figured it out already... Or if anyone else is curious... Or for myself when I get old and forgetful...
    h2. Object Creation
    For starters, when you create an ActiveX object from within VB, use:
    Set myObject = CreateObject("JavaObject.Bean")When I refer to JavaObject.Bean, I'm meaning the full object name + ".Bean". So, in your case, you should use:
    Set myObject = CreateObject("xxx.axb.Bean")h2. Location
    The .dll file must be located in the JRE that is used at the time of calling. Meaning, the .dll file must be placed under <jre_home>\axbridge\bin and registered there.
    In your case:
    DLL:
    C:\Program Files\Java\jre6\axbridge\bin
    Jar:
    C:\Program Files\Java\jre6\axbridge\libh4. A Note:
    The only supported JRE is a 32bit version as far as I know with regards to the ActiveX bridge. Just like the packager.exe can only be found in the 32bit JDK.
    h2. Methods
    h3. Object Types
    ActiveX Bridge does not support passing literals or arrays. However, it does support passing java's primitive data types as Objects.
    Simply meaning:
    h4. Invalid:
    public int get_axb_Handle() {
         int Address = 12345678;
         return Address;
    }h4. Valid:
    public Integer get_axb_Handle() {
         int Address = 12345678;
         return Address;
    }On a normal circumstance, there's little difference between the two methods. However, in the second example, the JVM does a typecast from a literal data type to a object data type, resulting in a valid object to pass through to Visual Basic. Now, obviously there are multiple ways to do a proper change, new Integer(int) for example. It doesn't matter to me. At the end of the day, you have to pass an object.
    As a side note, the same idea applies when receiving data from Visual Basic.
    h4. Invalid:
    public void set_axb_Handle(int newHandle) {
         int Address = newHandle;
    }h4. Valid:
    public void set_axb_Handle(Integer newHandle) {
         int Address =newHandle;

  • Call java from sybase trigger

    Is it possible to call java from Sybase trigger ? If so can you please supply example or URL to one ? Alternative solution is to call shell script from sybase trigger (as app is based on Solaris).
    Regards
    Michal

    Thank for your opinion, but what idea is better ?Doing things in the middle tier, where Java lives.
    Ever heard of event-based trading systems?
    pooling a table every 30 sec. ?. I need to implment
    real-time system which process each trade from table
    once it appears there.Sounds like you have it backwards - you're trying to drive Java from the database.
    I think it'd be better to write that event-based system in Java and leave the database just for persistence.
    GigaSpaces and their ilk are being used this way for highly transactional trading systems. Maybe you could see how they're doing it.
    %

  • Is it possible to call Java routines from FMS?

    Say I have a game package, most of which
    are written in Java. I am thinking
    to leave the core logics in Java, but
    change the user interface into Flash,
    and serve it over FMS. Now is it
    possible to call Java routines from
    FMS?
    I'd appreciate any suggestions.

    Yes! You can use SOAP(or XML-RPC) to call Java routines.
    Relevant link:
    http://www.adobe.com/devnet/flashmediaserver/articles/fms_web_services_05.html
    Btw, does anyone know if there is XML-RPC package for
    FMS?

  • Calling Java from Delphi

    Can ActiveX bridge used for calling Java from Delphi?

    Also trying to solve this problem, after creating the bean i packaged/registered it successfully, (tested the bean using beanbox, works perfectly) then tried calling it via createoleobject in delphi 7
    (*Code Snip *)
    Var
    v : variant;
    begin
    try
    v := createoleobject(Edit1.text); // my class name ie WorldPort.Bean (also tried WorldPort.Bean.1
    except on e:exception do
    showmessage(e.Message)
    end;
    end;
    (*Code Snip*)
    After this simple code failed i started backtracking , eventually after getting "Access Violation...etc in axbridge.dll" all the time. tried delphi "import activex control" got the same access violation.
    Decided to test the example from http://java.sun.com/j2se/1.4.2/docs/guide/beans/axbridge/developerguide/examples.html........ they both crashed on execution (calc.exe and boundprop.exe).
    After this failed I tested these example classes on another machine, both crashed again.....
    Also tried this experiment in VC++ , after adding the class to the Toolbox , i try to drop it onto a form, once again access violation.**PS**
    ('You will need VC++ and the Microsoft SDK to build the dll, download c++beta for free from microsoft site it you need it')** and a simple cmd file todo the job would look something like this:
    echo - ** Build Java ActiveX Bridge **
    echo Make sure these folders exist in jre--> axbridge\lib and axbridge\bin
    cd\SDK\jre\axbridge\bin
    set path=%path%;C:\MSDN\Bin;C:\VisualC++\lib
    echo path
    javac WorldPort.java
    jar cmf Manifest.txt WorldPort.jar WorldPort.class
    "C:\SDK\bin\packager.exe" -clsid {162193C4-AD5C-4A06-9F88-A737AE9B43AD} -out "C:\SDK\jre\axbridge\bin" WorldPort.jar WorldPort-reg
    *** After running this cmd you will find the dll in bin folder and the jar in lib folder..***
    Must Read:http://java.sun.com/j2se/1.4.2/docs/guide/beans/axbridge/developerguide/index.html
    Hope some of this helps , if you have successfully created / installed/ used a "JavaActiveX" in Delphi , i would really like to try replicate it on my machine..

  • Problem calling java remotely

    Hi,
    I have developed an applet that allows online compiling of java codes. I also intend to make this applet capable of running the .class files online. I connected this applet to a servlet and the servlet calls javac using Runtime.exec() to compile the source code that the user entered through the applet. This works fine with javac. But when I tried to do the same for java to run the program that the user has compiled, I got the error stream that kept saying "Exception in thread "main" : java.lang.ClassNotDefined" .
    The line that I called java goes like this :
    Runtime.exec("java" + filenameWithoutExtension);
    Could it be that java could not find the .class file generated? But I tried putting the .class files at several places, but the same error still occur. Is it possible to call java like that ? Please help. Thanks a lot !
    skitties

    Thanks for your suggestion. Sorry that my earlier post had some mistakes. The error that I got was:
    java.lang.NoClassDefFound
    Exception in thread "main"
    error and not as mentioned earlier.
    I want to clarify some points. I use Tomcat 3.2 to host the servlet. First, the user enters the code through the applet. The applet calls the servlet and the servlet will invoke javac using Runtime.exec("javac sourcefile.java") on the server. It can compile and the .class file appears in the folder c:\jakarta\tomcat. I guess it appeared here coz i used c:\jakarta\tomcat\bin/startup to start tomcat in cmd.
    Now that I want to run the .class file using the same method as how I compiled, I couldn't. I keep getting the NoClassDefFound error. No matter where I put the .class file, I still could not get it to work. When I print the Classpath during runtime, this variable points to all the Tomcat 3.2 related values. And I have my PATH variable set to c:\jdk1.3\bin.
    I get this error when I invoke "java" using the servlet with tomcat on. But when I use Runtime.exec("java filename ") as an application it ran fine and the output is produced.
    These are the things that I have tried:
    1) put .class file into c:\jdk1.3\bin (same error appear)
    2) invoke java using Runtime.exec("cmd /c start jdk1.3/bin/java fileToBeRun") (no error appear but no output from running of .class file appear either)
    3) Change classpath using System.setProperty() to point to the directory where the .class file reside (same error appear)
    The server is using jdk1.3 on windows 2000 professional. Can someone tell me which java.exe is it calling when i call Runtime.exec("java filename") ? Issit the one in jdk1.3\bin or the one in winnt\system32 or elsewhere ?
    Please someone help me if they know the solution the the error i get to spare me from more sleepless nights.
    Thanks!

  • ResourceBundle throws MissingResourceException when calling Java from C

    All,
    Our code calls Java from C application.
    The C code create JVM using JNI_CreateJavaVM. Due to internal design issues we don't
    create the JVM with a "-classpath" option.
    After creating the JVM, we create a ClassLoader (URLClassLoader), with a URL list as it's classpath.
    The last step in the C code is to load a Java class using the C reference to URLClassLoader.loadClass
    (I will refer to this class as classA), and than call one of it's static methods.
    Please notice that classA is not instantiated, we call a static method.
    At this point we are moving to the Java code...
    In the Java static method we call ResourceBundle.getBundle("resources.messages"),
    the result is ResourceBundle throws MissingResourceException.
    - The JAR hosting "resources/messeges.properties" (refer as jarA) is include in the
    ClassLoader URL paths we used for loading the Java class.
    - Using a debugger we can see that ClassLoader.getSystemClassLoader() don't contain
    jarA in it's URL list.
    - Using the debugger we see that classA.class.getClassLoader() does contain
    jarA in it's URL list.
    After some investigation we see that ResourceBundle.getBundle calles to ResourceBundle.getLoader:
    private static ClassLoader getLoader() {
            Class[] stack = getClassContext();
            /* Magic number 2 identifies our caller's caller */
            Class c = stack[2];
            ClassLoader cl = (c == null) ? null : c.getClassLoader();
            if (cl == null) {
                cl = ClassLoader.getSystemClassLoader();
            return cl;
        } getClassContext() - native method, this can explain the why the above work fine for Windows.
    I suspect the problem raised in the above code. Since I couldn't get a debug
    version of rt.jar for Solaris, I need some help.
    Our environment is Solaris 8, Java 1.5.
    Please note that the same code works fine on WindowsXP with the same Java version!
    Thanks,
    Avi

    I was thinking JVM should the classpath when it is invoked. But obviously it is not and we need to assign the classpath ourselves when invoking from native side. Thanks for pointing that out. For other people's benefit the following is the code piece I for initializing JVM.
    char* str1;
              char* str2;
              char* classpath;
              str1 = "-Djava.class.path=";
              str2 = std::getenv("CLASSPATH");
              classpath = (char*)malloc(strlen(str1) + strlen(str2) + 1);
              strcpy(classpath, str1);
              strcat(classpath, str2);
              if (str2 == NULL)     {
                   printf("CLASSPATH environment variable is not defined.");
                   exit(1);
              m_VmArgs.version = JNI_VERSION_1_4;
              m_options[0].optionString= classpath;
              m_VmArgs.options = m_options;
              m_VmArgs.nOptions = 1;
              m_VmArgs.ignoreUnrecognized = JNI_TRUE;
              JNI_GetDefaultJavaVMInitArgs(&m_VmArgs);
              /* Create the Java VM */
              m_Res = JNI_CreateJavaVM(&m_Jvm, (void**)&m_Env, &m_VmArgs);
              if (m_Res < 0) {
                   printf("Can't create JVM\n");
                   exit(1);
    thanks,
    chancellor

  • Calling java from scripting

    Hello,
    I would like to integrate some scripting capability in my web application.
    The main purpose is to cover the following scenario :
    - I develop a web app with JSP technology, packaged in a MyAPP.WAR file containing my application and another file (MyCustomer.RAR?) containing installation specific informations. I want the MyApp.WAR to be the same for all my customers, just having the RAR file specific to each customer (installation).
    - In this ressource file, there could be some scripting functions that will be called from my JSP Pages to change the default presentation with some customer particular informations.
    Those informations would be extracted from my java data model. The purpose is to enable the customer to code some little script, and to avoid coding those in Java.
    The question I have on that are :
    1/ is it possible to call java instances from scripting language (I read on apache that the answer was yes for some of them), but I would like to know if javascript can do that.
    2/ Can I recover the "result" of the script in JSP ?
    An example :
    1/ The class containing a marvellous property
    class MyClass {
    public String myProperty;
    2/ The JSP page :
    <stlLib:callScript(Customer.RAR, "ScriptToCall",anInstance) />
    <stlLib:getResult ???>
    3/ A user script (pseudo-code)
    Customer 1 :
    Function ScriptToCall(object) {
    variable iwanttoshowsquareroot;
    iwanttoshowsquareroot = squareroot(object.myProperty);
    return iwanttoshowsquareroot ;
    Customer 2 :
    Function ScriptToCall(object) {
    variable mychoiceisdifferent;
    mychoiceisdifferent= object.myProperty / 2;
    return mychoiceisdifferent;
    According to what ScriptToCall looks like the result on page would be different
    Thanks in advance for your advises
    Olivier.

    1) The script will be running in the browser, not the server, yes? So in Netscape you can load Java objects via Javascript, but IE doesn't seem to support this. Although in either, you can call methods on an applet in the page. But you can't call a JS function from the Java code in the JSP page, since that is only executed on the server.
    2) Only if the "result" is submitted back to the server.

  • Problem calling simplebutton from library

    Hi guys,
    I'd like to ask for your assistance. I have a problem calling
    SimpleButton from library. I already checked the Linkage:Export for
    actionscript but still an error appear "Call to a possibly
    undefined method OkBtn". I'm just wondering because this method
    works on my MovieClips except for SimpleButtons. Is there another
    way to call SimpleButtons?
    Here's my code calling MovieClip:
    var mc:MovieClip = new ourProduct();
    and same in calling my SimpleButton:
    var myOkBtn:SimpleButton = new OkBtn();
    please help.
    Thank you very much

    Hi again,
    Since I could not call my SimpleButton inside the library, I
    was thinking of putting my button inside the movieclip and call
    that clip inside my library.
    On my stage, I called
    underConstructionPane() movieclip. This
    underConstructionPane contains
    myOkBtn which previously I wanted to call but as a work
    around, I just put it inside
    underConstructionPane movieclip with instance name of
    okBtn. I added eventHandler on
    okBtn which supposed to call
    showHome() function outside
    underConstructionPane.
    showHome() was declared on the stage or root (I don't know
    the correct term. hehehe
    sorry.) but I don't know how to call that function.
    I tried this:
    var home = new showHome();
    but it won't work.
    Please help me
    Thank you.

  • Windows 8.1 Problem with games from windows store.

    I've got a problem with games from windows store. The installation is going well without any problems, however when I try to open it it's loading and then it turns off. The same problem happens when I try to use Games for Windows. I've use a sfc scan and
    it shows some errors but unfortunately it cannot fix them. Should I share the CBS log or find the solution somewhere else? I hope you help, best regards.

    Hi,
    According to my experience, the problem like store game app open failed probably caused by hardware driver. such as Audio and Graphic driver. So, first of all, please try to reinstall these two driver to fix this problem for test.
    In addition, for SFC scan failed problem, it can be caused by many reasons, I would suggest you use another command to fix your system for test.
    Dism /Online /Cleanup-Image /ScanHealth
    Also you can test SFC command in Windows 8.1 safe mode.
    Thirdly, if problem persists, please check Event Viewer, generally speaking, it would record the app open failed events.
    Roger Lu
    TechNet Community Support

  • Is it possible to call website from ABAP Program?

    Hi Experts,
           Is it possible to call website from ABAP Program?
    It is very Urgent Help me.
    Regards,
    Ashok.

    Hi,
    Check the following program:
    REPORT ZURL NO STANDARD PAGE HEADING.
    DATA: BEGIN OF URL_TABLE OCCURS 10,
    L(25),
    END OF URL_TABLE.
    URL_TABLE-L = 'http://www.lycos.com'.APPEND URL_TABLE.
    URL_TABLE-L = 'http://www.hotbot.com'.APPEND URL_TABLE.
    URL_TABLE-L = 'http://www.sap.com'.APPEND URL_TABLE.
    LOOP AT URL_TABLE.
      SKIP. FORMAT INTENSIFIED OFF.
      WRITE: / 'Single click on '.
      FORMAT HOTSPOT ON.FORMAT INTENSIFIED ON.
      WRITE: URL_TABLE. HIDE URL_TABLE.
      FORMAT HOTSPOT OFF.FORMAT INTENSIFIED OFF.
      WRITE: 'to go to', URL_TABLE.
    ENDLOOP.
    CLEAR URL_TABLE.
    AT LINE-SELECTION.
    IF NOT URL_TABLE IS INITIAL.
      CALL FUNCTION 'WS_EXECUTE'
           EXPORTING
                program = 'C:\Program Files\Internet Explorer\IEXPLORE.EXE'
                commandline     = URL_TABLE
                INFORM         = ''
              EXCEPTIONS
                PROG_NOT_FOUND = 1.
      IF SY-SUBRC <> 0.
         WRITE:/ 'Cannot find program to open Internet'.
      ENDIF.
    ENDIF.
    Regards,
    Bhaskar

  • Call java from ABAP

    JCo connectivity is used to call RFCs from Java. can i call Java from abap?
    thanks in advance.....
    regards,
    Sundararamaprasad

    Hi Sundar ,
             This link will surely give u an idea about calling java fro ABAP using Jco.
    http://www.thespot4sap.com/Articles/SAP_Netweaver_Java_Connector.asp
    regards,
    aravindh.

  • Is it possible to call Webservice from VB 6.0?

    Is it possible to call Webservice from VB 6.0?
    Regards,
    Krishanu ray

    Hi
    Please check following links.
    Calling Web Services from Visual Basic 6, the Easy Way
    SAP PI integration with VB 6.0
    Thanks,
    Dipak Patil

  • Is it possible to call methods from another class from within an abstract c

    Is it possible to call methods from another class from within an abstract class ?

    I found an example in teh JDK 131 JFC that may help you. I t is using swing interface and JTable
    If you can not use Swing, then you may want to do digging or try out with the idea presented here in example 3
    Notice that one should refine the abstract table model and you may want to create a method for something like
    public Object getValuesAtRow(int row) { return data[row;}
    to give the desired row and leave the method for
    getValuesAt alone for getting valued of particaular row and column.
    So Once you got the seelcted row index, idxSelctd, from your table
    you can get the row or set the row in your table model
    public TableExample3() {
    JFrame frame = new JFrame("Table");
    frame.addWindowListener(new WindowAdapter() {
    public void windowClosing(WindowEvent e) {System.exit(0);}});
    // Take the dummy data from SwingSet.
    final String[] names = {"First Name", "Last Name", "Favorite Color",
    "Favorite Number", "Vegetarian"};
    final Object[][] data = {
         {"Mark", "Andrews", "Red", new Integer(2), new Boolean(true)},
         {"Tom", "Ball", "Blue", new Integer(99), new Boolean(false)},
         {"Alan", "Chung", "Green", new Integer(838), new Boolean(false)},
         {"Jeff", "Dinkins", "Turquois", new Integer(8), new Boolean(true)},
         {"Amy", "Fowler", "Yellow", new Integer(3), new Boolean(false)},
         {"Brian", "Gerhold", "Green", new Integer(0), new Boolean(false)},
         {"James", "Gosling", "Pink", new Integer(21), new Boolean(false)},
         {"David", "Karlton", "Red", new Integer(1), new Boolean(false)},
         {"Dave", "Kloba", "Yellow", new Integer(14), new Boolean(false)},
         {"Peter", "Korn", "Purple", new Integer(12), new Boolean(false)},
         {"Phil", "Milne", "Purple", new Integer(3), new Boolean(false)},
         {"Dave", "Moore", "Green", new Integer(88), new Boolean(false)},
         {"Hans", "Muller", "Maroon", new Integer(5), new Boolean(false)},
         {"Rick", "Levenson", "Blue", new Integer(2), new Boolean(false)},
         {"Tim", "Prinzing", "Blue", new Integer(22), new Boolean(false)},
         {"Chester", "Rose", "Black", new Integer(0), new Boolean(false)},
         {"Ray", "Ryan", "Gray", new Integer(77), new Boolean(false)},
         {"Georges", "Saab", "Red", new Integer(4), new Boolean(false)},
         {"Willie", "Walker", "Phthalo Blue", new Integer(4), new Boolean(false)},
         {"Kathy", "Walrath", "Blue", new Integer(8), new Boolean(false)},
         {"Arnaud", "Weber", "Green", new Integer(44), new Boolean(false)}
    // Create a model of the data.
    TableModel dataModel = new AbstractTableModel() {
    // These methods always need to be implemented.
    public int getColumnCount() { return names.length; }
    public int getRowCount() { return data.length;}
    public Object getValueAt(int row, int col) {return data[row][col];}
    // The default implementations of these methods in
    // AbstractTableModel would work, but we can refine them.
    public String getColumnName(int column) {return names[column];}
    public Class getColumnClass(int col) {return getValueAt(0,col).getClass();}
    public boolean isCellEditable(int row, int col) {return (col==4);}
    public void setValueAt(Object aValue, int row, int column) {
    data[row][column] = aValue;
    };

  • Advantages and Disadvantages of calling java from PL/SQL

    Hi,
    I have one doubt. What are all the advantages and disadvantages of the calling java from PL/SQL?
    In actual scenario the java program will be in the Application server side. It will do the operation and it will store the result in Data base. But in this case (calling java from PL/SQL), we are loading the java program in the Data base and it is doing the operations.
    I have seen many posts are coming regarding loading jar files into the database. Actually the jar will deploy in to Application server. Is there any difference instead of keeping in the Application server side?
    Then I have read,
    advantages:
    -> java having lot API's. so PL/SQL can use that API's.
    -> if we can not do anything in PL/SQL. we can do it using this mtd(calling java from PL/SQL).
    My questions:
    -> could you explain what are all the things we can not do but we can do using "calling java from PL/SQL" method?
    -> is there any other advantages?
    Disadvantages:
    -> the performance is very slow in calling java from PL/SQL.
    My questions:
    -> Then why others are loading java files and jar files into database?
    -> is there any other disadvantages?
    Could you explain about this one? It will be more helpful to others also…
    Regards,
    kk

    Hi,
    You can read the free first chapter of my book @ http://www.amazon.com/gp/product/1555583296/ (see details then Excerpt)
    Kuassi http://db360.blogspot.com

Maybe you are looking for

  • SORT NODE Fn. in Mapping

    Hello, I am trying to use this node fn sort in my gui mapping and whenever i use this fn and execute my mapping shows error: RuntimeException in Message-Mapping transformation: Exception:[java.lang.IllegalArgumentException: Unknown comparator type: L

  • How to solve java.io.IOException: Corrupt form data: premature ending

    hei evryone! Does anyone knows how to solve this bug? java.io.IOException: Corrupt form data: premature ending Im using Oreilly's cos.jar MultipartRequest here is my form : <FORM METHOD="POST" NAME="uploadform" action="mbbfile" ENCTYPE="multipart/for

  • Accessing cache server of JRun

    Hi there, I am writing a .NET app that ports data from one database to another. The destination database is used by a JRun v3.01 server application. The cache server of JRun is used to store the next primary key for every table in the database (no au

  • Mavericks slow and erratic

    My Mavericks experience so far: Slower launch and response times (to the point of annoyance) for several applications e.g. Mail, Safari, System Preferences. Erratic dock behavior (freeze) and appearance (random changes between monitors) when using mu

  • Portal on java 2EE 5

    Hello, in which time sap-portal will run on java 2EE 5? Best regards Oliver Prodinger