[DUG] Com problem
David Moorhouse
David.Moorhouse at pegasus.org.nz
Fri Oct 7 10:18:37 NZDT 2016
The _TLB file will contain the stubs so if the client can compile, the problem is unlikely to be on the client side.
Is there more than one copy of the server part of the app ? Have you unregistered and re-registered the server ?
Cheers
D
David Moorhouse (BCom) | Principal Software Engineer - HealthOne
Pegasus Health (Charitable) Ltd
P: 03 353 0871 | W: www.pegasus.org.nz
E: david.moorhouse at pegasus.org.nz
PO Box 741, Christchurch 8140
160 Bealey Ave, Christchurch 8014
-----Original Message-----
From: delphi-bounces at listserver.123.net.nz [mailto:delphi-bounces at listserver.123.net.nz] On Behalf Of Robert Martin
Sent: Friday, 7 October 2016 10:11 a.m.
To: NZ Borland Developers Group - Delphi List
Subject: Re: [DUG] Com problem
Hi David
Thanks for your reply. I'm tied up fighting fires at the moment so will look into this more when I free up a bit. However my Client app shares the _TLB.pas file and so that is identical between the two apps, was there any other file you think I want to re import?
I don't think its the data types, they are just WideString and Integer (BSTR and long in the typelibrary editor), the same as most other methods. I think I will try and add another method that takes no params to rule out that.
Cheers
Rob
On 7/10/2016 9:20 AM, David Moorhouse wrote:
> Hi Rob
>
> It's a while since I've done any COM related stuff (typically SOAP and REST these days) but a couple of things spring to mind:
>
> Have you checked the signatures of the methods to make sure you're only using valid data types - especially when passing/returning strings.
>
> Also IIRC you need to regenerate the tlb and reimport the stubs in the client.
>
> Cheers
>
> David Moorhouse (BCom) | Principal Software Engineer - HealthOne
> Pegasus Health (Charitable) Ltd
> P: 03 353 0871 | W: www.pegasus.org.nz
> E: david.moorhouse at pegasus.org.nz
> PO Box 741, Christchurch 8140
> 160 Bealey Ave, Christchurch 8014
>
>
>
>
> -----Original Message-----
> From: delphi-bounces at listserver.123.net.nz
> [mailto:delphi-bounces at listserver.123.net.nz] On Behalf Of Robert
> Martin
> Sent: Friday, 7 October 2016 8:42 a.m.
> To: NZ Borland Developers Group - Delphi List
> Subject: [DUG] Com problem
>
> Hi All
>
> Recently I went to add a new COM method to our app. I hadn't done this since our previous version of Delphi by the looks of it because the type library menu item was disabled. I discovered I needed to add the .rdil file to the project. Having done that all seemed ok. I added the method in the typeLibrary screen then implemented the code.
>
>
> In my COM consumer app I then try to call the new com method. All the old methods work just fine but the new method just AVs. The com method is not called. It is almost like, even though I have defined the v call it hasn't actually been 'build' into the app. I have checked the The rdil and tlb files and the new method looks the same as the existing methods.
>
> Does anyone have any suggestions of where I should look?
>
>
> Thanks
> Rob
>
>
>
> _______________________________________________
> NZ Borland Developers
_______________________________________________
NZ Borland Developers Group - Delphi mailing list
Post: delphi at listserver.123.net.nz
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to delphi-request at listserver.123.net.nz with Subject: unsubscribe
[http://snow.pegasus.org.nz/wp-content/uploads/2016/10/moving_footer.jpg]
********************************************************************************
This email or attachment(s) may contain confidential or legally privileged
information intended for the sole use of the addressee(s). Any use, redistribution,
disclosure, or reproduction of this message, except as intended, is prohibited.
If you received this email in error, please notify the sender and erase all
copies of the message, including any attachments.
Any views or opinions expressed in this email (unless otherwise stated) may not
represent those of Pegasus Health Ltd.
********************************************************************************
More information about the Delphi
mailing list