473,324 Members | 2,370 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

soapmessage c# windows app help


hi all

can someone help me out

i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005

SoapMessage message;

message.GetReturnValue();

but it says Use of unassigned local variable 'message'

is anyone able to help
Nov 22 '07 #1
10 2943
This may help

http://www.codeproject.com/useritems...extraction.asp

Cheers,
Husam Al-A'araj

"plork" wrote:
>
hi all

can someone help me out

i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005

SoapMessage message;

message.GetReturnValue();

but it says Use of unassigned local variable 'message'

is anyone able to help
Nov 22 '07 #2
On Nov 22, 12:41 pm, Husam Al-A''araj
<HusamAlAa...@discussions.microsoft.comwrote:
This may help

http://www.codeproject.com/useritems...extraction.asp

Cheers,
Husam Al-A'araj

"plork" wrote:
hi all
can someone help me out
i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005
SoapMessage message;
message.GetReturnValue();
but it says Use of unassigned local variable 'message'
is anyone able to help- Hide quoted text -

- Show quoted text -

I've tried this example

but i get an error on this line of code

doc.LoadXml(SoapMessage);

System.Web.Services.Protocols.SoapMessage' is a 'type' but is used
like a 'variable'

I don't know how to solve it
Nov 22 '07 #3
plork,

You have to assign a SoapMessage instance to the local variable, like
so:

SoapMessage message = null;

That will fix the compilation error, but you will want to replace null
with the actual message.

If you are going to access a web service, you might want to add a
web-reference, or use WCF in .NET 3.0, or the Web Service Extensions (WSE).
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"plork" <pl******@hotmail.comwrote in message
news:7f**********************************@j20g2000 hsi.googlegroups.com...
>
hi all

can someone help me out

i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005

SoapMessage message;

message.GetReturnValue();

but it says Use of unassigned local variable 'message'

is anyone able to help
Nov 22 '07 #4
On Nov 22, 2:59 pm, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
plork,

You have to assign a SoapMessage instance to the local variable, like
so:

SoapMessage message = null;

That will fix the compilation error, but you will want to replace null
with the actual message.

If you are going to access a web service, you might want to add a
web-reference, or use WCF in .NET 3.0, or the Web Service Extensions (WSE).

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

"plork" <plork...@hotmail.comwrote in message

news:7f**********************************@j20g2000 hsi.googlegroups.com...


hi all
can someone help me out
i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005
SoapMessage message;
message.GetReturnValue();
but it says Use of unassigned local variable 'message'
is anyone able to help- Hide quoted text -

- Show quoted text -
I've addedd a web reference to the web service and i can call it and
get the correct results

But I need to get the raw soap response, this is where i'm having
trouble

Any help much appreciated

Nov 22 '07 #5
On Nov 22, 4:11 pm, plork <plork...@hotmail.comwrote:
On Nov 22, 2:59 pm, "Nicholas Paldino [.NET/C# MVP]"

<m...@spam.guard.caspershouse.comwrote:
plork,
You have to assign a SoapMessage instance to the local variable, like
so:
SoapMessage message = null;
That will fix the compilation error, but you will want to replace null
with the actual message.
If you are going to access a web service, you might want to add a
web-reference, or use WCF in .NET 3.0, or the Web Service Extensions (WSE).
--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com
"plork" <plork...@hotmail.comwrote in message
news:7f**********************************@j20g2000 hsi.googlegroups.com...
hi all
can someone help me out
i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005
SoapMessage message;
message.GetReturnValue();
but it says Use of unassigned local variable 'message'
is anyone able to help- Hide quoted text -
- Show quoted text -

I've addedd a web reference to the web service and i can call it and
get the correct results

But I need to get the raw soap response, this is where i'm having
trouble

Any help much appreciated- Hide quoted text -

- Show quoted text -

I have this

WebService service = new WebService ();
results[] results = null;
results = service.method(paramA, paramB, paramC, paramD);

How to i now get the raw soap?


Nov 22 '07 #6
plork,

If you want to do this, I recommend that you either issue the request
with the HttpWebRequest/HttpWebResponse classes, and handle all the
encoding/decoding of the parameters yourself, or use .NET 3.0 and WCF, which
will give you direct access to the underlying message (in a much easier way
than issuing the request yourself).
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"plork" <pl******@hotmail.comwrote in message
news:c5**********************************@i29g2000 prf.googlegroups.com...
On Nov 22, 4:11 pm, plork <plork...@hotmail.comwrote:
>On Nov 22, 2:59 pm, "Nicholas Paldino [.NET/C# MVP]"

