Function ReadStringValueFBini(ByRef sGroup As String, ByRef sKey As String) As String
Функция получает значение типа String из файла настроек
sGroup - заголовок(группа)
sKey - ключ
Windows , Linux
#Include "window9.bi"
If CreateFBini("prefar.ini") <> Cast(Any Ptr, -1) Then
Dim As String ss="hello"
Dim As Byte ii=76
WriteGroupFBini("Group1")
WriteGroupFBini("Group2")
WriteValueFBini("Group1","Key",ss)
WriteValueFBini("Group2","Key",ii)
CloseFBini()
EndIf
If OpenFBini("prefar.ini",1) <> Cast(Any Ptr, -1) Then
? ReadStringValueFBini("Group1","Key")
? ReadByteValueFBini("Group2","Key")
?
dim as STRING sz = "Hello world"
WriteValueFBini("Group1","Key",sz)
WriteValueFBini("Group2","Key",Cast(Byte,90))
? ReadStringValueFBini("Group1","Key")
? ReadByteValueFBini("Group2","Key")
CloseFBini()
Sleep()
EndIf
hello
76
Hello world
90
Created with the Personal Edition of HelpNDoc: Free EPub and documentation generator