I have created a default Mvvmlight silverlight 4, and it runs successfully displaying the app in the browser.
If I put a break point in the constructor of the MainPage, and debug the app, the debugger does not break. How do I configure this so I can debug the silverlight app?
Rgds
Douglas
I think I may have been having another issue. Are you Attaching to the silverlight process? Just because you are debugging by hitting the button, doesnt mean you are attached to the silverlight process. This was a big change for me coming from a WPF/Windows Forms background.
I added a Web project and linked it to the mvvm silverlight app.
Also I am using firefox as default browser and there is a config tweak that needs to be done before the debugger can attach to firefox. see Debugging Silverlight with VS and Firefox for details.
Related
I'm an ASP.NET Web Forms developer who has recently switched over to an MVC web app.
I'm having difficulty working out the quickest way to preview code changes when running the MVC web app through the integrated Visual Studio web browser.
In web forms, I can make a change to the codebehind and simply refresh the page and it's all good.
In MVC, I seem to have to close the tab in the browser, return to Visual Studio and press F5, wait for it to build every single dependent project and open up a new tab in the browser to display the page. This is so much slower than how it works in Web Forms it's driving me to distraction.
Am I doing things right? Is there a way to speed this cycle up?
The view pages themselves are compiled dynamically and thus any changes to these can be viewed simply by saving the changes and refreshing the pages in the browser. Changes to code made elsewhere, however, will require a rebuilt after which you can refresh the page.
Pressing F5 will start the web server (if it isn't already started) and then attach a debugger to the process after which it will fire up the web page. The first two steps are very slow, and you should avoid them unless you specifically need to start the web server or debug the application.
So
Changes to view: ctrl+s -> refresh web page (f5)
Changes to code: ctrl+shift+b -> refresh web page (f5)
I used to find setting my project to run via IIS, rather than Cassini, made it a bit quicker. If you've made changes to the code, you'll still have to compile the solution, but at least this way you aren't waiting for Visual Studio to slowly crank itself into gear every time.
Found this article that might provide some clues too:
What are the (dis)advantages of using Cassini instead of IIS?
We're developing .Net Application using asp.net and C# and .Net Framework 3.5.
We are using windows form message box in a .Net application.
This windows form works great on the debug mode but once we publish the application this message box won’t work.
We are referencing System.Windows.Form.dll in order to use the message box features.
Kindly advice if we need to register this DLL or follow some configuration steps in order to solve this problem.
Thank in advanced,
Jad
Don't use MessageBox in a web application. It will show up on the server console, there's nobody around to click the OK button. I assume that ASP.NET has some counter-measures against it, given that it is such a serious denial-of-service attack.
If you are using unreferenced classes a project/solution is usually not even compiled.
So probably the problem is in another place. Are you sure that the code that should display the MessageBox is executed?
EDIT: When you develop web applications (ASP.NET), as described by you in comments, you cannot use Winforms MessageBox.
Try showing it with javascript, if you really need it
Response.Write("<script>alert('This a message')</script>");
I'd like to run drop shadow on Bitmap class in ASP.NET and I'd be really happy if GPU could do that. Any chance of this happening?
Update: I'd like to do that on server side. It doesn't really have to be ASP.NET app, it could be console app or windows service.
The issue is there is no hardware accelerated method to capture a visual to a bitmap. RenderTargetBitmap uses the software render path. You can however get RTB to work in an ASP.NET application, but it is not a supported scenario.
How about running Silverlight embedded in ASP.NET?
I am compiling asp.net 2.0 code. I have IE 8. When I compile application, it open two browser. One browser is blank and other one show web form after a while.
why it happening?
You have 2 web projects in the solution and it's starting both of them up. To avoid this, go to properties on the one you don't want, the Web tab, then change the Start Action to Don't open a page.
I have 2 asp.net web applications, one of which is the main application and the second one is referencing the first application for like master pages , themes etc, and the main frameset that will point to the second application's webform based on database values (menu generated from database);
All my actual forms are in the second application, but the problem is when I set a breakpoint on the javascript file on my second application, it doesnt go into the breakpoint?
Any advice please? I need to get the debugger working, without having the need to put in the "debugger" keyword in javascript if possible.
My IDE is visual studio 2008 SP 1 and IE 8 as the browser.
Cheers
Do you have the solution set up to start up both projects with debugging when you start the debugger? To set multiple startup projects, right-click on the solution. Choose Set Startup Projects. In the dialog, select multiple startup projects and set the two web sites to start up with debugging when the debugger is started.
For what it's worth, I usually like to debug my javascript in Firefox with Firebug. I much prefer that to the developer tools in IE 8.