# Examples of Generator Usage

From Audacity Development Manual

## Example 1: Insert two seconds of silence at the start of the track as a "lead-in"

1. Click the the "Skip to Start" button or press Home to place the cursor at the start of the track.
2. Choose Silence from the Generate menu, accessed by: Generate > Silence.
3. Specify two seconds of silence by clicking on the final digit of the two digits that represent seconds, then overtype it with "2". The highlight then moves to the next digit.
   - If the value is showing at 30.000 seconds with "3" highlighted, type "02".
   - To change the digit that is highlighted, either click on the one you want to highlight, or move the highlighting by using the Left or Right arrow keys on your keyboard.
4. Click the OK button or press Enter on your keyboard.

## Example 2: Replace a 30 second section of audio starting at 1 minute 15 seconds with a tone

1. Click in the track at 1 minute 15 seconds (underneath "1:15" in the Timeline above the track).
   - Or for greater accuracy, enter 1 minute 15 seconds in the Selection Start box of Selection Toolbar.
2. Drag your mouse to the right to select 30 seconds of audio, then release the mouse button.
   - Or for greater accuracy, select Start and End from the cogwheel menu in Selection Toolbar, then enter 1 minute 45 seconds in that box.
   - Alternatively, select Start and Length from the cogwheel menu and enter 30 seconds.
3. Choose Tone from the Generate menu, accessed by: Generate > Tone.
   - If you used the mouse and now see in "Duration" that the selection is a little too short or long, move the highlighted digit as required using the Left or Right arrow keys on your keyboard, then type over that digit. To generate exactly 30 seconds, all the digits for samples should be zero.
4. Specify the Waveform type, Frequency and Amplitude required in the dialog box.
5. Click the OK button or press Enter on your keyboard.

Advanced: To insert or replace audio whose length must be specified in CDDA or film frames:

1. Open the context menu by clicking the triangle to right of the Duration digits
2. Choose the required Selection Format.

You can also open the context menu by hovering over or selecting in the Duration digits, then right-clicking or using a keyboard equivalent.

|< Generate Menu