How to clean up registry settings with uninstall? - excel

I have an installer which needs to add a key to Currentuser under \Software\Microsoft\Office\12.0\Excel\Options. It must be CurrentUser because excel does not look in LocalMachine. I have a customer that requires Admin rights for an install. I found that when the installer was run as the Admin user, the key was created under the Admin users registry settings. To get around this, I wrote a custom action which created the Excel key in Currentuser, and then copied the key to every other user currently logged on to the machine. This seems to work.
The problem i now have is on the uninstall. The registry key is left in place, which causes issues with Excel. What is the best way to get rid of this registry key on an uninstall?
I am using the Windows installer in VS 2010.
Currie

try installing and running Revo Uninstaller. Once it's installed, see if excel is still there to be uninstalled. In REVO, there is a step in the uninstall process where you check the checkboxes, in bold text, of the registry items to be deleted.
http://www.bleepingcomputer.com/download/revo-uninstaller/
(on the site, click "download Now" instead of the "download" button at the top (which is just a link to google leads).

Related

Run shortcut as administrator

In InstallShield 2015 Premier , how to set a shortcut created for an EXE to have ability of Run As Administrator. I have searched every corner in InstallShield, but not find option I need
Thanks
There is no front-end option. However, you can create a registry entry in your project to set up the following:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers]
"C:\\yourapp.EXE"="~ RUNASADMIN"
It may or may not accept [INSTALLDIR] variable, if it does not, you can create registry entry using InstallScript.
Alternatively, you can embed application manifest into your application itself, in which case you won't need to worry about setting admin rights in IS.

Windows Server 2012: trying to copy files via command line, getting permission denied

I'm trying to programmatically copy major folders from C: to E:, for the purpose of automatically backing these folders up. It seems to me, as Administrator, I should have full access like root does on Linux, especially for only reading files.
This makes no sense to me. I'm logged in as Administrator, I run powershell as administrator, and I even went to the Control Panel and moved the UAC slider thing all the way down.
So why am I getting access/permissions errors when trying to copy C:\Users or 'C:\Program Files'?
This will get migrated hopefully, but the answer is that Windows is not like Linux. The Administrator account is not like the root account. It does not, by default, have various rights unless you do the equivalent of a sudo, which is to run the prompt at an elevated rights. Right click on your powershell prompt and choose Run as Administrator.
Dragging the UAC slider down does not turn off UAC, it just turns off the UAC warnings when something wants elevation.

Unable to shelve changes in VS2012 for TFS2010

We are using TFS2010 (for source control only), and until recently everyone was using VS2010. Our developers just installed VS2012.
Pulling down code works fine in Visual Studio. When you go to "Pending Changes" in Team Explorer, we are seeing TF201072: A user or group could not be found. Verify that the users and groups used in your work item type definition have been added to Team Foundation Server., twice, at the top. We can still check-in code from VS - seems this error is ignored.
However, we are unable to shelve changes - when you attempt to shelve, the same error comes up in a popup, and the shelveset is not saved.
We can shelve using the command prompt (tf shelve), and can still shelve using VS2010, so it doesn't seem to be a permission issue. Also, the TFS administrator is not seeing the error message, and can shelve from VS2012 with no error.
Any thoughts as to what could be causing VS to error out here? We've tried clearing out the TFS cache, creating a new workspace, and gone over every option we could find in Visual Studio.
I had the same issue. Tried many different stuff from web sites and non of them helped. Finally find the solution for this. Follow these to make it work:
1) Create temporary AD User
2) You will need to transfer all old user configuration into a new temporary account. If you are OK with using the temporary account you may just keep it and get rid of old account. Go into the machine that TFS is installed and Run this command: TFSConfig identities /change /fromdomain:mydomain /todomain:mydomain /account:oldAccount /toaccount:temporaryAccount
(TFSConfig is in C:\Program Files\Microsoft Team Foundation Server XX.0\Tools\)
3) If you don't want to use temporary account you will need to convert from temp account to your old account. To do that run the same command wit changing the user names:
TFSConfig identities /change /fromdomain:mydomain /todomain:mydomain /account:temporaryAccount /toaccount:oldAccount
That's all you need to do.

How to get Local development STS running

I am in need of help getting Local Development STS running. I just started with MSDN tutorials and got stuck when trying to build WCF service using WIF. So far I did following:
Installed "Identity and Access Tools" in my Visual Studio 2012
Created new WCF Service project in new solution
Right clicked projects name and selected "Identity and access..."
Selected "Use the Local Development STS" option on first tab and changed token
type to "SAML 2.0" on "Local Development STS" tab
Clicked "Ok"
I end up with following that informs me about problems with certificate:
I verified that the file is there physically.
I verified access to it - System, Administrators and my user have full access to it (only last option is unchecked)
I tried to install the certificate manually, but it is protected with password and I cant find it anywhere
I tried to toy around with "Identity and Access..." wizard
I tried to google the answer
I tried to check if I have certificate like that installed, there are tree Personal certificates in my Local Machine store, but I have no idea how to check their subject or whatever else
So far I wasn't successful. Could anyone advise how to fix the situation, so I can be sure I have proper certificate installed, I would be eternally grateful.
Erchi
Are you using the .NET 4.5 tutorials - WIF Code Sample Index?
To check the subject:
Start / Run / mmc
File / Add - Remove Snap In
Certificates - Add.
My User Account - Finish - OK
Expand the tree as required - double click on certificate - Details.

Delete team project from Visual Studio Team Services

I am using Team Services on domain visualstudio.com and I need to delete one project, I found out that I need to use command prompt to delete projects, but when I tried the script it seemed that it doesn't work
My Script is,
TfsDeleteProject
/force collection:https://mytfs.visualstudio.com/DefaultCollection MyProject
My first mistake was that I didn't append DefaultCollection to the URL, but now I get error that I don't have privileges.
Thanks to #Christopher I was able to make the script work.
You can use the following command from the "Developer Command Prompt":
TfsDeleteProject /collection:https://mytfs.visualstudio.com/DefaultCollection MyProject
You can now do it via visualstudio.com
Open the administration context for the team project collection by choosing the gear icon.
Open the menu for the team project that you want to delete.
If you don’t see the actions icon , either you’re not accessing VSTS or you’re not a member of the Project Collection Administrators group.
You must type the name of the team project in order to initiate the delete operation.
Open “Developer Command Prompt” under “Program Files>Microsoft Visual Studio” or in Windows 8 type “Developer“.
In the command prompt, use this command template below to delete your project from TFS. Replace the YourTFSName to yours and also the ProjectName to the name of your project.
TfsDeleteProject /collection:https://YourTFSName.visualstudio.com/DefaultCollection ProjectName
Hit Enter and then Y if you are prompted for confirmation.
Done. Double check by login to your TFS online.
From http://bizvise.com/2013/03/08/how-to-delete-team-project-from-my-team-foundation-service-tfs-default-collections/
Although the accepted answer is absolutely correct and very clear, I managed to get lost and run into that 'grayed out Delete button' issue and just wanted to share what I was doing wrong.
For the folks having issue with grayed out delete button, make sure that you are inside 'View the collection administration page' (as shown in the accepted answer), not inside the project itself.
If the last breadcrumb on the top of your VS Team Services is the name of the project, you are at the wrong place (it looks similar). Here the Delete button (appears on right clicking the project name) will be grayed out.
If you click the link that says 'View the collection administration page' after clicking the Settings(gear), you will be at the right place.
if your project name have space, you must use "MyProject name"
TfsDeleteProject /collection:https://mytfs.visualstudio.com/DefaultCollection "MyProject name"

Resources