cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
gridman
Level 8

Web Application and Web Service install question

I create an ASP.NET web application and web service and tested it on the local machine. It tests with no errors.

I then published the whole thing to a deployment folder on my hard drive.

I then created an IS 2010 installation, added all the deployed files and folders into the project in the Files and Folders view. IS created four components to handle the files.

I then went to the IIS view, created a website, then created a web application, then referenced the component that contained the Default.aspx page.

It works fine on the development machine, but when I install it on a virtual machine to test, it does not recognize the web service. What I mean is that the web page displays, but it does not access the web service to display the required information.

Is there a white paper on how to a install web application and an associated service?
Labels (1)
0 Kudos

(5) Replies
gridman
Level 8

Perhaps I should ask what is the proper method to install a web service in InstallShield? Because that's my problem.
0 Kudos
Cary_R
Level 11

Hi There,

IIS should recognize the application as long as the folder you installed it to is defined as an application in IIS. It'll see web.config, handle the rest, just like if you create a virtual directory using the IIS VDir wizard. Such is the theory, at least.

Now, maybe the problem you're seeing is something more subtle, since you're talking about a web page dynamically populating itself with information from a web service call:

"What I mean is that the web page displays, but it does not access the web service to display the required information."

So the web application piece might feasibly be working, and the web service is choking. Or perhaps even the service is working, but perhaps not returning the data you expect for some reason. Since it's ASP .Net my first thought is to check the Application Event viewer for exceptions that correspond to when you're hitting the site.

As well, can you perhaps post a screenshot of what you're supposed to see, what you're actually seeing, and as well the path to the web service you're trying to call?

Another question, is the web service you're calling an *.ascx file or an *.asmx file? Also, how is your application trying to access the service? Via GET, POST, or SOAP...?
0 Kudos
gridman
Level 8

Thanks for the reply.

This is a test project so I can learn how to install a web service along with a web application.

The web service is an .asmx file. But perhaps I'm not doing it right.

On my development machine, I created the web service and the web application, and put both projects in the same solution.

In the web application, I added a reference to the web service. So, when I test it on the dev. machine, it works from Visual Studio.

Next, I publish the solution (web app and web service in same solution) to a folder on the hard drive. Then my basic msi project gets the files from that folder.

The installation installs with no errors on a test machine, the web app displays the web page, but the information from the web service is missing. It's not showing up on the web page. The web service doesn't access a database or anything. I just call the web service, and it returns some dummy strings. Just something to test if I have the framework working.

When I built the web service, it created a DLL. To answer your question, it's an .asmx file, but I don't deploy that. Instead I deploy the DLL, correct?
0 Kudos
Cary_R
Level 11

Ah, I see. You actually do need to deploy the *.asmx file, since this is the URL you'll be hitting to pull information from. You should be able to browse to something like:

http://somehost/folder/webservice.asmx

And you'll see a Visual Studio-generated UI that gives you examples of how to call the web service via various methods. The *.dll provides the code that runs behind the scenes when the *.asmx file (or *.aspx, *ascx, etc.) file gets invoked via IIS. So, if you're not deploying the *.asmx file, there's no URL to hit to pull data from the web service from.

This sounds like it might be the issue you're seeing if the main *.aspx file works OK.
0 Kudos
gridman
Level 8

Great. Thanks for the help and the link.:)
0 Kudos