Custom Query

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (31 - 33 of 3810)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
Ticket Resolution Summary Owner Reporter
#3856 No Bug FileOpenDialog passing unseen information anonymous
Description

The summary is the best I could describe it and is an assumption. See link starting at post 4 https://www.autoitscript.com/forum/topic/207124-regexp-assistance-please/ for a better perspective.

Passing a file list to an array from the fileopendialog function puts something in the array that is messing with regexp functions. If I pass the same exact information from a "manually built array" of information the regexp will work with no issue.

$FileSelect = FileOpenDialog("File Rename", "F:\", "Images (*.jpg)|Videos (*.mp4)", $FD_MULTISELECT, "", $hForm)

$aDirContent_New = StringSplit($FileSelect, "|", 2)

_ArrayDisplay($aDirContent_New)

    For $i = UBound($aDirContent_New) - 1 To 0 Step - 1
        ConsoleWrite($i & " " & $aDirContent_New[$i] & @CRLF)
        If StringRegExp($aDirContent_New[$i], "^\d{4}(-\d{2}){2}_\d{6}_[PV]$") Then
            ConsoleWrite("> " & $i & @CRLF)
            _ArrayDelete($aDirContent_New, $i)
            ContinueLoop
        EndIf
        ;$aDirContent_New[$i] = $aDirContent_New[0] & "\" & $aDirContent_New[$i]
    Next
    
_ArrayDisplay($aDirContent_New)
{{{


As I said, passing an array directly, or the following code works perfectly with regexp which leads me to believe this is a bug.



{{{
#include <File.au3>
#include <WinAPISysWin.au3>
Global $GText
Local $hTimerProc = DllCallbackRegister('_TimerProc', 'none', 'hwnd;uint;uint_ptr;dword')
Global $g_iCount = 0
Local $iTimerID = _WinAPI_SetTimer(0, 0, 1000, DllCallbackGetPtr($hTimerProc))
$title = "File Rename"
$sFileSelect = FileOpenDialog($title, "F:\", "Images (*.jpg)|Videos (*.mp4)", $FD_MULTISELECT, "", 0)
$aDirContent_New = StringSplit($GText, """", 2)
_ArrayDisplay($aDirContent_New)

    For $i = UBound($aDirContent_New) - 1 To 0 Step - 1
        ConsoleWrite($i & " " & $aDirContent_New[$i] & @CRLF)
        If StringRegExp($aDirContent_New[$i], "^\d{4}(-\d{2}){2}_\d{6}_[PV]$") Or $aDirContent_New[$i] = " " Then
            ConsoleWrite("> " & $i & @CRLF)
            _ArrayDelete($aDirContent_New, $i)
            ContinueLoop
        EndIf
        ;$aDirContent_New[$i] = $aDirContent_New[0] & "\" & $aDirContent_New[$i]
    Next

_ArrayDisplay($aDirContent_New)
Func _TimerProc($hWnd, $iMsg, $iTimerID, $iTime)
$GText = ControlGetText($title, "", "Edit1")
EndFunc   ;==>_TimerProc
}}}
}}}
#3855 No Bug _ArrayToString for 1D array, for used in the Combo Box anonymous
Description

Original from Include Array.au3 Func _ArrayToString(Const ByRef $aArray, $sDelim_Col = "|", $iStart_Row = -1, $iEnd_Row = -1, $sDelim_Row = @CRLF, $iStart_Col = -1, $iEnd_Col = -1)

If using for Combo Box with 1D Array,

$Array = [1,2,3,4,5] GUICtrlSetData($Combo1, _ArrayToString($Array))

MsgBox(0,"",_ArrayToString($Array))

the String result will be

1 2 3 4 5

instead of 1|2|3|4|5

But if exchange the Delimiter the result will be ok

Func _ArrayToString(Const ByRef $aArray, $sDelim_Row = "|", $iStart_Row = -1, $iEnd_Row = -1, $sDelim_Col = @CRLF, $iStart_Col = -1, $iEnd_Col = -1)

Thank You

#3854 Wont Fix Setting Control Color has unintended consequences in GUI paul.keselman@…
Description

Uncommenting GUICtrlSetColor creates a bug where interacting with the input, also causes the button function to be executed

#include <GUIConstantsEx.au3>

$hGUI = GUICreate("Test", 200, 100)
$hButton = GUICtrlCreateButton("Button", 10, 10, 160, 24)
;GUICtrlSetColor($hButton, 0xFF0000)
$hInput = GUICtrlCreateInput("", 10, 40, 60, 24)
GUISetState()

While 1
   Switch GUIGetMsg()
          Case $hButton
                 ConsoleWrite("Button" & @CR)
          Case $hInput
                 ConsoleWrite("Input" & @CR)
          Case $GUI_EVENT_CLOSE
                 Exit
   EndSwitch
WEnd
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
Note: See TracQuery for help on using queries.