Révision 4 LicensesMercure/UFManual.pas
UFManual.pas | ||
---|---|---|
194 | 194 |
FieldByName('SoftwareEnableKey').AsString := ESoftwareEnableKey.Text; |
195 | 195 |
Post; |
196 | 196 |
try |
197 |
f := TIniFile.Create(SHARED_DRIVE + SHARED_FOLDER + 'Fichiers\InraPorc.lic');
|
|
197 |
f := TIniFile.Create(TempFolder + '\InraPorc.lic');
|
|
198 | 198 |
f.WriteInteger ('License', 'LicenseType', 2); |
199 | 199 |
f.WriteInteger ('License', 'LicenseNumber', FieldByName('LicenseNumber').AsInteger) ; |
200 | 200 |
f.WriteString ('License', 'Version', FieldByName('Version').AsString); |
... | ... | |
256 | 256 |
end; |
257 | 257 |
StrMessage.Free; |
258 | 258 |
end; |
259 |
if FileExists(SHARED_DRIVE + SHARED_FOLDER + 'Fichiers\InraPorc.lic')
|
|
259 |
if FileExists(TempFolder + '\InraPorc.lic')
|
|
260 | 260 |
then |
261 | 261 |
begin |
262 | 262 |
if choix = mrYes |
263 | 263 |
then |
264 |
TIdAttachmentFile.Create(MKey.MessageParts, SHARED_DRIVE + SHARED_FOLDER + '\Fichiers\InraPorc.lic')
|
|
264 |
TIdAttachmentFile.Create(MKey.MessageParts, TempFolder + '\InraPorc.lic')
|
|
265 | 265 |
else |
266 | 266 |
begin |
267 |
MFile.Lines.LoadFromFile(SHARED_DRIVE + SHARED_FOLDER + 'Fichiers\InraPorc.lic');
|
|
267 |
MFile.Lines.LoadFromFile(TempFolder + '\InraPorc.lic');
|
|
268 | 268 |
MKey.Body.Add(''); |
269 | 269 |
MKey.Body.Add('********** InraPorc.lic **********'); |
270 | 270 |
if FieldByName('Language').AsString = 'FR' |
... | ... | |
304 | 304 |
except |
305 | 305 |
FMenu.MLog.Lines.Add('Message could not be sent !'); |
306 | 306 |
end; |
307 |
if not DeleteFile(SHARED_DRIVE + SHARED_FOLDER + 'Fichiers\InraPorc.lic')
|
|
307 |
if not DeleteFile(TempFolder + '\InraPorc.lic')
|
|
308 | 308 |
then |
309 |
FMenu.MLog.Lines.Add('File Fichiers\InraPorc.lic could not be deleted !');
|
|
309 |
FMenu.MLog.Lines.Add('File InraPorc.lic could not be deleted !'); |
|
310 | 310 |
end |
311 | 311 |
else |
312 |
FMenu.MLog.Lines.Add('File Fichiers\InraPorc.lic could not be found !');
|
|
312 |
FMenu.MLog.Lines.Add('File InraPorc.lic could not be found !'); |
|
313 | 313 |
except |
314 |
FMenu.MLog.Lines.Add('File Fichiers\InraPorc.lic could not be created !');
|
|
314 |
FMenu.MLog.Lines.Add('File InraPorc.lic could not be created !'); |
|
315 | 315 |
end; |
316 | 316 |
end; |
317 | 317 |
FMenu.MLog.Lines.Add('Logging record...'); |
... | ... | |
359 | 359 |
FieldByName('FinalDate').AsDateTime := DTPFinalDate.DateTime; |
360 | 360 |
FieldByName('SoftwareEnableKey').AsString := ESoftwareEnableKey.Text; |
361 | 361 |
Post; |
362 |
FMenu.MLog.Lines.Add('Saving to Fichiers\InraPorc.lic');
|
|
362 |
FMenu.MLog.Lines.Add('Saving to InraPorc.lic'); |
|
363 | 363 |
try |
364 | 364 |
f := TIniFile.Create(SHARED_DRIVE + SHARED_FOLDER + 'Fichiers\InraPorc.lic'); |
365 | 365 |
f.WriteInteger ('License', 'LicenseType', 2); |
... | ... | |
381 | 381 |
f.WriteString ('License', 'SoftwareEnableKey', FieldByName('SoftwareEnableKey').AsString); |
382 | 382 |
f.Free; |
383 | 383 |
except |
384 |
FMenu.MLog.Lines.Add('File Fichiers\InraPorc.lic could not be created !');
|
|
384 |
FMenu.MLog.Lines.Add('File InraPorc.lic could not be created !'); |
|
385 | 385 |
end; |
386 | 386 |
end; |
387 | 387 |
FMenu.MLog.Lines.Add('Logging record...'); |
Formats disponibles : Unified diff