Visual Studio 2015 Xamarin tools - visual-studio

I created a solution in Visual Studio 2015 using the Xamarin project type. During the initial creation, it did something to my network settings. I figured it was just doing what it needed to do to pretend to be an android phone or something. However, now every time I reboot my computer I have to go to my network settings and repair the connection or I can't use the internet.
Google search has so far been less than productive.
Does anyone know what I can do to permanently repair this issue?

so this required resetting my whole ethernet setup. I used this guide: Digital Citizen network reset guide. The gist of it is this:
Open the Settings App in Windows 10
Enter the "Network and Internet Settings" category
Select the "Status tab from the left-hand side.
Select the "Network reset" command from the page that's displayed.
You will be prompted to restart your computer. Click yes to all the options and make sure your work is saved. Restart your computer if it doesn't do so automatically.
I do not know if Visual Studio will mess this up again.

Related

Visual Studio Community 2015 won't sign in. How do I fix this?

Whenever I open Visual Studio Community 2015, it asks me to update my license. It won't let me download an updated license, as every time I try, it tells me to check my network or proxy. I do not have a proxy, and my network is just fine.
In addition, when I click the "Add Account" button, which is supposed to let me add an account, it has a message box pop up saying "Configuration system failed to initialize.".
When I click the sign in button, the sign in window pops up, but it disappears immediately, then the program crashes.
Here are a few pictures:
Visual Studio Community 2015
How do I fix this?
I'm afraid it's something with your specific machine. Given that you've cleaned out the computer and made a full reinstall of the OS and tried with a new account at Microsoft, there's no rational reason why it's not working in a general case.
I've tried those steps and it worked out. You might want to retry the clean-reinstall-reregister steps again, in case something went missing the last time.
As a personal side note I can safely point out that this shouldn't happen. Definitely not to good people like us. :)

TF400324: Team Foundation services are not available from server <Server/CollectionName> in Visual Studio 2012

