1.初始化项目。保险起见bin目录完整提交 2.基于现场代码为调整过的初始项目(此次提交还未解决代码差异问题)
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
|
||||
namespace AGVSystem.Cls
|
||||
{
|
||||
// Token: 0x02000029 RID: 41
|
||||
public class FileRW
|
||||
{
|
||||
// Token: 0x06000247 RID: 583
|
||||
[DllImport("kernel32")]
|
||||
public static extern long WritePrivateProfileString(string section, string key, string val, string filePath);
|
||||
|
||||
// Token: 0x06000248 RID: 584
|
||||
[DllImport("kernel32")]
|
||||
public static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
|
||||
|
||||
// Token: 0x06000249 RID: 585 RVA: 0x000507B0 File Offset: 0x0004E9B0
|
||||
public static string ReadIniValue(string Section, string Key, string file)
|
||||
{
|
||||
StringBuilder stringBuilder = new StringBuilder(1024);
|
||||
FileRW.GetPrivateProfileString(Section, Key, "", stringBuilder, 1024, file);
|
||||
return stringBuilder.ToString();
|
||||
}
|
||||
|
||||
// Token: 0x0600024A RID: 586 RVA: 0x000507E8 File Offset: 0x0004E9E8
|
||||
public static long WriteIniValue(string Section, string Key, string value, string file)
|
||||
{
|
||||
return FileRW.WritePrivateProfileString(Section, Key, value, file);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user