<m...@spam.guard.caspershouse.comwrote:
plork,
You have to assign a SoapMessage instance to the local variable,
like
so:
SoapMessage message = null;
That will fix the compilation error, but you will want to replace
null
with the actual message.
If you are going to access a web service, you might want to add a
web-reference, or use WCF in .NET 3.0, or the Web Service Extensions
(WSE).
--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com
"plork" <plork...@hotmail.comwrote in message
>news:7f**********************************@j20g200 0hsi.googlegroups.com...
hi all
can someone help me out
i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005
SoapMessage message;
message.GetReturnValue();
but it says Use of unassigned local variable 'message'
is anyone able to help- Hide quoted text -
- Show quoted text -

I've addedd a web reference to the web service and i can call it and
get the correct results

But I need to get the raw soap response, this is where i'm having
trouble

Any help much appreciated- Hide quoted text -

- Show quoted text -


I have this

WebService service = new WebService ();
results[] results = null;
results = service.method(paramA, paramB, paramC, paramD);

How to i now get the raw soap?

Nov 22 '07 #7
On Nov 22, 4:23 pm, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
plork,

If you want to do this, I recommend that you either issue the request
with the HttpWebRequest/HttpWebResponse classes, and handle all the
encoding/decoding of the parameters yourself, or use .NET 3.0 and WCF, which
will give you direct access to the underlying message (in a much easier way
than issuing the request yourself).

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

"plork" <plork...@hotmail.comwrote in message

news:c5**********************************@i29g2000 prf.googlegroups.com...
On Nov 22, 4:11 pm, plork <plork...@hotmail.comwrote:
On Nov 22, 2:59 pm, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
plork,
You have to assign a SoapMessage instance to the local variable,
like
so:
SoapMessage message = null;
That will fix the compilation error, but you will want to replace
null
with the actual message.
If you are going to access a web service, you might want to add a
web-reference, or use WCF in .NET 3.0, or the Web Service Extensions
(WSE).
--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com
"plork" <plork...@hotmail.comwrote in message
news:7f**********************************@j20g2000 hsi.googlegroups.com...
hi all
can someone help me out
i'm trying to get the soap message from a web service call in my c#
code. i'm using .net 2 and vs 2005
SoapMessage message;
message.GetReturnValue();
but it says Use of unassigned local variable 'message'
is anyone able to help- Hide quoted text -
- Show quoted text -
I've addedd a web reference to the web service and i can call it and
get the correct results
But I need to get the raw soap response, this is where i'm having
trouble
Any help much appreciated- Hide quoted text -
- Show quoted text -
I have this
WebService service = new WebService ();
results[] results = null;
results = service.method(paramA, paramB, paramC, paramD);
How to i now get the raw soap?- Hide quoted text -

- Show quoted text -
are you able to show me an example of using HttpWebRequest/
HttpWebResponse ?

i'm not allowed to goto .net 3
Nov 22 '07 #8
On Nov 22, 4:47 pm, Marc Gravell <marc.grav...@gmail.comwrote:
http://www.google.com/search?q=%2BHt...est+%2Bexample
orhttp://www.google.com/search?hl=en&q=%2BWebClient+%2Bexample

for instance:http://www.c-sharpcorner.com/UploadF.../debx8sh9.aspx

Marc
i've got that working but all that's doing is reading the wsdl file
it's not retruning the response from the webservice method i'm calling

Nov 22 '07 #10
Ahh... try this then:

http://geekswithblogs.net/marcel/arc...26/109886.aspx

But again, it would be a lot easier with WCF as you can install custom
behaviors at all levels of the stack.

Marc
Nov 22 '07 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Wolfgang Kaml | last post by:
Hello All, I have been working on this for almost a week now and I haven't anything up my sleeves anymore that I could test in addition or change.... Since I am not sure, if this is a Windows...
2
by: Ken Lindner | last post by:
I have a need to become familiar with SQL Server 2000 for work. Needless to say I am new to SQL Server any version, but not IT in general. My employer has provided me with the SQL Server 2000...
1
by: Scott Davies | last post by:
Hi, I'm looking for some help on a small program that I'm trying to develop in VB.NET. I'm having trouble getting the code that I've written to work, can anyone shed some light as to where I'm...
0
by: Scott Davies | last post by:
Hi, I'm looking for some help on a small program that I'm trying to develop in VB.NET. The program I'm trying to develop needs to be able to do the following: - Select remote server -...
0
by: moleee | last post by:
hello How can i find Request Client IP from SoapMessage of SoapExtension ?..
0
by: moleee | last post by:
hello How can i get request client ip from soapmessage in SoapExtension?
21
by: Dan Tallent | last post by:
In my application I have a form (Customer) that I want to be able to open multiple copies at once. Within this form I have other forms that can be opened. Example: ZipCode. When the user enters...
0
AmberJain
by: AmberJain | last post by:
Windows Autorun FAQs: Description NOTE- If you are unfamiliar with the concept of autoruns, then read "Windows Autorun FAQs: Overview". Que-1: How can I safely remove or edit the autorun...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.