# Editor.MapEditor.Hammer.RunCommand

```csharp
static bool RunCommand(string name)
```

Run a Hammer command by name on the active map, exactly as if its key binding was pressed.
Returns false if no command has that name. See [Editor.MapEditor.Hammer.Commands](/api/Editor.MapEditor.Hammer/Commands) for what exists.

### Parameters

- `name` (`string`)

### Returns

`bool`

Declared in [Editor.MapEditor.Hammer](/api/Editor.MapEditor.Hammer).
Assembly: `Sandbox.Tools`.
