⚙️Yapılandırma Dosyası

AutoHotkey (AHK) ile temel yapılandırma dosyası işlemleri ve yapılandırma dosyası yönetimi

✍ Dosyaya Yazma

  • 💠 IniWrite metodu ile yapılır

IniWrite, this is a new value, %A_ScriptDir%\temp.ini, section2, key1
IniWrite, this is a next value, %A_ScriptDir%\temp.ini, section2, key2
[section2]
key1=this is a newvalue
key2=this is a next value

‍🧙‍♂ Detaylar için IniWrite alanına bakmanda fayda var

👁️ Dosyadan Okuma

💠 Kod📝 Açıklama

IniRead, OutputVar, Filename, Section, Key, Default

key değerini okuma yoksa Default değerini alma

IniRead, OutputVar, Filename, Section, Key

key okuma

IniRead, OutputVarSection, Filename, Section

sectiondeğerlerini okuma

IniRead, OutputVarSectionNames, Filename

Tüm dosyadaki section verilerini okuma

IniRead, OutputVar, %A_ScriptDir%\temp.ini, section2, key2
if (OutputVar != "ERROR") {
    MsgBox, The value is %OutputVar%.
}

‍🧙‍♂ Detaylar için IniRead alanına bakmanda fayda var

🔗 Faydalı Kaynaklar

Last updated

© 2024 ~ Yunus Emre Ak ~ yEmreAk