Apathetic userprofile. ENVIRONMENT VARIABLES - environment environment variables

If the file.userprofile is known for your system, you can open it by double pressing the mouse or Enter key. This operation will start associated with the file.UserProfile application installed in the system. If the system meets the file for the first time and there are no relevant associations, the action will end the system offer, find the appropriate software in the computer or the Internet.

Sometimes it happens that the wrong program is attributed to maintain the file type.userprofile. This happens, as a result of hostile programs, such as viruses or malware, but most often this is the result of the erroneous alignment of the application with the extension of the file.UserProfile. If during the maintenance of a new type of files .Userprofile, we will specify the system incorrect program, the system will be mistaken to recommend its use whenever the file of this type will occur. In this case, you should try to re-select the appropriate application. Right-click on the file.userprofile file, and then select the "Open with ..." option "Select the default program" from the menu. Now select one of the installed applications from the above list and try again.

Programs that will open file.userprofile

Manual Editing Windows Registry

If our system does not cope with the extension .USERPROFILE and summed up all automatic and semi-automatic methods of teaching it to this art, it remains manual editing the Windows registry. This registry stores all the information relating to the work of our operating system, including connecting file extensions with programs for their maintenance. Command Regedit. inscribed in the window "Search for programs and files" or "Run In the case of senior versions of the operating system, it provides us with access to the register of our operating system. All operations carried out in the registry (not even very complex, concerning the extension of the file.Userprofile) have a significant impact on the work of our system, so before conducting any modifications it is necessary to make sure that a copy of the actual registry is made. The section of interest - this is the key HKEY_CLASSES_ROOT.. The following instruction shows step by step, how to modify the registry, and specifically the entry in the registry containing information about the file.userprofile.

Step by step

  • Click the "Start" button
  • In the "Find Programs and Files" window (in the senior versions of Windows, this is the "Run" window) enter the "regedit" command and then approve the operation with the "Enter" key. This operation will launch the registry system editor. This tool will allow not only to view existing records, but also to modify them, add or delete manually. Due to the fact that the Windows registry is key to its work, all operations carried out on it should be judged and consciously. Careless elimination or modification of a non-comprehensive key may irreversibly damage the operating system.
  • Using the CTR + F key, or the Editing and Options menu, find the extension it is interesting .Userprofile, scoring it in the search engine window. Approve by pressing OK or using the Enter key.
  • Spare copy. It is extremely important to create a spare copy of the registry before making any changes in it. Each change has an effect on the action of our computer. In extreme cases, the erroneous modification of the registry can lead to the impossibility of re-starting the system.
  • You are interested in the extension value, you can manually edit changing the keys assigned to the extension found .Userprofile. In this place you can also independently create the desired entry with the expansion of A.UserProfile if it is missing in the registry. All available options are located in a subwoofer (right mouse button) or in the Editing menu after the cursor is placed in the appropriate place on the screen.
  • After editing an editing of the recording concerning the extension.userprofile Close the system registry. The introduced changes will enter life after re-launching the operating system.

In Windows Server, everywhere - on the command line, scripts, etc. You can use environmental variables that give an additional degree of freedom, as they can not be attached to absolute values, replacing them with a variable system. But, as practice has shown, many users are poorly focused on Environment Variables. This table is designed to become a prompt in everyday work with the Windows Server environment variables.

List of ENVIRONMENT VARIABLES.

