Deploying a VB dll using some web service and accessing it through java

I'm new to Web Services Based Programming. I would like to know whether this is possible and if so has anyone tried it. I want to create a vb dll that contains the remote methods that the client will access from a java program. After going thru a lot of articles, I'm still unsure on how to do this. I found one method was to Create a VB program/dll, deploy it in a web service and create the java program that accesses by another web service.
I'm doing this as part of my lab syllabus. The thing is My lab exercises do not state anything about the technologies that I can use to do this.
This is all that is stated there:-
Creation Of DLL Using VB And Deploy it in Java
I just cant get any ideas other than deploying both the parts as web services. If anyone has Better ideas for this, I would really appreciate it.
I dont know anything about CORBA for languages other than Java and I'm already using the servlets and EJB's in my normal life. I'm also learning the ORB based programming in java. Therefore your help will probably help me learn something new then what I know.

Sorry I wasn't too specific in my last question.
This is my java class calling the native method print
//HeyWorld.java
class HeyWorld {
private native void print();
public static void main(String[] args) {
new HeyWorld().print();
static {
System.loadLibrary("HeyWorld");
In this case, my C method for calling a C++ method: HelloWorld.cpp
#include "jni.h"
#include "stdio.h"
#include "stdafx.h"
#Include "HeyWorld.h" //this is where i get my function prototype
#include "Test.h" //this is the C++ header where the print method and the Test class is
JNIEXPORT void JNICALL
Java_HeyWorld_print(JNIEnv *env, jobject obj)
CTest a; //CTest is the print class I created
a.print();
//This is the header for Test.h
class CTest: public CWinApp
public:
     CTest(); //constructor
     void print(); //our method
//And this is the implementation of the class Test.cpp
void CTest::print()
     printf("Hey World!\n");
     return ;
I could compile the Test.cpp, HeyWorld.cpp successfully. However when I tried to compile HeyWorld.cpp using
cl -I<path of jdk include> -I<path of jdk include win32> -LD HeyWorld.cpp -FeHeyWorld.dll,
the VC++ 6.0 compiler gave me this error:
HeyWorld.obj:error LNK2001: unresolved external symbol "public:_thiscall CTest::CTest(void)"
HeyWorld.obj:error LNK2001: unresolved external symbol "public:_thiscall CTest::print(void)"
Thanks for the help.

Similar Messages

  • Return Data from Oracle using a web service in AXIS - please help

    Hi Forum,
    I am very new to web services and Java tech. and recently I have been assigned to work with technology and I am struggling to learn it and need your help and assistance.
    I am trying to return some data from a an oracle database but I have to do that using a web service and I am using AXIS. For example below is a simple program that returns two columns for the demo EMP table
    import java.sql.*;
    class emp {
    public static void main(String args[])
    throws ClassNotFoundException, SQLException {
    Class.forName("oracle.jdbc.driver.OracleDriver");
    // or you can use:
    // DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:orcl","scott", "tiger");
    Statement stmt = conn.createStatement( );
    ResultSet rset = stmt.executeQuery("select * from emp");
    while(rset.next( )) {
    System.out.println(rset.getString(1));
    System.out.println(rset.getString(2));
    rset.close( );
    stmt.close( );
    conn.close( );
    } but I do not know how to convert this into a web service.
    Please help.
    Thanks in advance.
    Regards,
    Ravi

    The following code returns Document. I will be calling the below function to convert my Resultset to document. In my JWS file i simply call a method with parameters. can a web service method in .jws file return Document type. It shows error will doing so. Please help me.
    public static Document toDocument(ResultSet rs) throws ParserConfigurationException, SQLException
              Document res_doc = null;
              DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
              DocumentBuilder builder = factory.newDocumentBuilder();
              Document doc = builder.newDocument();
              Element results = doc.createElement("Results");
              doc.appendChild(results);
              ResultSetMetaData rsmd = rs.getMetaData();
              int colCount = rsmd.getColumnCount();
              while (rs.next())
              Element row = doc.createElement("Row");
              results.appendChild(row);
              for (int i = 1; i <= colCount; i++)
              String columnName = rsmd.getColumnName(i);
              Object value = rs.getObject(i);
              Element node = doc.createElement(columnName);
              node.appendChild(doc.createTextNode(value.toString()));
              row.appendChild(node);
              return res_doc;
         }

  • Error while deploying a web service whose return type is java.util.Date

    Hi
    I have written a simple web service which takes in a date input (java.util.Date) and returns the same date back to the client.
    public interface Ping extends Remote
    * A simple method that pings the server to test the webservice.
    * It sends a datetime to the server which returns the datetime.
    * @param pingDateRequest A datetime sent to the server
    * @returns The original datetime
    public Date ping(Date pingDateRequest) throws RemoteException;
    The generation of the Web service related files goes smoothly in JDeveloper 10g. The problem arises when I try to deploy this web service on the Oracle 10g (10.0.3) OC4J standalone. it gives me the following error on the OC4J console :
    E:\Oracle\oc4j1003\j2ee\home\application-deployments\Sachin-TradingEngineWS-WS\
    WebServices\com\sachin\tradeengine\ws\Ping_Tie.java:57: ping(java.util.Date) in com.sachin.tradeengine.ws.Ping cannot be applied to (java.util.Calendar) _result  = ((com.sachin.tradeengine.ws.Ping) getTarget()).ping
    (myPing_Type.getDate_1());
    ^
    1 error
    04/03/23 17:17:35 Notification ==&gt; Application Deployer for Sachin-TradingEngineWS-WS FAILED: java.lang.InstantiationException: Error compiling :E:\Oracle\oc4j1003\j2ee\home\applications\Sachin-TradingEngineWS-WS\WebServices: Syntax error in source [ 2004-03-23T17:17:35.937GMT+05:30 ]
    I read somewhere that the conversion between java to xml datatype and vice versa fails for java.util.Date, so it is better to use java.util.Calendar. When I change the code to return a java.util.Calendar then the JDeveloper prompts me the following failure:
    Method Ping: the following parameter types do not have an XML Schema mapping and/or serializer specified : java.util.Calendar.
    This forces me to return a String data.
    I would appreciate if someone can help me out.
    Thanks
    Sachin Mathias
    Datamatics Ltd.

    Hi
    I got the web service working with some work around. But I am not sure it this approach would be right and good.
    I started altogether afresh. I did the following step :
    1. Created an Interface (Ping.java) for use in web Service as follows :
    public interface Ping extends Remote{
    public java.util.Date ping(java.util.Date pingDateRequest)
    throws RemoteException;
    2. Implemented the above interface in PingImpl.java as follows :
    public class PingImpl implements Ping
    public java.util.Date ping(java.util.Date pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    3. Compiled the above 2 java files.
    4. Generated a Stateless Java Web Service with the help of JDeveloper. This time the generation was sucessful.(If I had "java.util.Calendar" in place of "java.util.Date" in the java code of the above mentioned files the web service generation would prompt me for error)
    5. After the generation of Web Service, I made modification to the Ping interface and its implementing class. In both the files I replaced "java.util.Date" with "java.util.Calendar". The modified java will look as follows :
    Ping.Java
    =========
    public interface Ping extends Remote{
    public java.util.Calendar ping(java.util.Calendar pingDateRequest)
    throws RemoteException;
    PingImpl.Java
    ================
    public class PingImpl implements Ping
    public java.util.Calendar ping(java.util.Calendar pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    6. Now I recompile both the java files.
    7. Withour regenerating the Web Service I deploy the Web Service on OC4j 10.0.3 from JDeveloper. This time the deployment was sucessful.(The Deployment fails if I don't follow the step 5.)
    8. Now I generated a Stub from JDeveloper and accessed the stub from a client. It works fine. Here if you see the Stub code it takes java.util.Date as a parameter and returns a java.util.Date. (Mind you I am accepting a java.util.Calendar and returning the same in my Web Service interface. Step 5)
    The confusing thing is the Serialization and Deserialization of Data from Client java data to Soap message and Soap message to Server java data.
    From Client to SOAP :
    java.util.Date to datetime
    From SOAP to Server :
    datetime to java.util.Calendar
    From Server to SOAP :
    java.util.Calendar to datetime
    From SOAP to Client :
    datetime to java.util.Date (I am not able to understand this part of the conversion)
    Any help or inputs would be appreciated.
    Thanks
    Sachin Mathias

  • Does Weblogic 8.1 use Apache web service libraries

    Does Weblogic 8.1 use Apache web service libraries ? I've been pressured to include the apache web service libraries, but have been resistant. I was later told by those wanting me to include the apache libraries that weblogic uses the apache libraries, but I have not found any evidence of it.
    Can some confirm or deny this?
    Thanks,
    Eddie

    Hosting an Apache web service inside WLS is basically deploying the Apache service as a webapp in WLS. And in the webapp's WEB-INF\lib folder you would have the Apache libraries.
    Regards
    Shridhar

  • How to integrate deployed Web Services and Portlets

    Hi All,
    I am able to deploy Web Services and Portlets in the Application Server, which is in the network system.Now, I want to know how to integrate the Web Services and Portlets.I dont have any idea about this and i didn't got any good material..
    Please, provide some useful links or material, if anybody has any idea about this.
    Thanks in advance.
    Praphul

    You can consume a Web service from a JSF page for example using the ADF Web service data control:
    http://www.oracle.com/technology/obe/obe11jdev/bulldog/webservices/ws.html
    http://www.oracle.com/technology/obe/obe11jdev/11/wsdc/wsdc.htm
    You can turn these JSF pages into portlets using WebCenter's JSF to Portlet bridge.
    http://www.oracle.com/technology/products/jdev/11/cuecards111/jps_set_62/ccset62_ALL.html

  • How to create a crystal report using secured web service as a datasource?

    Hi All Expert,
    I having some challenges on how to create a report using secured web service as a datasource in crystal report designer (CR11 R3).
    Secured Web Service including the certificate trusting, token authentication, header and/or body encryption. All web services running on https protocal.
    Could you please suggest me on the solution?
    Thank you and Best Regards,
    Cherr

    Please re-post if this is still an issue or purchase a case and have a dedicated support engineer work with you directly:
    http://store.businessobjects.com/store/bobjamer/DisplayProductByTypePage&parentCategoryID=&categoryID=11522300?resid=-Z5tUwoHAiwAAA8@NLgAAAAS&rests=1254701640551

  • Invoking a web service not created using oracle web service lib

    Hi All,
    I have a need to invoke my web service from oracle sql command. My web service not created using oracle web service library, but it is created using axis c++ libraries. Is it possible to do so,
    Thanks in advance,
    Regards,
    Monica

    In order to call out from the database process, is SQL (or PL/SQL) you need to generate some client code, that understand the details about the specific of the service you want to invoke and can produce the correct SOAP request. Once this proxy is uploaded in the Database, you can use it.
    There is a set of Database Web services samples that should help you get started. You can also take a look at the developer's guide - see Developing a Web Service Client in the Database.
    Hope it answers your question.
    --eric                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Error connecting to Salesforce using a Web Service Adapter

    Hi,
    I'm working on a connection from Data Services 4.2 to Salesforce using a Web Service Adapter.
    I've setup up the adapter (including JVM parameters to use a HTTP proxy), created a Datastore based on the adapter and built a batch job that calls the login operation and initiates a sessions towards Salesforce.
    When I execute the batch job I get an error message that says:
    Error calling function <login>: <Web Services client unable to create a SOAP request to send to server. Error: The current node has been removed using a method other than Iterator#remove()>.
    The trace log for the Web Service Adapter contains the same error message and has some additional info.
    4/16/15 1:17:25 PM Thread[Thread-10,5,main] Handle request starting for operation: login
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Entering addDocumentMessage()...
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Entering addHeadersToEnvelope()...
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Web Services client unable to create a SOAP request to send to server. Error: The current node has been removed using a method other than Iterator#remove()
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Remove message listener for message type [adapter.WSAdapter.__STREAM_FUNCTION.1].
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Stopping web service function call operation
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Receive message: BrokerMessage(
    _e.ErrorsTo=com.acta.adapter..client.dataAndMetadata_8
    _e.Timestamp=Thu Apr 16 13:17:26 2015
    _e.SourceTimeoutLength=90000
    _e.MessageID=16
    _e.Destination=com.acta.adapter.webservice.adapter.WebServiceAdapter.data_2
    _e.MessageType=MSG_ADAPTER_END_OPER
    _e.ReplyTo=com.acta.adapter..client.dataAndMetadata_8
    _e.CorrelationID=15_com.acta.adapter..client.dataAndMetadata_8
    _a.MSGFIELD_ADAPTER_SESSION_ID=2
    _e.Source=com.acta.adapter..client.dataAndMetadata_8
    _a.MSGFIELD_ADAPTER_OPER_ID=1)
    I've searched for any additional tracing/logging on the server but I haven't found anything relevant. Can anyone help me determining what the cause of this error is so I can solve this?
    Thanks,
    - Ian

    Hi,
    I'm working on a connection from Data Services 4.2 to Salesforce using a Web Service Adapter.
    I've setup up the adapter (including JVM parameters to use a HTTP proxy), created a Datastore based on the adapter and built a batch job that calls the login operation and initiates a sessions towards Salesforce.
    When I execute the batch job I get an error message that says:
    Error calling function <login>: <Web Services client unable to create a SOAP request to send to server. Error: The current node has been removed using a method other than Iterator#remove()>.
    The trace log for the Web Service Adapter contains the same error message and has some additional info.
    4/16/15 1:17:25 PM Thread[Thread-10,5,main] Handle request starting for operation: login
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Entering addDocumentMessage()...
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Entering addHeadersToEnvelope()...
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Web Services client unable to create a SOAP request to send to server. Error: The current node has been removed using a method other than Iterator#remove()
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Remove message listener for message type [adapter.WSAdapter.__STREAM_FUNCTION.1].
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Stopping web service function call operation
    4/16/15 1:17:26 PM Thread[Thread-10,5,main] Receive message: BrokerMessage(
    _e.ErrorsTo=com.acta.adapter..client.dataAndMetadata_8
    _e.Timestamp=Thu Apr 16 13:17:26 2015
    _e.SourceTimeoutLength=90000
    _e.MessageID=16
    _e.Destination=com.acta.adapter.webservice.adapter.WebServiceAdapter.data_2
    _e.MessageType=MSG_ADAPTER_END_OPER
    _e.ReplyTo=com.acta.adapter..client.dataAndMetadata_8
    _e.CorrelationID=15_com.acta.adapter..client.dataAndMetadata_8
    _a.MSGFIELD_ADAPTER_SESSION_ID=2
    _e.Source=com.acta.adapter..client.dataAndMetadata_8
    _a.MSGFIELD_ADAPTER_OPER_ID=1)
    I've searched for any additional tracing/logging on the server but I haven't found anything relevant. Can anyone help me determining what the cause of this error is so I can solve this?
    Thanks,
    - Ian

  • Cannot pass data from Web Dynpro to XI using a Web Service

    Hi All,
    We have been facing some issues when we try to pass on a SOAP / XML message via a WSDL from a WebDynpro App to XI - No data is reaching XI interface. The payload data details for the inbound message in XI is empty. When testing the WSDL separately using XML spy the data passes to the XI successfully.
    The problem only occurs when we pass on the data from the WebDynpro component.
    We are also passing additional information _user and _password to ensure authenticated access.
    Steps that we completed so far:
    1. Created a WSDL which we can use to communicate to XI interface.
    2. Imported WSDL using webdynpro Web Service Model import
    functionality.
    3. Bound WSDL with webdynpro components.
    4. Pass on data through WSDL contexts.
    5. Execute WSDL model.
    Any help would be much appreciated.
    Thanks,
    RR

    Hi,
    please check document:
    Almost Everything about Transaction Launcher u2013 Part
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/3059fb20-987f-2e10-ef82-d147b9b5e8b4
    Denis

  • Using Axis web service

    Hi,
    are there anyone who use axis webservice in PI. I'm using .Net web service easily but Axis webservice is problem.When i import. It doesn't show all parameter structure therefore it isn't used in message mapping etc.
    thank.

    Hi!
    Like already mentioned there are some restrictions. Unfortunately the PI 7.1 Online Help does not explcitely tell them as you can see here:
    http://help.sap.com/saphelp_nwpi71/helpdata/en/26/9e97b0f525d743882936c2d6f375c7/content.htm
    But the XI 3.0 documentation contains a hint:
    For technical reasons, proxy generation and the respective editors in the Integration Builder do not support the entire language range of XML schema and WSDL. For an overview of which language elements are supported, see the Excel spreadsheet in the SAP Service Marketplace at service.sap.com/xi ® Media Library ® Documentation: SAP XI 3.0 (SP11) u2013 Supported XML Schema and WSDL (EN).
    Hope this helps.
    Regards,
    Volker

  • Exception when trying to run an Web Application that uses a Web service

    Hello All,
    I get an exception when trying to run an Web Application that uses a Web service. The web application is a WebDynpro Application.(an application similar to the one "Using an Email Web Service in Web Dynpro" in the tutorial section of Web Dynpro but using a different web service)
    The exception is
    <b>Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.InvalidResponseCodeException: Invalid Response Code: (404) Not Found.</b>
    Could anyone give me an idea on what might be the problem ?
    Regards,
    Loveline.

    Hello,
    Like you said it was the problem with url.
    The webservice I used is actually running on the local machine (where the NetWeaver developer studio is installed); so in the url I had specified localhost. But I deployed the application on another server(SAP J2EE Engine). That is why it didn't work. On changing the url as required, the application is working fine.
    Thanks !
    Regards,
    Loveline.

  • I can't use "Import Web Service".

    Hi, I can't use "Import Web Service" in LabVIEW Web UI builder.
    I write IP:8080 and click on Connect.
    And it says "No Web ervices found on the server".
    Please help.

    I think I'm one step from finished application.
    So ... I've tried this building web service from tutorial and when I'm on the step when I have to deploy a Web Service to the Web Server I have a problem.
    I rightclick on My Web Service under "build specifications" and click to deploy and I get this message in attachment.
    My question is how can I start the web server ?
    Thanks in advance and I hope that after solving this I won't bother any of you anymore.
    Attachments:
    problem.JPG ‏99 KB

  • JCAPS UDDI - Problem Using the Web Service Management Application

    Hi everyone, this is my problem:
    1.) I installed the JCAPS UDDI Server in a Solaris. <-- Ok
    2.) In the eManager I installed the Web Services Access Manager. <-- Ok
    3.) I started the UDDI server. <-- Ok
    4.) I check that the process is running (in Solaris). <-- Ok
    5.) I'm trying to load the Web Service Management Application Login Page, but it doesn't show the page so I can't login and in consequence I can't publish, remove, view, and search WSDLs by using the Web Service Management Application.
    I appreciate some help about this.
    Regards

    Yes, I am connecting to the same system where we have data..
    Anirban

  • Using 2 web services data sources in the same report

    I've been trying unsuccesffuly to use 2 web services data sources in a report. The main report accesses the first web service to get job summary information. 3 fields are are passed as parameters to a sub-report and used as parameters for the sub-report selection. Each report works fine independently, but when I link them together the subreport alway fails to retrieve data.

    Please re-post if this is still an issue or purchase a case and have a dedicated support engineer work with you directly:
    http://store.businessobjects.com/store/bobjamer/DisplayProductByTypePage&parentCategoryID=&categoryID=11522300?resid=-Z5tUwoHAiwAAA8@NLgAAAAS&rests=1254701640551

  • Crystal Report using a Web Service as a data source?

    I am trying to figure out how to use a Web Service as a data source in Crystal Reports. When I use the report wizard, I do not see an option to select Web Service as a new connection. We are currently using Crystal Reports 2008 v12.1.0.892. Could it be that my version does not support this? Is there an update that contains this feature? Please help.

    Thanks for your response. Unfortunately I do not see a radio button for Web Services. I've read that it should be there too. Could it be a missing plug-in or patch?
    Here are screen shots of what I see when trying to connect to an XML. Any thoughts?
    [http://s26.photobucket.com/albums/c120/hpolit/?action=view&current=wizard1.jpg]
    [http://s26.photobucket.com/albums/c120/hpolit/?action=view&current=wizard2.jpg]

Maybe you are looking for

  • Text-to-speech no longer working in any PDF apps in Mac 10.8.5.

    Text-to-speech is no longer working in any PDF apps in Mac 10.8.4/5.  Does anyone know the software component that passes highlight text over to the speech synthesiser?   How is this process different in PDF's compared to any other text format? So fa

  • BW Master data delta generic data source for further update in BW

    Hi BWers, I am looking for an option to load delta from Master data to another master data within BW. Export data source option for master data only has full load option but no delta update possible. I tried creating generic data source delta enabled

  • Stop iPhoto starting up!

    This is probably a fairly simple thing to do, but for some reason I can't get my head around it... Is there a way to connect my iPhone to my mac without iPhoto starting up automatically? I do want iTunes to start, as this is set up to sync calendars,

  • Error in SWF_XI_CUSTOMIZING - Configure RFC Destination

    Dear Experts, Basis team is performing PI 7.1(EHP1 - SP04) readiness check. We are not able to activate Configure RFC Destination. Please refer the following attachment. We have checked if WF-BATCH user got locked. It is fine and in unlocked status.

  • Problem facing in ALV to List processing and back to ALV

    HI all, In ALV USER_COMMAND i have inserted statement 'LEAVE TO LIST-PROCESSING'. I want to display records on List processor (Classical report) which are selected from ALV. Due to LEAVE TO LIST-PROCESSING i can see Classical report but from here i a