|
-
Apr 9th, 2007, 07:51 AM
#1
Thread Starter
Frenzied Member
[2005] Creating a setup for XML Web Service
Hello,
I have to create a setup for web service. Which I don't think will be much of a problem.
However, I have to create a setup that once its installed on the IIS, there is a button that can be pressed that would be on a windows form after the setup has completed. This will inform the user that the setup was completed successfully. Does anyone know of any good method to do this?
I think what I need is some kind of window that will be displayed after the setup is completed. However, how would I test if the setup was completed or not?
Many thanks for any suggestions and examples.
Steve
-
Apr 10th, 2007, 04:21 PM
#2
Re: [2005] Creating a setup for XML Web Service
Steve, a button which the user has to press to inform the user that the web service is pretty redundant. The installer that you create that comes with Visual Studio will automatically inform the user that setup is complete.
Testing it is a different matter, depending on how complex the web service is, it may be a simple matter of browsing to the URL, or it may involve actually invoking a few methods in it.
-
Apr 10th, 2007, 10:21 PM
#3
Thread Starter
Frenzied Member
Re: [2005] Creating a setup for XML Web Service
Hello,
Thanks for your reply.
I did explain that to my boss. But he said that was not good enough. There has to be a button that he can click that will inform him that the web service has been installed ok.
Currently i am looking into custom actions.
Any more advice would be most grateful,
Steve
-
Apr 11th, 2007, 09:09 AM
#4
Re: [2005] Creating a setup for XML Web Service

Well, alright.
Yes, you want custom actions. What you can do is, knowing the URL at which your web service now exists, send a WebRequest to the URL. If you get a 200 OK, then you know that the web service exists. If you want to take it a step further, then you can actually create a form that references that web service and invoke one of its methods, say, a test method (yeah!) that returns a dummy value. Just to show that you can invoke methods.
-
Apr 11th, 2007, 10:37 PM
#5
Thread Starter
Frenzied Member
Re: [2005] Creating a setup for XML Web Service
Hello,
Thanks for the help.
There is another problem which I am having with. The web service has a connection string in the web.config file. Only the user will know the details of the connection string (server, database, userID, and pwd) when they install the web service. This so that they can install on any machine and use a different database connection string. Only the user will have the details for this.
Is there a way to get the information from the user that will allow you to update the connection string?
I have a created a web setup deployment and added custom action, installer class, and user interface(if you right click the setup file in the solution explorer | view | user interface) to collect the details. The code for this is as follows:
vb Code:
Public Overrides Sub Install(ByVal stateSaver As System.Collections.IDictionary)
MyBase.Install(stateSaver)
Dim database As String = Me.Context.Parameters.Item("database")
Dim server As String = Me.Context.Parameters.Item("Server")
Dim userID As String = Me.Context.Parameters.Item("UserID")
Dim pwd As String = Me.Context.Parameters.Item("pwd")
MsgBox(server)
MsgBox(userID)
MsgBox(pwd)
MsgBox(database)
End Sub
There was an error message with the database variable ("path database not found"), could never get that one to work. Another problem with the password field you cannot make it so that it blanks out the text. These user interfaces are not very flexible, and they are very standard.
I am new to deployment, so go easy on me.
Thanks a lot once again,
Steve
-
Apr 12th, 2007, 07:35 AM
#6
Re: [2005] Creating a setup for XML Web Service
You're only attempting to get the parameters and display them in a messagebox, but you're getting this error.
I suggest you change the variable from database, which seems to be a reserved keyword, to something else like db or strdb. Then try to see if this code works.
I have not done a lot of custom actions in installers, so I am not sure what you mean by
Another problem with the password field you cannot make it so that it blanks out the text.
Either way, you are going about this the right way. You can't get much further with this unless you were to go for a more flexible third party installer for which you may or may not have the time and resources.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|