% Allusersprofile% \\ Documents and Settings \\ all users
% APPDATA% \\ Documents and Settings \\ (UserName) \\ Application Data
% CD% Returns the path to the current folder
% Cmdcmdline% Returns the command string by which this instance of cmd.exe was launched
% CmDextVersion% Returns the version number of current command handler extensions
% ComputerName% (ComputerName)
% ComSpec% \\ Windows \\ System32 \\ cmd.exe
% Date% Returns current data. Uses the same format as the DATE / T command. Created by the cmd.exe command
% Errorlevel% Returns the error code of the last used command. The value that is not equal to zero usually indicates an error
% Homedrive% Disk with the basic directory of the user. It is indicated in the "Local Users and Group" snap
% HomePath% \\ Documents and Settings \\ (UserName) is indicated in the "Local Users and Group" snap
% Homeshare% Network path to the common basic user directory. It is indicated in the "Local Users and Group" snap
% LogonServer% Returns the name of the domain controller, which checked the authenticity of the current session
% Number_of_Processors% Sets the number of processors installed on the computer
% OS% Returns the name of the operating system.
% Path% C: \\ Windows \\ System32 \\, C: \\ Windows \\, \u200b\u200bC: \\ Windows \\ System32 \\ WBEM
% Pathext% Returns a list of file extensions, which are considered by the operating system as executable
% Pathext% .Com, .exe, .bat, .cmd, .vbs, .vbe, .js, .wsf: .wsh (list of executable files)
% Processor_architecture% Returns the processor architecture. Values: x86, IA64
% Processor_identFier% Returns processor description
% Processor_Level% Returns the number of the processor model installed on the computer
% Processor_Revision% Returns the processor modification number
% ProgramFiles% \\ Program Files.
% Prompt% Returns command line parameters for the current interpreter cmd.exe (usually $ P $ G)
% Random% Returns an arbitrary decimal number from 0 to 32767. Created by the cmd.exe command
% SystemDrive% Returns the disk name containing the Windows root directory (i.e. system catalog)
% Systemroot% \\ Windows
% Systemroot% System Returns The Location of the Windows Root Directory.
% Temp% and% TMP% : \\ DocuME ~ 1 \\ (UserName) \\ Locals ~ 1 \\ TEMP
% Time% Returns the current time. Uses the same format as the TIME / T command. Created by the cmd.exe command
% UserDomain% Returns a domain name containing user accounts list
% Username% (UserName)
% UserProfile% \\ Documents and Settings \\ (UserName)
% UserProfile% \\ Application Data APPDATA.
% UserProfile% \\ Cookies Cookies.
% UserProfile% \\ Desktop Desktop.
% UserProfile% \\ Favorites Favorites.
% UserProfile% \\ Local Settings Local Settings
% UserProfile% \\ Local Settings \\ Application Data Local AppData.
% UserProfile% \\ Local Settings \\ History History.
% UserProfile% \\ Local Settings \\ Temporary Internet Files Cache.
% UserProfile% \\ My Documents My documents
% UserProfile% \\ My Documents \\ My Music My Music
% UserProfile% \\ My Documents \\ My Pictures My Pictures.
% UserProfile% \\ Nethood Nethood.
% UserProfile% \\ Printhood Printhood.
% UserProfile% \\ Sendto Sendto.
% UserProfile% \\ Start Menu Start Menu.
% UserProfile% \\ Start Menu \\ Programs Programs.
% UserProfile% \\ Start Menu \\ Programs \\ Startup Startup.
% UserProfile% \\ Templates Templates.
% Windir% \\ Windows

In addition, there are pseudo-destroyed in the popular File Manager Total Commander:

Name Description Example
% $ APPDATA% Application Data. C: \\ Documents and Settings \\ Main \\ Application Data
% $ Desktop% Desktop C: \\ Documents and Settings \\ Main \\ desktop
% $ Personal% My documents C: \\ Documents and Settings \\ Main \\ My Documents
% $ PROGRAMS% Main menu \\ Programs C: \\ Documents and Settings \\ Main \\ Main menu \\ Programs
% $ StartMenu% Main menu C: \\ Documents and Settings \\ Main \\ Main menu
% $ Startup% C: \\ Documents and Settings \\ Main \\ Main menu \\ Programs \\ Autoload
% $ MYPICTURES% My drawings C: \\ Documents and Settings \\ Main \\ My Documents \\ My Pictures
% $ MyMusic% My music C: \\ Documents and settings \\ Main \\ my documents \\ my music
% $ MyVideo% My video C: \\ Documents and Settings \\ Main \\ My Documents \\ My Video
% $ Local_appData% Local Settings \\ Application Data C: \\ Documents and Settings \\ Main \\ Local Settings \\ Application Data
% $ Fonts% Fonts C: \\ Windows \\ fonts

The environment variables used in batch (command) files allow you to do without specifying absolute paths to directories. For example, if the system disk letter is unknown in advance, we can always use the variable % SystemDrive%returning the letter of the disc on which the OS is installed. Also, variables are used to optimize the code - a repeated parameter (for example, a registry key) can be assigned a short variable and use it. This article discusses in detail various techniques of work with variables, as well as ways to change and create new variables. Now everything is in order.

Classification of environment variables

Summary

The Windows Shell (cmd.exe) is a very powerful system tool. Using batch files, you can automate a fair amount of tasks, and that is why they are often used to automatically install Windows. The skillful use of variables in batch files allows you to solve a wide range of questions. Working with the command shell becomes more efficient and at the same time simplifies the code of batch files. Other examples of using variables you can find on the pages of the site or forum. All examples used in this article are taken from the participants scripts, for which they thank you very much.

Terminology

Team shell - This is a separate software product that provides a direct connection between the user and the operating system. Text user interface of the command line provides an environment in which applications and utilities are executed with text interface.

cmd.exe. - Interpreter of the commands that the Windows command shell uses to translate the entered command to the format, understandable system.

Command Session can initiate as starting cmd.exe.and the launch of the batch file. In other words, the current command shell is created. Accordingly, the exit from this shell (for example, the end of the package file) terminates the command session.

User session (User session) begins from the moment of user login in the system (log on) and ends when log off (LOG OFF).

Windows variables are the emphasis on "s" in the second word (the meaning of the phrase is laid in the parental case and faithful stress: the variables of what? - Wednesdays!), In English versions of Windows - Wednesses - eNVIRONMENT VARIABLE)

