Advertisement
GordCaswell

PicPickCustomCodeNew

Aug 28th, 2013
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ${SegmentFile}
  2. Var PAL:CustomFirstRun
  3.  
  4. ${SegmentPrePrimary}
  5.     ReadINIStr $0 "$EXEDIR\Data\settings\PicPickPortableSettings.ini" "FirstRun" "Done"
  6.     ${If} $0 != true
  7.         ClearErrors
  8.         MessageBox MB_ICONINFORMATION|MB_OK "FOR PERSONAL(HOME) USE ONLY$\r$\n$\r$\nThis version is provided as freeware for only personal use. In this case, you are granted the right to use this program free of charge. Otherwise, you need to pay for a license for commercial use."
  9.     StrCpy $PAL:CustomFirstRunDone false
  10.     ${ElseIf} $0 == true
  11.         ReadINIStr $1 "EXEDIR\App\AppInfo\appinfo.ini" "Version" "PackageVersion"
  12.     ${AndIf} $1 != "3.2.7.0" ; NOTE: THIS VALUE MUST BE ADJUSTED EVERY TIME THE APP IS UPDATED - GC
  13.         StrCpy $PAL:CustomFirstRunDone false
  14.     ${Else}
  15.         StrCpy $PAL:CustomFirstRunDone true
  16.     ${EndIf}
  17. !macroend
  18.  
  19. ${SegmentPreExec}
  20.     StrCmp  $PAL:CustomFirstRunDone "true" +2 0
  21.         WriteINIStr "$EXEDIR\App\picpick\picpick.ini" "Setting" "FirstRun" "3270" ; NOTE: THIS VALUE MUST BE ADJUSTED EVERY TIME THE APP IS UPDATED. - GC
  22. !macroend
  23.  
  24. ${SegmentPost}
  25. StrCmp  $PAL:CustomFirstRunDone "true" +2 0
  26.         WriteINIStr "$EXEDIR\Data\settings\PicPickPortableSettings.ini" "FirstRun" "Done" "true"
  27. !macroend
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement