> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# openfiledialog

> Windows file picker uzerinden Windows file-open dialog acar ve secilen dosyayi file item olarak dondurur.

<div className="real-function-page">
  ```lua theme={null}
  openfiledialog(options?: DialogOptions): FileSystemItem | nil
  ```

  ## Argümanlar

  <ParamField path={"options"} type={"DialogOptions"}>
    Optional table. openfiledialog icin title, defaultPath ve extensionFilter kullanilir. extensionFilter, extension strings iceren bir table degeridir; her filter \*.\<extension> olmadan once bastaki . veya \*. kaldirilir.
  </ParamField>

  ## Dönüşler

  <ResponseField name={"file"} type={"FileSystemItem | nil"}>
    Selected file item veya dialog iptal edilirse ya da selected filesystem path donmezse nil. Dialog failures, Failed to open file dialog throw eder.
  </ResponseField>

  ## Tipler

  ### DialogOptions

  Yerel dosya veya klasör seçimi iletişim kutusunu yapılandırır.

  | Name               | Type                 | Required | Açıklama                                                                                   |
  | ------------------ | -------------------- | -------- | ------------------------------------------------------------------------------------------ |
  | `title`            | `string`             | No       | İletişim penceresi başlığını ayarlar.                                                      |
  | `defaultPath`      | `string`             | No       | İletişim kutusu açıldığında gösterilen dizini seçer.                                       |
  | `extensionFilter`  | `&#123;string&#125;` | No       | Seçilebilir dosyaları, başında nokta olsun ya da olmasın, listelenen uzantılarla sınırlar. |
  | `suggestedName`    | `string`             | No       | Kaydetme iletişim kutularında ilk dosya adını sağlar.                                      |
  | `defaultExtension` | `string`             | No       | Girilen dosya adında hiçbir uzantı olmadığında kullanılan uzantıyı ayarlar.                |

  ## Örnek

  Bir file picker acin ve selected file item veya cancellation durumunu ele alin.

  ```lua theme={null}
  local file = openfiledialog({
      title = "Choose a configuration",
      defaultPath = ".",
      extensionFilter = { "json", "txt" },
  })

  if file then
      print(file:GetName())
      print(file:IsFile())
  else
      print("No file selected")
  end
  ```
</div>
