Archive: I think I found a bug under Windows 9x only


I think I found a bug under Windows 9x only
Hello,

Today, I was testd UltraModernUI under Windows 98:

There is a problem, concerning several of my InstallOption pages:
On these pages, I modify file INI manually in order to fill there of the text in a "Text" or a Folders list in a "TreeView" Controls, (I cannot do it with the WriteIniStr function because of the limitation of 1024 characters of the variables).
The problem is that if I use the WriteIniStr function before my functions FileOpen, FileWrite and FileClose, Just after FileClose, my modifications were canceled... as if I had not done anything. (Before FileClose, I noted that the text was correctly written in the file) and thus, finally, not of text nor of folder list appear in the these pages.

I think it is a problem with the WriteIniStr function, that don't close correctly the INI file under win9x.

Example of code:

Function "${PRE}"

; This macro use the WriteIniStr function to set the RTL mod
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "${UMUI_INFORMATIONPAGE_INI}" "Information.ini"
; If y replace this !insertmacro by these two lines (no WriteIniStr function used) this code work
;SetOutPath "$PLUGINSDIR"
;File "/oname=$PLUGINSDIR\Information.ini" "${UMUI_INFORMATIONPAGE_INI}"


FileOpen $MUI_TEMP2 "$PLUGINSDIR\Information.ini" a
IfErrors 0 +2
Abort
FileSeek $MUI_TEMP2 -2 END ; seek to end

FileWrite $MUI_TEMP2 .............

MessageBox MB_OK "Here, the text is correctly Written in the file"

FileClose $MUI_TEMP2

MessageBox MB_OK "Here, the text disappeared under win9x"


!insertmacro MUI_INSTALLOPTIONS_WRITE "Information.ini" "Field 1" Text "${UMUI_INFORMATIONPAGE_TEXT}"

!insertmacro MUI_PAGE_FUNCTION_CUSTOM SHOW

!insertmacro MUI_INSTALLOPTIONS_DISPLAY "Information.ini"

FunctionEnd

Have you tried FlushINI?


I did not know this Instruction Thanks