Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Delphi 4 and CORBA..

Posted on 1999-01-27
5
Medium Priority
?
282 Views
Last Modified: 2010-08-05
We have a CORBA server object written in PERL. The IDL has been generated using IDL2PAS.  That is a whole other story.  I can't even connect to the CORBA server.  I am using the TCorbaConnect object.  I put the hostname and repositoryid and switch connected to TRUE and it says "NO_IMPLEMENT"  What am I missing?  The guys who wrote it conenct to it with no trouble from PERL.  They pass all kinds of other variables such as ORBServices=CosNaming and SVCnameroot=CorbaJava.  What am I doing wrong?  The object exists.  Why can't I connect to it.  I am not trying to do anything else.

I need a full explanation as well as source code.

Thank you..
0
Comment
Question by:lorenkoss
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 13

Accepted Solution

by:
Epsylon earned 400 total points
ID: 1363619
Are the ObjectName and RepositoryID Correct?
Can you connect to the Corba server? Try to ping the ip address.
Run Visibroker's Smart Agent and Smart Finder to look for Corba Objects on the network. If the wanted object is listed, check the NAME and IDL. You should now be able to connect to it.
0
 

Author Comment

by:lorenkoss
ID: 1363620
Epsylon,
Thanks, I didn't know about those apps.. I don't know what smart agent does, but smart finder did find the corba server and listed the objects. I now typed it in the TCorbaConnection object and it now says "BAD_OPERATION" instead of "NO_IMPLEMENT" which is what it was saying yesterday.

What am I doing wrong?
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 1363621
If you are writing a client for a CORBA server that was not written using Delphi, you must write your own descendant of TCorbaStub to provide marshaling support for your client. You must then register this stub class with the global CORBAStubManager. Finally, to instantiate the stub class and get the server interface, you can call the global BindStub procedure to obtain an interface which you then pass to the CORBA stub manager’s CreateStub method.
0
 

Author Comment

by:lorenkoss
ID: 1363622
Thanks, I still am having trouble.  I have 3 files created using the IDL2PAS program by Kevin Smith.  The CORBA objects are TickerServer and Ticker.  IDL2PAS created a ITickerServerStub object, ITickerStub, TTickerServer, and TTicker objects..  I tried TTickerServer.Create, but that requires some variables.  I also read about CreateStub, but am still confused.  For all your help, I'm adding 10 more points (sorry, its all I have)..
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 1363623
You can use Dii. You don't have to use stubs this way.
First the server interface must be registered with an Interface Repository. You have already done this.
In the client app, obtain the server interface and assign it to a TAny vaiable:

var
  IntToCall: TAny;
begin
  IntToCall := CorbaBind('IDL:MyServer/MyServerObject:1.0');
  ...

Then you can call the interface's methods. This example is copied from the Delphi help files:

var

  HR, Emp, Payroll, Salary: TAny;
begin
  HR := CorbaBind('IDL:CompanyInfo/HR:1.0');
  Emp := HR.LookupEmployee(Edit1.Text);
  Payroll := CorbaBind('IDL:CompanyInfo/Payroll:1.0');
  Salary := Payroll.GetEmployeeSalary(Emp);
  Payroll.SetEmployeeSalary(Emp, Salary + (Salary * StrToInt(Edit2.Text) / 100));
end;



0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question