#include "_Ini.au3"
Local $NewVal1 = '0000' ;指定CashRegisterCode新值
Local $NewVal2 = '88888-88888-88888-88888-88888' ;指定CDKey新值
Local $Val = _IniRead('ID.ini', 'ID', 'CashRegisterCode', '')
Local $aVal = StringRegExp($Val, '(\H+)(\h*&&.+)', 3)
If @Error Then Exit
_IniWrite('ID.ini', 'ID', 'CashRegisterCode', $NewVal1 & $aVal[1], 128)
$Val = _IniRead('ID.ini', 'ID', 'CDKey', '')
$aVal = StringRegExp($Val, '(\H+)(\h*&&.+)', 3)
If @Error Then Exit
_IniWrite('ID.ini', 'ID', 'CDKey', $NewVal2 & $aVal[1], 128)
|