Installing a software without admin privileges via Regedit - windows

I want to install an application which is installing in AppData folder. Normally, they do not need admin rights but still my application is asking for permission. This is an Excel Add-In exe file.
I have tried by using a bypass method, by adding a batch file.. All these did not work for this. I can`t change the privileges of a machine and I need to do modification for the setup only.
Now I`m trying to install this via regedit. I want to add a batch file to the setup. Anyone know how to do this?

Related

Inno Setup : how to integrate admin credentials in the installer

I want to create an installer that:
- install a software package
- copy a host file in the user system
without any user installation except launching the installer.
I need this installer to run as admin but I do not want to disclose the admin login/password to users but instead I want to embed it in the installer itself. How can I insert the admin credentials within the installers, please ? Is it even possible ?
I've looked into the forums but did not find what I'm trying to do.
Thank you for your help and support,
Fred
You basically need this:
Make Inno Setup installer request privileges elevation only when needed
(the old code in the second part of my answer with an explicit code for the elevation for Inno Setup 5)
Except that instead of simply re-running the installer with runas verb (which needs entering the Administrator credentials manually), you need this:
Inno Setup run/execute code as another user

adding a service to windows from vb.net

I've created a windows service application and I'm working on the installer for this service application at the moment, as there's lots of user options that need defining.
Previously when I needed to create a service I've just created a .bat file containing a relevant SC Create command in temp and executed it to add my service, however I wondered if there's a way to add the service directly rather than creating and executing a bat file.
You don't need the temporary .bat file. You can run any command through Process.Start without a temporary file.
Maybe you should think about your installer technology though. A VB.NET executable means people will have to run an installer for that first, then start it to have an installer for the service. I would be slightly amused by having to install the installer.
Wix for example can build installer packages that install a service. Other alternatives are out there too (but this one is free).

how to install Go language on windows without admin rights?

I don't have admin rights on my Windows machine and I am trying to install Go whose installer needs admin rights to complete the installation.
Is there any way to install Go on Windows without admin rights?
Can you download the Windows ZIP archive and extract it to somewhere in your User folder?
You would then need to update the GOROOT and PATH environment variables accordingly.
The question is still relevant and the preceding answer is still correct, but the link should be updated to https://go.dev/dl/ to obtain a Windows zip archive and not the msi installer.
It is also worth noting that environment variables may be found and edited by using the search bar to find "Edit the system environment variables" in the control panel.

InstallShield 2012 error code 1925: Requires admin privileges for setup

I'm trying to package and deploy a wpf application. I used install shield and I have created the setup file. When I try running the setup file it keeps throwing this error code
1925: it needs admin privileges to run the setup.
How do I configure the setup file to be run by any user? Should I make any changes in the registry during the creation of setup file in install shield? Is there anyway to work around this problem?
Thanks
It sounds like you're trying to create a per-user installation. Since Windows Vista, this requires several steps, but was made simpler with Windows 7. I would check a verbose log in case it highlights any specific problems, and if not, follow this general advice:
If this is always a per-user installation, set General Information > Require Administrative Privileges to No and set the ALLUSERS property to empty.
If this is only conditionally per-user, leave them as Yes and 1 respectively, and use the MSIINSTALLPERUSER property with ALLUSERS=2 to select a per-user installation at run time. Note that this only works on Windows 7 (MSI 5.0) and later.
Ensure that your setup.exe, if you are using one, does not elevate. Set Required Execution Level to Invoker in the setup.exe tab of the Releases view.
If you are not using MSIINSTALLPERUSER, ensure that you are not installing any resources to any machine locations. This includes installation files to the ProgramFilesFolder, registry keys to HKEY_CLASSES_ROOT or HKEY_LOCAL_MACHINE, or other machine-level items such as Windows Services. Note that you may have to exclude services from MSIINSTALLPERUSER scenarios as well.

How to delete application file from AppData\Roaming folder

I am using windows installer to create setup project.
How I can remove/delete application files from AppData\Roaming folder when application uninstalled.
I tried added a special folder and set DefaultLocaltion to [AppDataFolder] but it didn't working.
Do I need to do anything else?
I'd need to understand what you are trying to do to give you specific advice. In general what you are trying to do would be OK removing files from CommonAppDataFolder but not AppDataFolder as trying to clanup user data from multiple user profiles is not a best practice. Additionally trying to cleanup Roaming Profile User data is outright impossible because the other users aren't logged on.
You'll want to read:
Managing Roaming User Data Deployment Guide
Assuming you are trying to do what I think you are, you'll need a cleanup script / exe that you leave behind on uninstall and a custom action to write to the registry during uninstall ( MSI can't do this natively ) to call that script/EXE. You'll want to leverage the Active Setup trick as described here:
Using Active Setup to Repair User Settings
The way it'll work is your uninstall leaves the EXE and registry entry behind so that when a user logs on it's roaming data gets pulled down from the server to local and Active Setup realizes it hasn't run the script yet. The script runs (once) and the data is deleted. When the user logs off the data is replicated / deleted on the server. Then they log on again it doesn't run again.
By default Windows Installer does not remove the files created by your application, after the installation. To do that you need to either write your own custom action, that will run upon uninstall, or depending on the tool used for authoring the MSI, you can use built-in options for cleaning the application locations, as some tools have this support.

Resources