When I open my existing solution in Visual Studio 2012 professional, I got the above error. This used to work but something messed up after the computer is rebuilt.
I have installed Visual Studio 2015 Community and can connect to the same
collection correctly.
I also tried to use a browser to connect to the same collection. It works fine also.
Cleaning all files in AppData\Local\Microsoft\Team Foundation\4.0\Cache does not work.
It should not be a firewall or proxy issue since Visual Studio 2015 works.
Anyone knows what is wrong with Visual Studio 2012 and how to fix it?
Edit:
This error can happen with later versions of TFS:
Team Foundation Error
TF400324: Team Foundation services are not available from server TFSServer\DefaultCollection.
Technical information (for administrator):
Unable to connect to the remote server
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond xxx.xxx.xxx.xxx:443
According to this blog the solution is (and Yes it worked for me)
Close all instances of Visual Studio
Open the Task Manager and check if any TFS Services are running. Select each of them and click on End Process Tree (in my case I did not find any of them to End)
Browse to the folder %LocalAppData%\Microsoft\Team Foundation\
and then select the folder with your TFS version and go inside the Cache folder.
for example, in my machine the path was %LocalAppData%\Microsoft\Team Foundation\7.0\Cache and it should be the same on your machine with the difference of the TFS version folder name.
Delete everything in that Cache folder.
Start Visual Studio and build the project
I got this error in TFS2017. For me the problem was a Self-Signed Certificate.
Open the TFS URL in IE and you will see a Red Address Bar:
Click the "Certificate Error" in the address bar:
Then select "View Certificates":
If clicking "View Certificates" doesn't work, right click on page > Properties > Certificates.
If the Install Certificate button is hidden to make it visible you will have to Open Internet Explorer Options > Security > Sites > type the TFS server URL > Tick Require server verification > click Add. (If the dialog is disabled see the guide Trusted Sites Dialog is Disabled at the end of this answer).
Once you have the install certificate button available, select “Install Certificate”.
This will launch the Certificate Import Wizard. Make sure to Choose the option “Place all certificates in the following store” and select browse.
Select Trusted Root Certification Authorities and click Ok.
Click Finish on Completing the Certificate Import Wizard:
Click yes on the security warning to install the certificate.
=================================================
Trusted Sites Dialog is Disabled
You can check to see if the site is Trusted, on Windows 7 the path is:
HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMapKey
The key should contain several string values with a name indicating the URL and numeric data indicating the zone, one of the following by default.
0 = My Computer
1 = Local Intranet Zone
2 = Trusted sites Zone
3 = Internet Zone
4 = Restricted Sites Zone
If the TFS site is not listed in the registry then add it manually. Restart Visual Studio and try to connect to the TFS server again from Visual Studio. Once you can connect you can also remove the TFS server from the Connection List. I suggest removing it and adding the FQDN url which will most likely already have a Trusted Site rule.
Edit
Hit this again. This time it was caused by a problem with a network card that was replaced on the weekend by our telecommunications provider.
This issue is happening when server is not responding, In my case server hosting TFS was down, we restarted and get connected.
Try clear both local TFS cache and Visual Studio Cache
clear visual studio cache under
%APPDATA%\Microsoft\VisualStudio
clear TFS cache under
%LocalAppData%\Microsoft\Team Foundation
...better late than never...
I just had a user run into same error TF400324 connecting VS2012 to TFS2015 (hosted in a virtual private cloud). TFS Web Access worked fine for her, but Visual Studio 2012 UI was stuck in offline connection.
FIX: She managed to get VS connected again after clicking Team Explorer > Connect | {TeamProject}, Then select desired Team Project below the TFS Server connection (see screenshot attached).
NOTES:
I suspect clearing client-side TFS cache might also fix, but all VS instances would need to be closed then "Connect to Team Project Connection" re-established. Just disconnecting and reconnecting VS to TFS did not clear the "offline" state.
Error she saw was in VS output window:
This solution is offline. [Team Foundation Server: {//TFS Collection URL}]
The solution was offline during its previous session and will remain offline.
TF400324: Team Foundation services are not available from server .
Technical information (for administrator):
Page not found.
NOTE: I recently moved TFS to different domain requiring SSH connection and localhost port mapping. I have users going offline much more frequently due to different proxy routing depending on whether they are at work or connected more directly to the Internet.
For me the fix was simply running Visual Studio (2010) as an administrator.
In my case, my company VPN my Host machine was connected to was preventing me to access the tfs on a VirtualBox VM, returning this exact error message.
We solved it by adding a specific exclusion to ESET / Kaspersky AntiVirus for the devenv.exe
"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\devenv.exe"
Its been working great ever since.
I get basic idea from this link
Soluton for me was to run the standalone TFS installation. This is for 2017, but worked to fix my VS2019.
https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=TeamExplorer&rel=15
Bit of background...
I'd been having this issue since 2017. Tried all the usual suggestions on here, cache clearing, config file editing etc. but would always have to come off my organisation's network to check code in, as it was proxy related. TFS was trying to connect to a proxy server ip that had been decommissioned, no one from the service desk could work out why. Couldn't find any reference to this old ip in any config files.
Installed VS2019 hoping it would solve the issue but it persisted. Eventually I thought of trying to uninstall it as a component and re-installing it. Couldn't find a way to do that but in my search I found the standalone installer for Team Explorer, albeit for VS2017.
After installing, I ran this, opened up Manage Connections in the Team Explorer connections page and did what I needed to connect to the repository from there. Worked first time. Closed Team Explorer 2017, opened my VS2019, and everything seemed fine in there as well.
Amazed my problem is finally solved!
This error is usually related to the TFS cache. Before you clear the cache folder, please make sure you have closed all instances of Visual Studio and also try to open Task Manager and check if any TFS Services are running. Select each of them and click on End Process Tree.
And also clear the server cache Server cache, the path like C:\ProgramData\Microsoft\Team Foundation\Web Access
Then restart Visual Studio and run as Administrator Mode.
More details you can refer this blog (archived version at the bottom) and also could try the better fix.
Note: Make sure you are working on a different workspace rather then VS2015's.
For me it was the windows firewall causing this problem : TF400324 The underlying connection was closed.

Visual Studio 2013 remote debugging

I own a Surface RT and I was programming in Visual Studio 2013.
I found the tutorial online on how to set it up but I couldn't do it. Right by the part Visual Studio tries to find remote connections it doesn't find the surface. If I reboot the surface, right about when I open the remote debugger there is a small (10 seconds) period where it becomes available on my Visual Studio to select but it disappears right after never giving me the change to remote debug the app.
Does anyone had this problem before?
You can try adding the Surface's address manually.
Right-click your Windows 8 project, select Properties, go to Debug tab. Here select Target device: Remote Machine and then in Remote machin field enter the address and port your Surface shows you when you run the Remote Debugging Monitor (in the very first message you will see something like Msvsmon started a new server named 'SOMEADDRESS:PORT'. Waiting for new connections.). This usually helps when Visual Studio fails to find the device on it's own.

How do I get the serial key for Visual Studio Express?

I am Visual Studio 2010 Professional user. But for a reason I need Visual Web Developer 2008 Express edition.
I downloaded this, but I need the serial key to activate the product, otherwise it will expire in 30 days.
When I go there, I got this error:
"Thank you for your interest in registering Visual Studio. We are currently experiencing issues with the registration process. We are working on this and will have it fixed as soon as possible. Please try to register your product again at a later time. We apologize for the inconvenience."
I tried for a long time, but I got the same error every time. Is there any other way to get the serial key?
I have an improvement on the answer #DewiMorgan gave for VS 2008 express. I have since confirmed it also works on VS 2005 express.
It lets you run the software without it EVER requiring registration, and also makes it so you don't have to manually delete the key every 30 days. It does this by preventing the key from ever being written.
(Deleting the correct key can also let you avoid registering VS 2015 "Community Edition," but using permissions to prevent the key being written will make the IDE crash, so I haven't found a great solution for it yet.)
The directions assume Visual C# Express 2008, but this works on all the other visual studio express apps I can find.
Open regedit, head to HKEY_CURRENT_USER\Software\Microsoft\VCSExpress\9.0\Registration.
Delete the value Params.
Right click on the key 'Registration' in the tree, and click permissions.
Click Advanced...
Go to the permissions tab, and uncheck the box labeled Inherit from parent the permission entries that apply to child objects. Include these with entries explicitly defined here.
In the dialog that opens, click copy.
Note that in Windows 7 (and 8/8.1, I think), it appears the copy button was renamed to add, as in add inherited permissions as explicit permissions.
In Windows 10, it appears things changed again. #ravuya says that you might have to manually re-create some of the permissions, as the registry editor no longer offers this exact functionality directly. I don't use Windows very much anymore, so I'll defer to them:
On Win10, there is a button called "Disable Inheritance" that does the same thing as the checkbox mentioned in step 5. It is necessary to create new permissions just for Registration, instead of inheriting those permissions from an upstream registry key.
Hit OK in the 'Advanced' window.
Back in the first permissions window, click your user, and uncheck Full Control.
Do the same thing for the Administrators group.
Hit OK or Apply.
Congratulations, you will never again be plagued by the registration nag, and just like WinRAR, your trial will never expire.
You may have to do the same thing for other (non-Visual C#) programs, like Visual Basic express or Visual C++ express.
It has been reported by #IronManMark20 in the comments that simply deleting the registry key works and that Visual Studio does not attempt to re-create the key. I am not sure if I believe this because when I installed VS on a clean windows installation, the key was not created until I ran VS at least once. But for what it's worth, that may be an option as well.
The question is about VS 2008 Express.
Microsoft's web page for registering Visual Studio 2008 Express has been dead (404) for some time, so registering it is not possible.
Instead, as a workaround, you can temporarily remove the requirement to register VS2008Exp by deleting (or renaming) the registry key:
HKEY_CURRENT_USER/Software/Microsoft/VCExpress/9.0/Registration
To ensure that this is working beforehand, click Help -> register product within VS2008.
You should see text like
"You have not yet registered your copy of Visual C++ 2008 Express
Edition. This product will run for 10 more days before you will be
required to register it."
Close the application, delete that key, reopen, click help->register product.
The text should now say
"You have not yet registered your copy of Visual C++ 2008 Express
Edition. This product will run for 30 more days before you will be
required to register it."
So you have two options - delete that key manually every 30 days, or run it from a batch file that also contains a line like:
reg delete HKCU\Software\Microsoft\VCExpress\9.0\Registration /f
[Edit: User #i486 confirms on testing that this workaround works even after the expiration period has expired]
[Edit2: User #Wyatt8740 has a much more elegant way to prevent the value from reappearing.]
Getting a product key is free. Here is how I did it:
I just downloaded the 2012 Express install ISO image. After install I got the message "This product will expire in 30 day(s). Registration is required for the continued use of Microsoft Visual Studio Express 2012 for Web."
On that same screen is a register online link. Clicking that I signed in with my live account, updated my profile, and got a registration key.
Visual C# Express 2005 ISO File does not require registration
I believe that if you download the offline ISO image file, and use that to install Visual Studio Express, you won't have to register.
Go here and find the link that says "All - Offline Install ISO image file". Click on it to expand it, select your language, and then click "Download".
Otherwise, it's possible that online registration is simply down for a while, as the error message indicates. You have 30 days before it expires, so give it a few days before starting to panic.

How to work offline with TFS

Our TFS server has some temporary connectivity issues right now, and as such VS has gone unresponsive, leaving 50+ developers unable to work!
Is it possible to switch TFS into an offline mode in the event of such an issue?
See this reference for information on how to bind/unbind your solution or project from source control. NOTE: this doesn't apply if you are using GIT and may not apply to versions later than VS2008.
Quoting from the reference:
To disconnect a solution or project
from source control
In Visual Studio, open Solution
Explorer and select the item(s) to
disconnect.
On the File menu, click Source
Control, then Change Source Control.
In the Change Source Control dialog
box, click Disconnect.
Click OK.
The 'Go Offline' extension adds a button to the Source Control menu.
https://visualstudiogallery.msdn.microsoft.com/6e54271c-2c4e-4911-a1b4-a65a588ae138
plundberg: The "disconnect" button is only available for the TFS provider starting in VS 2008. Even then, I'm not sure if it's officially supported. The recommended way to use the Go Offline feature is to [re]open the solution.
Martin Pritchard: if you get stuck mid-operation, you can force VS to timeout by pulling the network plug (literally) or running ipconfig /release.
Once you're marked offline, here's a step by step guide to working in that mode: http://teamfoundation.blogspot.com/2007/12/offline-and-back-again-in-vs2008.html
More detailed info on tweaking the behind-the-scenes behavior:
http://blogs.msdn.com/benryan/archive/2007/12/12/when-and-how-does-my-solution-go-offline.aspx
http://blogs.msdn.com/benryan/archive/2007/12/12/how-to-make-tfs-offline-strictly-solution-based.aspx
There are couple of little visual studio extensions for this purpose:
For VS2010 & TFS 2010, try this
For VS2012 & TFS 2010, use this
In case of TFS 2012, looks like there is no need for 'Go offline' extensions. I read something about a new feature called local workspace for the similar purpose.
Alternatively I had good success with Git-TF. All the goodness of git and when you are ready, you can push it to TFS.
Depending on which tool windows you have open, VS may or may not try to hit the team server automatically when it starts up.
For best results try this:
Close all instances of visual studio
Open an empty visual studio (no project/solution)
See which windows are opened by default, if source control explorer or team explorer or any other windows that use team are opened (and activated) by default, close them or switch them to a background tab.
Close visual studio
You should notice now that you can start visual studio without it trying to hit the TFS server.
I know its just an aside to your problem, but I hope you find this helpful!
If you have a solution open, and TFS is down, you might have trouble going into offline mode. If you close and reopen your solution, a nice little dialog will appear asking you if you want to Go Offline.
Alternatively if you don't want to close/reopen the solution, (as suggested by Bernie) you can install the TFS Go-Offline plugin, then click:
TEAM -> Go Offline
Simply, change the root folder name for your solution in your local machine, it will disconnect automatically.
I just wanted to include a link to a resolution to an issue I was having with VS2008 and TFS08.
I accidently opened my solution without being connected to my network and was not able to get it "back the way it was" and had to rebind every time I openned.
I found the solution here;
http://www.fkollmann.de/v2/post/Visual-Studio-2008-refuses-to-bind-to-TFS-or-to-open-solution-source-controlled.aspx
Basically, you need to open the "Connect to Team Foundation Server" and then "Servers..." once there, Delete/Remove your server and re-add it. This fixed my issue.
If the code has already been checked out by the user that if offline and they have the latest version on their local hd, then they just need to browse to the solution location and open the solution by double clicking sln file. The solution will open in disconnected mode.

Resources