A solution can have references to multiple sub-projects. If you make some code changes on a sub-project but the changes do not seem to take effects on the project, the reference may have been broken.
To check the references in the solution, right click on the Web Site on the Solution Explorer. Select Property Pages on the menu.
In the Property Pages dialogue, select References from the listed items. Check on the lists of the references and make sure the Version of all the sub-projects have the values of Auto Update. If it is a specific version number, your changes of the sub-project will have not effect. To change it to Auto Update, use the Remove button to remove the sub-project from the list and then use the Add button to add it back.
You may also be able to add or remove the References from the Solution Explorer for projects. Just expand the project and look for the References item.
Showing posts with label Visual Studio. Show all posts
Showing posts with label Visual Studio. Show all posts
Thursday, April 25, 2019
Saturday, June 28, 2014
Create a SOAP client from a WSDL with Eclipse or Microsoft Visual Studio
Supposed we have the WSDL file of an existing web service from which we want to create a SOAP client for testing purpose, both Eclipse and Microsoft Visual Studio can help us build one quickly.
The WSDL file can be on the web or on the local disk.
Its URLs could look like the following:
file:///c://path/to/the-wsdl-file.wsdl
http://www.example.com/path/to/the-wsdl-file.wsdl
String quote = client.GetQuote("AAPL");
Dim quote As String
quote = client.GetQuote("AAPL")
Its URLs could look like the following:
file:///c://path/to/the-wsdl-file.wsdl
http://www.example.com/path/to/the-wsdl-file.wsdl
Create a SOAP client in Java with Eclipse
- Create an empty Dynamic Web Project (New->Projects...->Web->Dynamic Web Project).
- Right click on the project and select New->Others.
- In the "Select a wizard" dialogue, select Web Service->Web Service Client, and click the "Next" button.
- Input the URL of the web service in the Service definition box.
- Drag the slider on the left to choose to generate a Test client. Click the "Next" button.
- Follow the prompts to create the client and start Tomcat.
- A web-based test client is generated and we can run a test with it.
- Create an empty Java Project.
- Use wsimport to generate the library for the WSDL, e.g.: wsimport -keep -verbose -d /path/to/eclipse/workspace/project/src /path/to/wsdl-file
- Write the source code for the test client using the generated library.
Create a SOAP client in C# with Microsoft Visual Studio
- Click on menu File->New Project...
- In the "New Project" dialogue, choose the template C#->Test. Change Name/Location/Solution/Solution name as needed. Click the "OK" button.
- On the Solution Explorer panel, right click on the project's References and select Add Service References...
- Input the URL of the web service in the Address box and click the "GO" button. Change the Namespace as needed. Click on the "OK" button.
- The test client is generated and the file UnitTest1.cs file is opened for us to add our test cases.
- Use http://www.webservicex.net/stockquote.asmx?WSDL as an example, We can write something like the below in TestMethod1():
String quote = client.GetQuote("AAPL");
Create a SOAP client in VB with Microsoft Visual Studio
- Click on menu File->New Project...
- In the "New Project" dialogue, choose the template Visual Basic->Test. Change Name/Location/solution/solution name as needed. Click the "OK" button.
- On the Solution Explorer panel, right click on the project's name and select Add Service References...
- Input the URL of the web service in the Address box and click the "GO" button. Change the Namespace as needed. Click on the "OK" button.
- The test client is generated and the file UnitTest1.vb file is opened for us to add our test cases.
- Use http://www.webservicex.net/stockquote.asmx?WSDL as an example, We can write something like the below in TestMethod1():
Dim quote As String
quote = client.GetQuote("AAPL")
Subscribe to:
Posts (Atom)