473,385 Members | 1,311 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,385 software developers and data experts.

Publishing web service

cj
I'm finally back to trying to write a web service. In VB 2005 I created
a new web site and then ASP.NET Web Service. It opened showing
App_Code/Service.VB with the following code already in it

Imports System.Web
Imports System.Web.Services
Imports System.Web.Services.Protocols

<WebService(Namespace:="http://tempuri.org/")_
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicPr ofile1_1)_
<Global.Microsoft.VisualBasic.CompilerServices.Des ignerGenerated()_
Public Class Service
Inherits System.Web.Services.WebService

<WebMethod()_
Public Function HelloWorld() As String
Return "Hello World"
End Function

End Class

This is a fine starting point. How do I test this? We have a web
server here but I need some steps to compile and put it on the web
server. I've only written windows apps so far. I can write a test
program to use the web service.

Also in my investigation of web services I thought this code was
supposed to be in service.asmx. The only thing in service.asmx is

<%@ WebService Language="vb" CodeBehind="~/App_Code/Service.vb"
Class="Service" %>

What's up with that?
Oct 16 '07 #1
4 3477
cj,

A webservice is in fact a website, you have to set the IIS for that. Have a
look as it is now on your testing computer and use it on the production
server.

Cor

Oct 16 '07 #2
cj
Our production server is currently running and hosting other pages.
What I need to know is what and how do I move a project from the Visual
Studio IDE to the web server.

Cor Ligthert[MVP] wrote:
cj,

A webservice is in fact a website, you have to set the IIS for that.
Have a look as it is now on your testing computer and use it on the
production server.

Cor
Oct 16 '07 #3
Hi Cj,

For ASP.NET/VS 2005 webservice, if you just want to test or debug it, you
can just run it in VS 2005(through the test webserver) and use other client
project to call it. To call webservice, you should generated the webservice
client proxy first. The "Add WebReference" function in VS 2005 can help you
do it:

#How to: Add and Remove Web References
http://msdn2.microsoft.com/en-us/lib...sx(VS.80).aspx

for deploying webservice project to IIS, it is the same as deploying an
ASP.NET web application. You can use the VS 2005 built-in features such as
"Publish Web Site" or "Copy Web Site". You can find "Copy Web Site" menu in
the "WebSite" menu and find "Publish WEb Site" in the "Build" menu(in case
you're currently in a web project). Here are some MSDN reference mentioend
the web application deployment:

#Web Site Deployment in Visual Web Developer
http://msdn2.microsoft.com/en-us/lib...ae(VS.80).aspx

#Walkthrough: Creating an XML Web Service Using Visual Basic or Visual C#
http://msdn2.microsoft.com/en-us/lib...7x(VS.80).aspx

Or you can also do all the stuffs yourself.

** create the virutal directory(mark it as application and set it to the
proper ASP.NET version)

** copy all the webservice project content into it

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


--------------------
>Date: Tue, 16 Oct 2007 13:19:46 -0400
From: cj <cj@nospam.nospam>
User-Agent: Thunderbird 2.0.0.6 (Windows/20070728)
MIME-Version: 1.0
Subject: Re: Publishing web service

Our production server is currently running and hosting other pages.
What I need to know is what and how do I move a project from the Visual
Studio IDE to the web server.

Cor Ligthert[MVP] wrote:
>cj,

A webservice is in fact a website, you have to set the IIS for that.
Have a look as it is now on your testing computer and use it on the
production server.

Cor
Oct 17 '07 #4
cj
Thanks

Steven Cheng[MSFT] wrote:
Hi Cj,

For ASP.NET/VS 2005 webservice, if you just want to test or debug it, you
can just run it in VS 2005(through the test webserver) and use other client
project to call it. To call webservice, you should generated the webservice
client proxy first. The "Add WebReference" function in VS 2005 can help you
do it:

#How to: Add and Remove Web References
http://msdn2.microsoft.com/en-us/lib...sx(VS.80).aspx

for deploying webservice project to IIS, it is the same as deploying an
ASP.NET web application. You can use the VS 2005 built-in features such as
"Publish Web Site" or "Copy Web Site". You can find "Copy Web Site" menu in
the "WebSite" menu and find "Publish WEb Site" in the "Build" menu(in case
you're currently in a web project). Here are some MSDN reference mentioend
the web application deployment:

#Web Site Deployment in Visual Web Developer
http://msdn2.microsoft.com/en-us/lib...ae(VS.80).aspx

#Walkthrough: Creating an XML Web Service Using Visual Basic or Visual C#
http://msdn2.microsoft.com/en-us/lib...7x(VS.80).aspx

Or you can also do all the stuffs yourself.

** create the virutal directory(mark it as application and set it to the
proper ASP.NET version)

** copy all the webservice project content into it

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


--------------------
>Date: Tue, 16 Oct 2007 13:19:46 -0400
From: cj <cj@nospam.nospam>
User-Agent: Thunderbird 2.0.0.6 (Windows/20070728)
MIME-Version: 1.0
Subject: Re: Publishing web service

Our production server is currently running and hosting other pages.
What I need to know is what and how do I move a project from the Visual
Studio IDE to the web server.

Cor Ligthert[MVP] wrote:
>>cj,

A webservice is in fact a website, you have to set the IIS for that.
Have a look as it is now on your testing computer and use it on the
production server.

Cor
Oct 22 '07 #5

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

Similar topics

0
by: marc.derider | last post by:
I was making a change to a Web service. It was something extremely trivial, such as adding a single parameter to extend the functionality exposed through that method. It got me to thinking...
2
by: postings | last post by:
Hi I work for a small company that publishes a number of paper based newsletters for companies. It also supplies these newsletters as PDF's and sends weekly updates (e-bulletins as we call...
3
by: EqDev | last post by:
Hello I have set up a new windows server 2003 standard edition for training (on new software we have developed) and am having problems publishing webs to it from VS 2005. I have a C# Web...
9
by: Coward 9 | last post by:
HI, I created the simplest "ASP .NET Web Service" by using VS 2005 and Visual C#( File | New | Web Site). However, when I tried to access the service from IE 7.0 ...
11
by: cj | last post by:
Perhaps someone knows how to do this. When I open a new ASP.NET web service application in VS 2008, it opens with a simple Hello World web service already written. I want to see this work. ...
0
by: Jeova Almeida | last post by:
Hello, I created a simple web service for testing purpose in Visual Studio 2005: <%@ WebService Language="C#" CodeBehind="~/App_Code/Service.cs" Class="WSTest" %> using System;
2
by: Niclas | last post by:
Hi, I have developed a WCF service that I am planning to host with a service provider. After spending some time uploading the service and fiddling around with the .svc file and Web.config, I...
3
by: K Viltersten | last post by:
I published the software i've designed but it seems that since it's designed as a service, i'm not able to use the usual publishing tools in VS05. When i try to install the software, it says i...
1
by: pankajit09 | last post by:
Can you tell me whether license is required for publishing C#.Net Web Service ?
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...
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...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

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.