Windows environment variables are used to configure operating systems. Not every user needs to be able to deal with these settings and put in these variables, but there are a couple of variables that you need to know all users of personal computers. We are talking about variables responsible for temporary storage of files - Temp. and TMP..



By default, the value of custom temporary (temp) variables - % UserProfile% \\ Local Settings \\ temp,

By default, the value of system time variables - \\ Windows \\ temp.

Therefore, in the first case, this is usually: " C: \\ Documents and Settings \\ User \\ Local Settings \\ temp"

Inexpensive productive ultrabook:

Characteristics: 14.1 inches screen 1920 * 1080 IPS, Windows 10, 8 GB RAM, 256 GB M.2 SATA 2280 SSD, WiFi, keyboard backlight.

Due to the fact that in the family of Windows operating systems, a folder with temporary files for some reason is not cleared by itself, there may be a huge variety of different unnecessary files reaching a total size of up to several gigabytes. Among the temporary files, various viruses and bad scripts are periodically hidden, therefore the duty of each PC user is to regularly delete the contents of temporary folders.

For ease of deletion, it is better to change the default path to the simpler, the most optimal option - " C: \\ temp".

How to change Windows TEMP and TMP environment variables? - Very simple:

1. Right click on the icon " My computer"On the desktop (if it is a full-fledged icon, not a shortcut) or through the menu Start -\u003e My Computer -\u003e Properties:

2. Go to the tab " Additionally"And click down on the button" Environment Variables":

3. In the upper window " Variables of the user's environment"Select first the first line (TEMP variable) and click the button" Change":



4. Correct the value of the variable on the simpler - " C: \\ temp":

5. Repeat items 3 and 4 for a variable TMP.:

As a result, it should be possible:

6. Press alternately 2 times " OK".



In principle, the same can be done using the command line by executing the command: SET TEMP \u003d C: \\ temp

All Windows environment variables:

Allusersprofile. Indicates the location of the All Users profile (local variable)
APPDATA. Specifies the location of the directory in which programs store the default data (local variable)
CD Specifies the name of the current directory (local variable)
Cmdcmdline Specifies the command line parameters that were used to start the current CMD.EXE program instance (local variable)
CmDextVersion. Specifies the version number of the current command processor extension (system variable)
ComputerName. Specifies the computer name (system variable)
ComSpec. Specifies the exact path to the command interpreter executable file (system variable)
Date. Specifies the current date. The same format is used as for the DATE / T command. The value is generated by the command interpreter (system variable)
ErrorLevel. Specifies the error code of the last program. The non-zero value is likely to indicate an error (system variable)
Homedrive. Specifies the letter of the local workstation disk connected to the home directory. The variable is determined based on the path to the home directory. The home directory of the user is determined in the snap-in local users and groups (Local Users and Groups)
Homepath Specifies the full path to the user's home directory. The variable is determined based on the path to the home directory. The home directory of the user is determined in the snap-in local users and groups (Local Users and Groups)
Homeshare. Specifies the network path to the shared user's home directory. The variable is determined based on the path to the home directory. The domestic user directory is assigned to the equippe of local users and groups (Local Users and Groups) (System variable)
LogonServer. Specifies the name of the domain controller on which the current session with the system is authorized (local variable)
Number_of_Processors. Indicates the number of processors installed in the computer (system variable)
OS Specifies the version of the operating system. Windows XP / XP is indicated as Windows_NT (system variable)
Path. Specifies the search path of executable files (system variable)
Pathext. Specifies the list of extensions that are recognized by the operating system as extensions of executable files (system variable)
Processor_architecture. Specifies the type of processor architecture. Possible values: x86 and Ia64 (system variable)
Processor_identifier Indicates processor description (system variable)
Processor_Level. Specifies the processor model number installed in the computer (system variable)
Processor_Revision. Specifies the version number of the processor model (system variable)
Prompt. Specifies the command line invitation settings for the current interpreter. Generated by interpreter cmd.exe (local variable)
Random Indicates a random decimal number from 0 to 32767. Generated by the CMD.exe program (system variable)
SystemDrive. Specifies the drive letter on which the Windows root directory is located (system variable)
Systemroot. Specifies the path to the Windows root directory (system variable)
TEMP or TMP. Indicates the path to temporary directories adopted by default. These directories are used by applications available to the user-registered user. Some applications require the value of the TEMP variable, while other - TMP (system and user variables, respectively)
Time. Specifies the current time. The same format is used as for the TIME / T command. Generated by the interpreter cmd.exe (system variable)
UserDomain. Specifies the domain name in which the user account is stored (local variable)
UserName. Specifies the username that is registered in the current time (local variable)
UserProfile Specifies the path to the profile of the current user (local variable)
Windir. Specifies the path to the operating system directory (system variable)



To access the variable value, it is necessary to put a sign% before its name and after it, for example: echo% Number_of_Processors.%