Custom Query
Results (40 - 42 of 3867)
Ticket | Owner | Reporter | Resolution | Summary |
---|---|---|---|---|
#41 | Xenobiologist | Rejected | Cleanup/Rename internal and User Defined Functions. | |
Description |
Hi, I read about some changes which may break old scripts. If you are going to make such changes think about ... Delete _ArrayCreate func (it is not necessary anymore) Rename WinMove --> WinSetPos It is kind of strange that there is _SoundPlay an SoundPlay. and so on. So long, Mega |
|||
#42 | Gary | mlowery <matin@…> | Fixed | _FileWriteFromArray outputs too many CRLF (File.au3) |
Description |
Lines output from the _FileWriteFromArray function in the standard File.au3 include are prefixed by a @CRLF, resulting in an initial blank line in the file. Repeated use of this function and its complement _FileReadToArray on the same file can result in file bloating. A suggested fix is to change the current file writing loop: Local $ErrorSav = 0 For $x = $i_Base To $i_UBound If FileWrite($hFile, @CRLF & $a_Array[$x]) = 0 Then $ErrorSav = 3 ExitLoop EndIf Next With something such as below that outputs the CRLF after the data, and does not write a final CRLF (code could undoubtedly be improved): Local $ErrorSav = 0 For $x = $i_Base To $i_UBound -1 If FileWriteLine($hFile, $a_Array[$x]) = 0 Then $ErrorSav = 3 ExitLoop EndIf Next If FileWrite($hFile, $a_Array[$i_UBound]) = 0 Then $ErrorSav = 3 As an additional suggestion, modify the function call to take the array by reference: _FileWriteFromArray($File, ByRef $a_Array, $i_Base = 0, $i_UBound = 0) Thanks! |
|||
#43 | lte5000 | Fixed | IniReadSectionNames returning incorrect number of sections (extra blank section) | |
Description |
IniReadSectionNames returns an extra blank section that does not exist in the INI file. This behavior occurs on Windows 98 SE. The function returns the correct number of sections on Windows XP SP2. Example: FileDelete("test.ini") IniWrite("test.ini", "section1", "key1", "abc") $var = IniReadSectionNames("test.ini") MsgBox(0, "how many sections", $var[0]) For $i = 1 To $var[0] MsgBox(0, "section #" & $i, $var[$i]) Next |