How to make a standard sound. Windows Welcome Sounds. Software setting of system sounds

Often the sound scheme operating system does not suit the user with its default set. And every PC owner would like to bring individuality to the system. And it's much easier than you might think...

As I said earlier, installing your own sounds should not be difficult, and you will need to complete two steps:

1. Preparing audio files

In order to install individual sounds, prepare them, because only WAV format audio files are required for application.

You can act in several ways and: download ready-made sound schemes, convert an existing sound file other than wav and create a voice file yourself (for example, using a voice recorder or the previously discussed .

2. Change system shutdown sound

After the sounds are ready for installation, you can proceed directly to changing the system sounds.

Consider making changes to the sound scheme using the example of Windows 7, and change the sound of shutdown (shutdown):

  1. Go to the following path: Start - Control Panel
  2. Then change the display type. To do this, click on the "Categories" item in the upper right corner and change to "Small Icons"
  3. From the Control Panel list select "Sound"
  4. In the window that appears, go to the “Sounds” tab and find the list of sounds in the middle of the window
  5. Highlight the “Shutdown” sound, after which you can listen to it by clicking the “Check” button at the bottom of the list, or go to choosing your own sound file by clicking the “Browse” button

  6. After selecting, click the "Open" button to install the file
  7. Save changes to the sound scheme by clicking the "OK" button at the bottom of the window.

Instead of an afterword

That's all you need to do to change the system sounds. Rest sound notifications are changed in the same way as above.

Sound schemes are distributed in different ways, there are 3 ways to install them on Windows.

1. If you downloaded the archive of sounds and among them there is a file *.inf, then we need to right-click on it and select the item Install . The sound scheme will be installed automatically.

2. You downloaded the archive and it contains only sound files *.wav, in this case we need to copy all the sounds (you can use a folder) to the directory C:\Windows\Media. Go to Control Panel -> Sound -> Sounds tab, click on the sound we are interested in to replace, then "Browse", specify the desired sound, "Save". So it is with every sound.

After you set up all the sounds, you can save the sound scheme. To do this, click on the button Save as...", write the name and " OK."

3. If there is one file in the downloaded archive *.soundpack take it to a convenient place. Then download the program, install and run. Then click on the button " import package", specify the sound scheme file and " Open".

The scheme will be displayed in the program list, point to it, click on the " Apply package", in the window that opens, select one of the two options for applying: Apply Enhanced Package or Apply Normal Package.

Apply Enhanced Package- the use of all the sounds that are included in the scheme.
Apply Normal Package- the use of a simplified sound scheme, without the sounds of minimizing / maximizing windows, etc. (those that can annoy the user).

* When changing the theme, the sounds are applied to those that are registered in the theme (.theme), that is, each time you need to go in and apply the sound scheme yourself in the sound panel.

* The login sound does not change in the ways indicated in the instructions, you can use a special program to change it -

The operating system is a kind of virtual world in which many users are immersed for a long time. Often, daily pastime at the computer exceeds the average 8-hour working day. Microsoft has long focused on personalizing Windows, and with the advent of system versions 8, 8.1 and 10, concern for the user's individuality and the preservation of his personal data has only intensified. So, to show your individuality, to provide yourself with a pleasant environment at the computer, you can not only install wallpaper for your desktop or window decoration colors to your taste. For example, Windows 8.1 provides flexible configuration start screen"Start". You can change the color of the screen, choose background picture or the transparency effect, customize the tiles of the Metro interface in your own way. True, in this version of the system, the setting of the sound scheme is greatly reduced, in particular, there is no possibility of setting the sound at the user's choice. Windows startup. So Microsoft decided to reduce the boot time of the system, and, of course, there is a rational grain in this. But, you see, sometimes it's nice to start working with a computer, accompanied by a pleasant sound greeting - for example, a comic sound effect or your favorite ringtone.

Unlike Windows 8.1, Windows 7's predecessor system allows users to customize the startup sound of the system to their taste. How to customize your Windows 7 startup sound - we'll talk about this below.

1. How to set your Windows startup sound

Windows 7 sound schemes are configured accordingly in the sound settings of the system control panel. This section can be accessed both through the control panel and through the "Personalization" menu. The second one is easier, so we will use it. Call the context menu on the desktop.

At the bottom, click the "Sounds" tab.

A window will appear system menu"Sound". In the "Sound Scheme" drop-down tab, you can experiment with different sound effects of the preinstalled sounds of Windows 7.

But since we are interested in our system startup sound, go to the section " Program events” and choose “ Windows Login". At the bottom, click the browse button to change the preset sound to another.

The "C:\Windows\Media" folder will open, where the system stores sound scheme files in the ".wav" format.

You can transfer the desired Windows Welcome sound file in the “.wav” format to this folder in advance. But you can store sound files elsewhere on your computer and simply specify the path in Explorer. Having decided on the sound file, click "Open", we can listen to it right there with the "Check" button, then click "Apply".

That, in fact, is the whole process of replacing the preinstalled Windows 7 startup sound. As you can see, everything is quite simple, now we can start solving another question - where to get sound files of the “.wav” format. And how to make a Windows startup sound file from your favorite track yourself?

2. Where to find sounds for Windows

The easiest way to change the boring sound of Windows startup is to download collections on the Internet sound effects immediately in the ".wav" format.

Of course, there will be a greater variety of sound effects in the ".mp3" format on the Internet. You can use the huge media libraries on social networks to immediately download only the sounds you like.

But audio content social networks browser extensions and special programs, as a rule, is also downloaded in the ".mp3" format. After downloading the audio file in ".mp3", you can then convert it to the ".wav" format. Fortunately, the process is simple, and there are many free solutions on the software market - online services, programs like Free WAV MP3 Converter or Free Audio Converter from DVDVideoSoft.

3. How to Create a Windows Startup Sound by Trimming a Track

The Windows startup sound can be a small ringtone - for example, a few seconds of the intro or climax of your favorite tune. And just the way ringtones are created for mobile phones, the Windows startup sound can be created by trimming the source track where needed. Audacity will help us trim the track and save the output file in the “.wav” format. This is a free audio editor with a pretty good arsenal of options for working with audio files.

Launch Audacity and choose "Open" from the "File" menu.

We select in the explorer the source file for trimming in any audio format supported by the program. It will appear on the Timeline inside Audacity. Select the desired segment of the track, holding down the left mouse button, and press the hot keys Ctrl + X to cut it.

To select the entire remaining track, press Ctrl+A, then use the Delete key to clear the pasteboard.

Now it remains to insert the desired segment of the track, located in the clipboard. We press the keys Ctrl + V.

The track is cut, the ringtone is placed on the Audacity timeline, it remains to export it to a “.wav” file. Click the "File" menu, then "Export Audio".

We save in the ".wav" format.

The option to edit metadata can be left unchanged.

That's it - now the created ringtone can be set by the Windows 7 startup sound.

Perhaps it is not necessary to say that many Windows users I do not like standard tune, which is played at system startup. They try to change it, but the standard method of changing the sound scheme is sometimes impossible to do. Let's look at how to change the Windows 7 welcome sound. As it turns out, this is a fairly simple process, although it will take a little digging into the system.

How to change the welcome sound in Windows 7: what you need to know?

Before proceeding to change the music played at system startup, you should pay attention to the most basic condition.

It is not clear why, but the developers of Windows systems did not take care that the use of different formats was supported in sound schemes. Unfortunately, when installing user settings will have to be content with only the standard type of sound WAV files(even MP3 is not perceived, not to mention formats like OGG or FLAC).

Thus, when solving the problem of how to change the Windows 7 welcome sound, make sure that the file you intend to use is in the appropriate format. You can change it in any audio processing program or using the appropriate converter.

How to Change the Windows 7 Welcome Sound: Basic Technique

The simplest method of changing the sound is to use the list of events, which is presented on the corresponding tab.

Here you need to find an event called "Logging into Windows", and then use the browse and destination button for your file from the bottom. But sometimes such an item in the list may not be.

Then first in the standard "Explorer" we find the imageres.dll file, which is located in the System32 directory of the root directory of the system (Windows). Next, you should make sure that you are the owner of the file (in the properties menu, this parameter can be changed on the corresponding tab). You need to copy this object to any place convenient for you, then open it for editing in some resource editor (Restorator, PE Explorer) and replace the original WAV component with your own. Next, we simply save the modified file, and then copy it to its original location with a replacement (all operations must be performed exclusively with Administrator rights).

If someone finds this option too complicated, you can install some specialized utility like Startup Sound Changer. When you select your own melody, the program will change the sound of the Windows 7 greeting automatically and without any editing of the dynamic library. True, the inconvenience is that the application will constantly be loaded at system startup and work in background. But resource consumption is low.

Instead of total

As you can see, when deciding how to change the Windows 7 welcome sound, it is better to give preference to installing an additional software product. This option will also come in handy if the sound scheme does not include playback of a melody when logging into the system. If there is a corresponding item in the list, then you do not have to install additional utilities (just select the desired file).

In this article, we will learn how to change the system windows sounds. Just in case, it is recommended to do backup registry before you run our program that makes changes to the registry.

You may know that Windows allows you to set custom sounds for various events such as Windows Logon, Connection Establishment, Mail Receipt Notification, and so on. We can set up our own sounds on the victim's computer to play a trick on a colleague. There are many resources where you can find a good collection of sounds, such as http://www.reelwavs.com/ .

Setting up system sounds

If you have access to the victim's computer, you can change the system sounds in the Control Panel by opening the Sound category (Control Panel | Hardware and Sound | Sound | Change System Sounds). You can go through all the events and assign your own sounds by specifying the file paths.

Software setting of system sounds

We can programmatically change system sounds using our utility. In addition, the utility will save and restore sound settings and play sounds.

But first, we need to find out where information about system sounds files is stored. Like many other things, such information is stored in the registry. You can find this information in a specific place:

Each folder under Schemes/Apps/.Default corresponds to a specific event. For example, if you disconnected a USB device, you should have heard the system sound associated with the event Device Disconnect. A given event like DeviceDisconnect has several folders: .current, .Default, and a folder for additional sound schemes.

The system event has the following structure:

  • .current- contains an empty key with a value containing the path to the sound file used in this configuration. For DeviceDisconnect on Windows XP, the current file is "C:\WINDOWS\media\Windows XP Hardware Remove.wav".
  • .Default- Contains an empty value containing the default sound file. If you haven't changed the sound file, then this value is the same as the .current key.
  • Other folders - You may have other folders where sound schemes (user settings) are stored.

Reading and writing sound files for events

Knowing where they are stored desired settings, you can create a DataSet that will contain system events and the file path for these events. Let's run new project Windows Forms and select "Add New Item..." from the Solution Explorer window, then select the DataSet template. Add a DataColumn element sound name and sound file as below:

Reading System Event Data from the Registry

Let's declare two variables in the RegistryWrapper class to store the paths.

//these represent the location in the registry with the user sounds string hivePrefix = @"AppEvents\Schemes\Apps\.Default\"; string hiveSuffix = @"\.current";

Next, add the method GetSystemSound() which returns RegSoundDataTable A that contains the SoundName and SoundFile values. The first thing we do is get a list of all the subkeys for the path we set when calling the GetSubKeyNames method. The method will return us a list of all system sounds for events. Then, we go through each event, creating a new row for the DataTable as long as the settings for the SoundName for the current event and the SoundFile in the registry key contain the path to the file. Note that when we call the GetValue method to get the sound file, we must pass the empty string "" in the key name. We will also add helper function to connect two variables declared earlier.

Public RegSound.RegSoundDataTable GetSystemSound() ( //Get the subkey key string values ​​= Registry.CurrentUser.OpenSubKey(hivePrefix).GetSubKeyNames(); RegSound.RegSoundDataTable tb = new RegSound.RegSoundDataTable(); foreach (string s in values) ( //Loop through rows RegSound.RegSoundRow newRow = tb.NewRegSoundRow(); newRow.SoundName = s; newRow.SoundFile = (string)Registry.CurrentUser.OpenSubKey(getRegKeyPath(s)).GetValue("") ; tb.Rows .Add(newRow); ) return tb; ) //adds the full registry key including prefix and suffix private string getRegKeyPath(string s) ( return hivePrefix + s + hiveSuffix; )

Register entry

To set all sound events, we'll create another method that takes a RegSound DataTable and the sound files we're changing. We loop through each row in the DataTable and set the value of the key in the registry for the sound using the SetValue method. When calling the SetValue method, we need to know the name of the key (in our case, the empty string ""), the value of the key (the path to the sound file), and the RegistryKind that describes the type of the value (we use the type string).

Public void SetSystemSound(RegSound.RegSoundDataTable sounds, string soundPath) ( //loop through all sounds foreach (RegSound.RegSoundRow row in sounds) ( //Set key and value RegistryKey key = Registry.CurrentUser.OpenSubKey(getRegKeyPath(row.SoundName) , true); key.SetValue("", soundPath, RegistryValueKind.String); ) )

Backup current audio settings

By changing the sound schemes of the victim, we must provide for the possibility of restoring old settings. To do this, let's add the SaveSystemSound method, which uses a DataTable to save and file paths. We can use the WriteXml method on the DataTable to save the DataTable as an XML file.

Public void SaveSystemSound(RegSound.RegSoundDataTable sounds, string savePath) ( //Save Sound DataSet sounds.WriteXml(savePath); )

Restoring Saved Settings

Now let's add a method to restore the settings from the previous step. We need to know where the DataTable was stored and call the ReadXml method to read the data. We now have the ability to loop through each sound event and call the setValue method to set the new value.

Public void RestoreSystemSound(string savePath) ( //Restore Sound DataSet RegSound.RegSoundDataTable sounds = new RegSound.RegSoundDataTable(); sounds.ReadXml(savePath); foreach (RegSound.RegSoundRow row in sounds) ( //Set Key RegistryKey key = Registry .CurrentUser.OpenSubKey(getRegKeyPath(row.SoundName), true); key.SetValue("", row.SoundFile, RegistryValueKind.String); ) )

Playing a sound event

Finally, we will add the ability to play sounds. Sound files are located in the media folder of the system Windows folders, we need to quickly check if there is a backslash ("\") in the file path to see if the file contains the path and the filename itself. If not, then we append the path to the filename and play it back.

Public void PlayRegistrySound(string soundFile) ( //play sound if there is an associated file if (soundFile != "") ( SoundPlayer sp = new SoundPlayer(); //add default path if there isn"t one int a = soundFile .IndexOf("\\"); if (a != 0) ( soundFile = "%SystemRoot%\\media\\" + soundFile; ) sp.SoundLocation = soundFile; sp.Play(); ) )

Building the user interface

Creation user interface We'll start by adding controls to the form:

  • ToolStrip element for the Backup, Restore, Select, and Apply Changes buttons.
  • DataGridView that we can drag by clicking "Data > Show Data Sources," and dragging the RegSound DataGridView element.
  • Two OpenFileDialog elements, one for choosing where to restore the settings from, and the second for choosing sound files to replace.
  • The SaveFileDialog element for choosing where to save the backup copy of the current system sounds.

Loading data

So, we have almost everything ready for the application. Let's add two more variables. One for the RegistryWrapper view we described earlier and one for holding the RegSoundDataTable data. To populate the DataTable, we will call the GetRegistrySounds method, which in turn will call the GetSystemSound method we created earlier. We call the GetRegistrySounds method when the form is loaded and when the sounds are restored, or when we apply changes by populating the DataGridView with the current sound settings.

Private void frmMainMenu_Load(object sender, EventArgs e) ( GetRegistrySounds(); ) private void GetRegistrySounds() ( //Call the RegistryWrapper Class sounds = myReg.GetSystemSound(); regSoundDataGridView.DataSource = sounds; )

Customizing the DataGridView

Let's deal with the presentation of data in the DataGridView element by changing some properties, for example, setting the property AlternatingRowsDefaultCellStyle to different colors by changing the DefaultCellStyle font to Arial 10, and turning off the ability to add, edit, and delete data. We'll also add a "play" image to listen to the current associated sound. To do this, click right click click on the DataGridView and select "Edit Columns" to bring up the Edit Column dialog box. Here we will add a new column "Play," set the type to DataGridViewImageColumn, assign the property Image our music image and set the property ImageLayout to "Zoom" so that the image fills the entire cell of the column.

Let's add code to play a sound when we click on the picture. To do this, use the DataGridView CellContentClick event. The sound will play if we click on the third column (the index starts at 0, so we use #2 for the third column). To reproduce, we need to know the path to the file, which we will get by creating DataGridViewTextBoxCell for the SoundFile column and reading its value.

Private void regSoundDataGridView_CellContentClick(object sender, DataGridViewCellEventArgs e) ( //Represents col #3 the "Play" column if (e.ColumnIndex == 2) ( DataGridViewTextBoxCell cell = (DataGridViewTextBoxCell) regSoundDataGridView.Rows.Cells; //Play Sound myReg. PlayRegistrySound(cell.Value.ToString()); ) )

Conclusion

Translation: Vasily Kotov