Click here to Skip to main content
15,916,463 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
GeneralA very challenging problem Pin
gaurav_verma723-Aug-03 2:37
gaurav_verma723-Aug-03 2:37 
GeneralRe: A very challenging problem Pin
leppie23-Aug-03 8:50
leppie23-Aug-03 8:50 
GeneralRe: A very challenging problem Pin
Tom Archer25-Aug-03 15:05
Tom Archer25-Aug-03 15:05 
GeneralRe: A very challenging problem Pin
leppie26-Aug-03 7:08
leppie26-Aug-03 7:08 
GeneralRe: A very challenging problem Pin
Frank Olorin Rizzi28-Aug-03 18:34
Frank Olorin Rizzi28-Aug-03 18:34 
GeneralRe: A very challenging problem Pin
igor196023-Aug-03 17:00
igor196023-Aug-03 17:00 
GeneralRe: A very challenging problem Pin
Joey Bloggs26-Aug-03 20:32
Joey Bloggs26-Aug-03 20:32 
QuestionAlmost desperate, C# into C++, why not work? Pin
adaoja22-Aug-03 1:50
adaoja22-Aug-03 1:50 
Hello everyone!

I hope that I won´t be kicked out for asking the same question again and again until I get it to work. But here goes:

I´m developing a managed C++-web Service and my problem
occured months ago when I tried to pass binary files as dataset
between the client and the service. I then got the advice to
use DIME and recently downloaded WSE 1.0 SP1.

I read an example in C# and tried to convert the code to
c++. But it don´t get it to work.

C#
DimeAttachment attachment = new DimeAttachment("application/octet-stream",
TypeFormatEnum.MediaType, ms);
HttpSoapContext.ResponseContext.Attachments.Clear();
HttpSoapContext.ResponseContext.Attachments.Add(attachment);

C++ (I´ve tried this, and similar)
DimeAttachment* attachment;
attachment = new DimeAttachment("application/octet-stream", TypeFormatEnum::MediaType, ms);
HttpSoapContext* hsc;
hsc->get_ResponseContext()->get_Attachments()->Clear();
hsc->ResponseContext->Attachments->Add(attachment);

This will compile, but when I run I get the error
"Object not set to an instance.." on the ...->Clear(); row.
If I then try to instance the object;
HttpSoapContext* phsc = new HttpSoapContext();
or
SoapContext* sc = new SoapContext();
i get the error C2512 "no deafult constructor" when I compile.

What can be wrong? Are there som arguments missing;
Intellisense doesn´t detect any. Are there some error in
the config-files?

With the very highest regards


PS*************************************************

Well actually, I also can´t get a C#-version to function.
I downloaded Roman Kiss-example
"Using WSE-DIME for Remoting over Internet"
http://www.codeproject.com/cs/webservices/remotingdime.asp

...allthough I did everything according to the book I kept on getting
the error .FileLoadException "The assembly manifest definition [name]
does not match the assembly reference".

DS**************************************************;);)

Daniel
AnswerRe: Almost desperate, C# into C++, why not work? Pin
Nemanja Trifunovic22-Aug-03 6:05
Nemanja Trifunovic22-Aug-03 6:05 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja22-Aug-03 7:04
adaoja22-Aug-03 7:04 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Nemanja Trifunovic22-Aug-03 7:41
Nemanja Trifunovic22-Aug-03 7:41 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Nemanja Trifunovic22-Aug-03 7:48
Nemanja Trifunovic22-Aug-03 7:48 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja22-Aug-03 11:02
adaoja22-Aug-03 11:02 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Nemanja Trifunovic22-Aug-03 11:47
Nemanja Trifunovic22-Aug-03 11:47 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja25-Aug-03 1:17
adaoja25-Aug-03 1:17 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Anthony_Yio26-Aug-03 1:53
Anthony_Yio26-Aug-03 1:53 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja26-Aug-03 2:30
adaoja26-Aug-03 2:30 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Anthony_Yio26-Aug-03 16:48
Anthony_Yio26-Aug-03 16:48 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja26-Aug-03 22:35
adaoja26-Aug-03 22:35 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Anthony_Yio26-Aug-03 1:14
Anthony_Yio26-Aug-03 1:14 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja26-Aug-03 1:25
adaoja26-Aug-03 1:25 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
Anthony_Yio26-Aug-03 1:31
Anthony_Yio26-Aug-03 1:31 
GeneralRe: Almost desperate, C# into C++, why not work? Pin
adaoja26-Aug-03 1:35
adaoja26-Aug-03 1:35 
AnswerRe: Almost desperate, C# into C++, why not work? Pin
igor196023-Aug-03 17:10
igor196023-Aug-03 17:10 
GeneralIsapi Filters and Extensions is managed C++ Pin
martinbertolino21-Aug-03 16:41
martinbertolino21-Aug-03 16:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.