I am creating a Silverlight application using .Net 4.0 and integrating it into an ASP.net project that created in .Net 3.5.
Whenever I make a change in the Silverlight project the changes are not reflected into the ASP.net project
You need to ensure your Silverlight app and the website are connected
Adding it to the solution is not enough. You need to make a Silverlight relationship between the website and your Silverlight application.
Right-click on your website project and select Properties.
Choose the Silverlight Applications tab on the left side
Press Add...
Leave Use an existing Silverlight project in the solution checked and select the project you want to add from the Project dropdown.
Leave Add a test page that references the control checked if you want a separate test page for your application.
Press Add and you are done.
The website will now build your Silverlight application and include the output Xap file in its ClientBin folder.
Related
How to create web service (server & Client) in Visual Studio 2012?
like being done before 2012 as
http://www.tutorialspoint.com/asp.net/asp.net_web_services.htm
When creating a New Project, under the language of your choice, select Web and then change to .NET Framework 3.5 and you will get the option of creating an ASP.NET WEB Service Application.
Create a new empty Asp.NET Web Application.
Solution Explorer right click on the project root.
Choose the menu item Add-> Web Service
WCF is a newer technology that is a viable alternative in many instances. ASP is great and works well, but I personally prefer WCF. And you can do it in .Net 4.5.
Create a new project.
Right-Click on the project in solution explorer, select "Add Service Reference"
Create a textbox and button in the new application. Below is my click event for the button:
private void btnGo_Click(object sender, EventArgs e)
{
ServiceReference1.Service1Client testClient = new ServiceReference1.Service1Client();
//Add error handling, null checks, etc...
int iValue = int.Parse(txtInput.Text);
string sResult = testClient.GetData(iValue).ToString();
MessageBox.Show(sResult);
}
And you're done.
--- create a ws server
vs2012 upd 3
new project
choose .net framework 3.5
asp.net web service application
right click on the project root
choose add service reference
choose wsdl
--- how can I create a ws client from a wsdl file?
I´ve a ws server Axis2 under tomcat 7 and I want to test the compatibility
i am using silverlight 5 and hosted the SL5 application.
As we all have seen, when we come in the homepage of this website, we will see a message telling us to install silverlight if we haven't installed silverlight. How to detect if the client machine has not installed silverlight ?
if not installed i need to show a custom message and take the user into micorsoft site in order to download the silverlight instead of the install silverlight message.
i have verified the below URL and did the same thing..
http://www.xdevsoftware.com/blog/post/Si...ction.aspx
but i hosted my application and i did the same in the above url but it does not worked..
i got the default result only but not my customized information's if the client doesn't have silverlight.
i am using silverlight 5.
Regards
gopal.s
Please take a look at http://msdn.microsoft.com/en-us/library/cc838126(v=vs.95).aspx
The Silverlight.js file does all the magic. In fact you if you create a new silver light project in Visual Studio 2010 detection of Silverlight and automatic install is all handled for you.
Silverlight Install and Upgrade Experience has all the information on customizing the install experience
I am writing an eclipse 3.6 RCP application with various menus, navigators, views, wizards etc.
Now I need to add a new wizard. But each time I would like to check how it looks I need to start the whole application, navigate to the menu that contains a button that launches the wizard and then I can see the result.
Is there some tutorials that show how to launch a single wizard from eg a junit test and maybe get some output from some of its pages?
Maybe you are looking for automated UI tests? Such that the tests start eclipse, open the wizard, will in some fields and check the result?
If so, take a look at http://eclipse.org/swtbot/ .
If you only want to check the look of your wizard page, you could use the Google WindowBuilder
This is a UI Designer that has quite nice support for SWT and is able to preview your design.
I develop a Webservice using Netbeans 6.9 and I use an embedded glassfish server to deploy my Webservice (http://some_domain/project_name/ws_for_sl4). On a different server there is deployed a Silverlight 4 client, which should have accesss to the Webservice.
I know that I have to have clientaccesspolicy.xml (under http://some_domain/project_name) however I do not know how to do it. I mean, I do not know in which folder of the netbeans project I need to put clientaccesspolicy.xml to have it automaticly deployed on an embedded glassfish server. To have my SL4 client using the webservice.
Solution:
- put clientaccesspolity.xml and crossdomain.xml under /Web Pages*
- open Project Properties (click right mouse button on a project root), go to Run, and delete a value of "Context Path".
Now your WS will be deployed directly under some_domain as it is required by SL4 (SL4 is looking for these files under the domain name.). SL4 will have no problem to access clientaccesspolity.xml and crossdomain.xml.
In case anyone doesn't like moving their webservice to "root", and instead prefers to have it in http://localhost:8080/aDifferentLocation/MyActualWebService, then placing those XMLs in the project Web Pages folder doesn't cut it.
http://localhost:8080/aDifferentLocation/clientaccesspolicy.xml
and
http://localhost:8080/aDifferentLocation/crossdomain.xml
would not work, as they need to be in
http://localhost:8080/clientaccesspolicy.xml
and
http://localhost:8080/crossdomain.xml
To achieve this, you must track down the folder where your GlassFish server is installed, let's call it [GlassFishInstallPATH] and paste the XMLs into the subfolder called docroot:
[GlassFishInstallPATH]/domains/domain1/docroot/ <--here go the XMLs.
(source)
In case you're wondering how you would do the same thing in Eclipse, you must track down the ROOT folder in your Eclipse J2EE workspace:
C:\Eclipse_j2ee_workspaces\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\ROOT/ <-- the XMLs go here.
I don't want WCF, I only want web service.
Thank you.
They've obscured it, but it's easy enough:
Right-click on your solution, select Add New Project.
In the Framework selection dropdown, select .NET Framework 3.5
Select the Web installed templates listing and you'll find ASP.NET Web Service Application as the last one in the list.
In other words, you can create one in .NET 3.5, but not 4. Now, that being said, it seems like it may be possible to create a .NET 4 template for VS2010, but I'm not a VS2010 guru, so that's for someone else to elaborate on.
Edited to Add: Somebody else posted a response to your question that was also a good answer, I thought, but they deleted it themselves for some reason. I don't remember their user name. I'll repeat it here.
If you create a new Web Application in the solution, you can then Add New Item, and one of the options under Web is "Web Service" at the very bottom.
The only drawback to this is that besides the web service, you also have the usual default items for a web application, namely default.aspx, about.aspx, global.asax, and site.master, as well as the folders Account, Scripts, and Styles. But you can delete these, so no problem. Also keep in mind that the web.config in the Web Application project will be different from that of the Web Service, and that the assembly bindings for the web service will point to ASP.NET v2 & v3.5 (see its web.config), whereas the service in the web application project will default to ASP.NET v4 (through its project file). I don't know if any negative implications exist for either way of working, though I suspect that both will work just fine.
If you select the framework like mentioned above to 3.5 you can select a web service application. If you want it to be targeted at .NET 4.0 framework, go into my project --> Compile --> Advanced Compile Options --> change the target framework to .net framework 4.
You can also change your compile options to target it at a x64 or x86 (32 bit) server.
web.config in the Web Application project will be different from that of the Web Service, and that the assembly bindings for the web service will point to ASP.NET v2 & v3.5 (see its web.config), whereas the service in the web application project will default to ASP.NET v4 (through its project file). I don't know if any negative implications exist for either way of working, though I suspect that both will work just fine.
Here was my resolution:
Right-click on your project name and select to Add Service Reference.
Select the Advance button at the very bottom.
Select the Add Web Reference button at the very bottom.
Proceed as usual. :)