# DTextEntry:OnGetFocus

- **Ortam:** İstemci, Menü
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/DTextEntry:OnGetFocus
- **Çeviri tarihi:** 2025-09-08

```lua
DTextEntry:OnGetFocus()
```

## Açıklama

[DTextEntry](https://gmod.tr/wiki/DTextEntry) odak kazandığında çağrılır.

### Örnek

```lua
local dTextEntry = vgui.Create("DTextEntry")
dTextEntry:SetText("Metni buraya girin")

-- Metin alanına tıklandığında temizlenmesini sağlar.
dTextEntry.OnGetFocus = function(self)
    self:SetValue("")
end
```

**Çıktı:** Kullanıcı yazmaya başlamak için tıkladığında metin girişi temizlenir

- [GMod Wiki ana sayfası](https://gmod.tr/wiki)

---

[Tüm sunucular](https://gmod.tr/) · [GmodTR Launcher](https://gmod.tr/launcher) · [Rehber](https://gmod.tr/rehber) · [GMod Wiki](https://gmod.tr/wiki) · [GmodTR nedir?](https://gmod.tr/hakkinda) · [Sunucu ekle](https://gmod.tr/sunucu-ekle) · [Discord](https://discord.gg/gmodtr)

Kaynak: https://gmod.tr/wiki/DTextEntry:OnGetFocus
