Discussion:
TSOAPAttachment changing content ID (CID)
(too old to reply)
Ronald Stubbe
2008-08-06 12:16:42 UTC
Permalink
It is possible to change the content ID that the TSOAPAttachment generates.

The reason is that the server that the application is talking to rejects the attachtment (wihout given a proper error message).

Tracing back the differences between what my applicaion sends out and what there apps sends, is the Content ID lines

There apps:
<documentFile href='cid:http://082142CB-493B-7DD9-B700-949C0E0D272B'>
Content-ID: <http://082142CB-493B-7DD9-B700-949C0E0D272B>

My apps:
<documentFile href="cid:BF16F1CE-418A-4FD0-8FF8-58218E33615A"/>
Content-ID: <BF16F1CE-418A-4FD0-8FF8-58218E33615A>

The only difference is the "http://" bit which is missing and needs to be added.

Can this be done??

Thanks
Remy Lebeau (TeamB)
2008-08-06 16:35:56 UTC
Permalink
Post by Ronald Stubbe
The only difference is the "http://" bit which is missing and needs to be added.
Why? There is nothing wrong with yours. The contents of a Content-ID are
arbitrary. You can use whatever you want, as long as it is unique within
that document. From a technical standpoint, your data is perfectly accurate
as it already stands. If the server is rejecting your data, then the
server, not your app, is faulty.


Gambit
Ronald Stubbe
2008-08-06 17:45:52 UTC
Permalink
The server is rejecting the attachments, as it is missing the "http://"
part. I don't know which libraries they have used on the server, but
appearently it rejects the attachments where the CID does not start with
http://.

I know that it not not my application, but as I have to interface with
that server, so that is why i try to have this change in the CID.

Ronald
Post by Remy Lebeau (TeamB)
Post by Ronald Stubbe
The only difference is the "http://" bit which is missing and needs to be added.
Why? There is nothing wrong with yours. The contents of a Content-ID are
arbitrary. You can use whatever you want, as long as it is unique within
that document. From a technical standpoint, your data is perfectly accurate
as it already stands. If the server is rejecting your data, then the
server, not your app, is faulty.
Gambit
Remy Lebeau (TeamB)
2008-08-06 21:51:47 UTC
Permalink
Post by Ronald Stubbe
I know that it not not my application, but as I have to interface with
that server, so that is why i try to have this change in the CID.
TSOAPAttachment does not provide access to change the Content-ID, sorry. It
is hard-coded behavior when the attachment is serialized to XML. To do what
you are asking, you will have to stop using TSOAPAttachment and change your
code to use the SOAP protocol manually, or else find a third-party component
that does what you need.


Gambit

Loading...