请高手做一道VB编程题
来源:百度知道 编辑:UC知道 时间:2024/09/23 01:22:48
Private Declare Function WritePrivateProfileString Lib "kernel32" Alias "WritePrivateProfileStringA" (ByVal lpApplicationName As String, ByVal lpKeyName As Any, ByVal lpString As Any, ByVal lpFileName As String) As Long '保存
Private Sub Command1_Click() '保存
Dim success As Long
success = WritePrivateProfileString("组名", "地方", Text1.Text, "c:\aa.ini")
End Sub
'=======================================
Private Declare Function GetPrivateProfileString Lib "kernel32" Alias "GetPrivateProfileStringA" (ByVal lpApplicationName As String, ByVal lpKeyName As Any, ByVal lpDefault As String, ByVal lpReturnedString As String, ByVal nSize As Long, ByVal lpFileName As String) As Long '读
Private Sub Form_load()'读
Dim ret As Long
Dim buff As String
buff = String(255, 0)
ret = GetPrivateProfileString("组名", "地方", "",