PC Review


Reply
Thread Tools Rate Thread

C# app call to ASP.NET web page

 
 
guy
Guest
Posts: n/a
 
      22nd Mar 2005
Hi,

I need to make a call from my C# application to an ASP.NET web page and pass
some parameters to it and receive back a return value.

Anybody know what the class/function name is in C# to do this?

I'm looking for something like:
string xxx = "http://www.myweb.com/test.aspx?param1=aaa&param2=bbb";
int result = GetWebResult(xxx);

Thanks


 
Reply With Quote
 
 
 
 
Brendan Grant
Guest
Posts: n/a
 
      22nd Mar 2005
You'd be better off if you put called a web service
instead of a web page.

With a webpage you will have to grab the entire page and
parse it, while with a web service you can return only
those values you want.

>-----Original Message-----
>Hi,
>
>I need to make a call from my C# application to an

ASP.NET web page and pass
>some parameters to it and receive back a return value.
>
>Anybody know what the class/function name is in C# to do

this?
>
>I'm looking for something like:
>string xxx = "http://www.myweb.com/test.aspx?

param1=aaaśm2=bbb";
>int result = GetWebResult(xxx);
>
>Thanks
>
>
>.
>

 
Reply With Quote
 
guy
Guest
Posts: n/a
 
      22nd Mar 2005
Can you give me an example of webservice that I can load to my web that I
can experiment with?

Or perhaps if I'm more specific you can point me in the right direction:
From my app, I'd like to call
www.example.com/auth.aspx?lic=234234&user=134123

and have that aspx page do a DB lookup to verify that the license on the
user's machine is current.

Do you think a web service is better for this?

Thanks.

"Brendan Grant" <(E-Mail Removed)> wrote in message
news:069701c52f00$26add880$(E-Mail Removed)...
You'd be better off if you put called a web service
instead of a web page.

With a webpage you will have to grab the entire page and
parse it, while with a web service you can return only
those values you want.

>-----Original Message-----
>Hi,
>
>I need to make a call from my C# application to an

ASP.NET web page and pass
>some parameters to it and receive back a return value.
>
>Anybody know what the class/function name is in C# to do

this?
>
>I'm looking for something like:
>string xxx = "http://www.myweb.com/test.aspx?

param1=aaaśm2=bbb";
>int result = GetWebResult(xxx);
>
>Thanks
>
>
>.
>



 
Reply With Quote
 
Brendan Grant
Guest
Posts: n/a
 
      22nd Mar 2005
I do not have any webservices that I can give you, but
take a look at:
http://www.codeproject.com/cs/webservices/myservice.asp
for a guide to making your own web service, it's pretty
easy to do.

In short, a webservice as far as your code is concerned
(after you've built the reference with the automatic
tools), is just another class that you would instantiate
and make a call to a member of.

On the server, it is not unlike standard class library,
you have functions with parameters that are called, do
their work and return a value.

>-----Original Message-----
>Can you give me an example of webservice that I can load

to my web that I
>can experiment with?
>
>Or perhaps if I'm more specific you can point me in the

right direction:
>From my app, I'd like to call
>www.example.com/auth.aspx?lic=234234&user=134123
>
>and have that aspx page do a DB lookup to verify that the

license on the
>user's machine is current.
>
>Do you think a web service is better for this?
>
>Thanks.
>
>"Brendan Grant" <(E-Mail Removed)> wrote in message
>news:069701c52f00$26add880$(E-Mail Removed)...
>You'd be better off if you put called a web service
>instead of a web page.
>
>With a webpage you will have to grab the entire page and
>parse it, while with a web service you can return only
>those values you want.
>
>>-----Original Message-----
>>Hi,
>>
>>I need to make a call from my C# application to an

>ASP.NET web page and pass
>>some parameters to it and receive back a return value.
>>
>>Anybody know what the class/function name is in C# to do

>this?
>>
>>I'm looking for something like:
>>string xxx = "http://www.myweb.com/test.aspx?

>param1=aaaśm2=bbb";
>>int result = GetWebResult(xxx);
>>
>>Thanks
>>
>>
>>.
>>

>
>
>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
A page call B page's methods? Elliot Microsoft ASP .NET 3 21st Apr 2009 02:18 AM
Call a javascript when i call an aspx page with a form html not running on server Fabio Mastria Microsoft ASP .NET 4 28th Jan 2008 09:05 AM
How to call an ASP page? MeAgin Microsoft VB .NET 7 14th Feb 2007 07:06 AM
Newbie using too many tools! Need to call page from page Jozef Microsoft ASP .NET 1 26th May 2005 12:33 PM
Call to Response.Redirect puts page in frameset, need page to replace frameset... S. Justin Gengo Microsoft ASP .NET 2 8th Jan 2004 05:55 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:23 AM.