BrowserLink MVC 6 - Not Working - No Extra Code Injected - asp.net

How do I get BrowserLink to work in MVC6 - using RC1 Release 1. Using Visual Studio 2015 Update 1.
Browsers never appear in Browser Link dashboard. No extra js is injected or extra web calls made by site so it just seems to not be adding browser link code.
I have app.UseBrowserLink(). I am running in Development mode, debug. I have tried CoreClr and Full Framework. This happens even with a brand new Asp.net 5 web template with no changes made to it.
What else do I need to do? Does Browserlink actually work for anyone with ASP.NET 5 RC1?
I would also add I ran older projects based on MVC5 and Browserlink works on them without issue.

Seems to be an issue with the installation of "Microsoft ASP.NET 5 RC1 Update 1". Go into Control Panel > Programs and Features > Click "Microsoft ASP.NET 5 RC1 Update 1" and press Change > Repair.
Fixed it for me on three of my development machines.

Related

Missing ASP.NET 5 Templates

I am following this setup tutorial
https://docs.asp.net/en/latest/tutorials/your-first-aspnet-application.html#create-a-new-asp-net-5-project
And have come across a problem. In the tutorial the instructions are as follows:
Start Visual Studio 2015. From the File menu, select New > Project.
Select the ASP.NET Web Application project template. It appears under
Installed > Templates > Visual C# > Web. Name the project ContosoBooks
and click OK.
This is fine, but in the next step :
In the New ASP.NET Project dialog, select Web Application under
ASP.NET 5 Preview Templates. Also, make sure the Host in the cloud
checkbox is not selected and click OK.
I am seeing no ASP.NET 5 Preview templates!
The only thing I am noticing is that my Authentication states No Authentication but I am signed in so I am not sure what this means or whether or not this is a factor.
The version I have installed of Visual Studio is "Community 2015".
I have already gone through the perquisites as outlined in This Article.
I am hoping that someone with a more thorough knowledge on the topic can help me out as I have not been able to find any threads etc. of the same issue or what could be causing the Templates to be missing.
Asp.net 5 templates no longer exist - they are renamed to Asp.net Core: ASP.NET 5 is dead - Introducing ASP.NET Core 1.0 and .NET Core 1.0
So, when creating your project, instead of picking "ASP.NET Web Application" as it is in the video - you would select "ASP.NET Core Web Application" and then on the next page those 3 templates (Empty, Web API, Web Application) are the same as the video's asp.net 5 preview templates
VS 2015 Preview is going under ASP.net Core web application. If you cant see that one under templates you may go to this site and download .NET Core 1.0 for Visual Studio then install.
I have concluded, by following another stackoverflow question on How to check the ASP.NET version loaded on a system as I noticed that the templates were categorized in the ASP.NET versions (4.6.1 & 5) in the tutorials but mine were not.
So I then checked and my files in C:\Windows\Microsoft.NET\Framework are as follows
Revealing no v5.0 directory. I rectified this and now all of the templates are available
AMENDMENT:
To fix it:
I went to http://www.asp.net/downloads and downloaded ASP.NET MVC 5
I ensured I had Developer Tools checked in the download process.
This issue was now resolved - As I then had the MVC 5 template files. Because I downloaded them, so I had them... and no longer didn't have them.
ALTERNATE FIX:
Furthermore From my research, some people had not included Developer Tools. To resolve: go to old mate 'Add or remove programs' and find your Microsoft Visual Studio 20xx install, 'change' and install Microsoft Web Developer Tools
I have had the same problem but it is actually even better because "The new dialog enables you to change the default authentication options for many of the templates. For example, when you create an ASP.NET Web Forms project you can select any of the following options:
No Authentication
Individual User Accounts (ASP.NET membership or social provider log in)
Organizational Accounts (Active Directory in an internet application)"
check out this >> http://www.asp.net/mvc/mvc5
I recently had this problem and finally fixed it by uninstalling (control panel -> uninstall a program) Microsoft.NET Core and Microsoft Visual C++ redistrutable 2015 (x64 & x86) and then re-installing the asp.net core rc2 (https://www.microsoft.com/net/core#windows or possibly check Tools->Extensions and Updates->Updates inside of Visual Studio).
I uninstalled the Visual C++ redistrutables because I kept getting an error when trying to re-install asp.net core rc2. It kept telling me that it already existed even after I had just uninstalled it and the update was showing in the "Extensions and Updates" section of Visual Studio after trying (but failing) to install the asp.net core rc2 update.

Can Local Build Deployment Settings Be Changed in VS 2013

A Little Background:
My team has a somewhat outdated ASP.NET MVC solution that I have been tasked with upgrading as current as possible. We're migrating up from MVC 2 and WebPages (ASPX/ASCX) to MVC 4. The solution is rather large (20+ projects) and most of it is working properly. We have run into an issue though where some of the aspx pages throw the compiler error:
> "BC30456: 'InitializeCulture' is not a member of 'some_extended_view_name_here'...
Most of the digging I came up with on the issue recommends that when publishing, you unselect "allow this precompiled site to be updatable". Problem is that when running locally via the "Run/Run Without Debugging" buttons, you aren't publishing per-se. So...
TL/DR: Is there any way to change the 'publish' settings when using the run or run w/out debugging buttons for MVC websites in Visual Studio 2012/2013? I have looked and looked, but can't find anything suggesting it's even possible.

Visual Studio 2015 Asp.net 5.0 Dynamic development does not work in debug mode

So I installed VS2015 CTP6. In the blog of Scott it advertises:
Dynamic Development.
In Visual Studio 2015, we take advantage of dynamic compilation to provide a streamlined developer experience. You no longer have to compile your application every time you want to see a change. Instead, just (1) edit the code, (2) save your changes, (3) refresh the browser, and then (4) see your change automatically appear.
Well, if I do that visual studio kills the browser on the save action.
What am I doing wrong?
Created a new project, asp.net 5 and switched runtime to coreclr. Tried IIS express & "web"..
The new edit & continue functionality for Roslyn currently does not work with the debugger attached. This will be fixed in a future release. You can start without debugging (ctrl + F5) if you want edit & continue support.

Webforms application .NET 4 in Visual 2013

I have a quick question concerning creating an web forms application with visual 2013 express. I'm working on older servers (Windows 2003) which cannot handle anything greater than .NET 4.
When I go to create my application with visual studio 2013 I go to the Visual Studio 2012 tab, where MVC 4 is listed and choose the web forms application there. What I've learned though, is that it automatically sets the framework to 4.5 still, so I have to change it to 4. In doing so, the NuGet packages get messed up and I have to reinstall them all. I discovered after reinstalling them all it's still messed up and I'm getting build errors. I assumed because I choose to use an older version of webforms, it would automatically set my framework up for me as well. Doing a little troubleshooting I discovered that even when you choose to create a MVC 4 application it still sets the framework to 4.5 and messes everything up when you try to change it.
I'm thinking about just downloading an older version of visual but I don't have admin rights to my computer and that is a pain. Any insight?
I'm painfully new to this material, so everything in layman's terms is appreciated!
when you select MVC 4 Web Application, or any of the other templates, there is a drop down at the top that allows you to select which Framework you would like to use. I'm using professional, it may be different in express.
http://msdn.microsoft.com/en-us/library/bb398202.aspx

Javascript errors after upgrading to .NET 4.0

I have inherited a working VB.NET 2.0 web app that has several User Controls with GridViews inside Update Panels. After running the VS 2010 Upgrade Wizard, the app runs fine in the debugger except for a couple of these Gridviews. In these, update and delete work but adding a new item causes the following javascript error when Save is clicked (calling DoPostBackWithOptions):
Microsoft jscript runtime error
Sys.WebForms.PageRequestManagerServerErrorException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
My theory is that the code is fine (I haven't touched it) and that there is some sort of configuration issue causing this. I have looked through SO and elsewhere and have tweaked my web config and updated the Ajax toolkit assembly. I got nowhere stepping thru the ScriptResource.axd javascript throwing the error. Any suggestions?
Update
The app works fine if I upgrade it to .NET 3.5 using the VS 2008 wizard. However, if I then upgrade that to 4.0 with VS 2010 the problem resurfaces.
Have you tried setting the controlRenderingCompatibilityVersion? The upgrade process should have included it for you, but it might be the cause of your heartache. It's in the <pages... tag of your web.config file...
This is only a workaround not a fix. But I figured I'd add it to help anyone else that might have a similar issue.
What I have figured out is that the project upgrades to .NET 3.5 just fine but that going 4.0 breaks it. I am not sure if the framework breaks it or the upgrade wizard does.
So the successful path for me has been:
Open in VS 2008 and run the upgrade
wizard to upgrade to 3.5.
Open the project again in VS 2010
and run the upgrade wizard but opt
to leave it on the 3.5 framework.
At this point the project behaves fine and I can used VS 2010 to make my updates.

Resources