Armand Posted May 2, 2008 Author Posted May 2, 2008 @MsCreatoR That didn't work, it doesn't matter much i think as i use the "_GUICtrlListView_SetItemText()" to actually set the text... @GaryFrost Done already, no effect... or maybe it does but not 100% working... It works 100% fine showing all languages when i use built-in function [GUICtrlCreateListViewItem()] but then it shows the table like a freakin' disco FLICKER that thing could blind ya' !!! [u]My Au3 Scripts:[/u]____________(E)Lephant, A Share download manager (RS/MU etc)Http1.1 Console, The Ez Way!Internet Reconnection Automation Suite & A Macro Recording Tool.SK's Alarm Clock, Playing '.MP3 & .Wav' Files._________________Is GOD a mistake of the Humanity Or the Humanity is a mistake of GOD ?!
Armand Posted May 2, 2008 Author Posted May 2, 2008 no idea anyone else maybe ?! [u]My Au3 Scripts:[/u]____________(E)Lephant, A Share download manager (RS/MU etc)Http1.1 Console, The Ez Way!Internet Reconnection Automation Suite & A Macro Recording Tool.SK's Alarm Clock, Playing '.MP3 & .Wav' Files._________________Is GOD a mistake of the Humanity Or the Humanity is a mistake of GOD ?!
MrCreatoR Posted May 2, 2008 Posted May 2, 2008 @Armand: What you mean by... It works 100% fine showing all languages when i use built-in function [GUICtrlCreateListViewItem()] but then it shows the table like a freakin' disco FLICKER that thing could blind ya' !!! ? what exactly wrong with the built-in functions? Spoiler Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1 AutoIt Russian Community My Work... Spoiler Projects: ATT - Application Translate Tool {new}| BlockIt - Block files & folders {new}| SIP - Selected Image Preview {new}| SISCABMAN - SciTE Abbreviations Manager {new}| AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize ProgramUDFs: OnAutoItErrorRegister - Handle AutoIt critical errors {new}| AutoIt Syntax Highlight {new}| Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDF Examples: ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation Demo Like the Projects/UDFs/Examples? Please rate the topic (up-right corner of the post header: Rating ) * === My topics === * ================================================== ================================================== AutoIt is simple, subtle, elegant. © AutoIt Team
Armand Posted May 2, 2008 Author Posted May 2, 2008 Well.. issue solved by using a UDF someone else provided in there:http://www.autoitscript.com/forum/index.php?showtopic=70227Bah i'm hoping i won't have to ""Revive"" it again in the future [in case some other 'same' issues that i haven't sought will pop...]@MsCreatoR-> it looks like it refreshes after every item\subitem it puts to the list... so it's like someone turns on\off the light on the control real fast, like a disco flicker.... [u]My Au3 Scripts:[/u]____________(E)Lephant, A Share download manager (RS/MU etc)Http1.1 Console, The Ez Way!Internet Reconnection Automation Suite & A Macro Recording Tool.SK's Alarm Clock, Playing '.MP3 & .Wav' Files._________________Is GOD a mistake of the Humanity Or the Humanity is a mistake of GOD ?!
Armand Posted May 5, 2008 Author Posted May 5, 2008 Here is a reproduction of the issue and FIXES! P.S, other issue has come across this reproduction... >> Notice how the first 2 are deleting a TAB-ITEM after two consecutive clicks due to the use of control ID instead of handle... expandcollapse popup#include <GuiConstantsEx.au3> #include <GuiListView.au3> #include <GuiImageList.au3> #include <WindowsConstants.au3> Opt("GUIOnEventMode", 1) ;$Debug_LV = False ; Check ClassName being passed to ListView functions, set to True and use a handle to another control to see it work Global $hListView, $GUI, $hImage Dim $SearchTableREF[16] = [15, 25, 380, 160, 78, 78, 130, 65, 80, 140, 70, 100, 100, 70, 100, 200] $GUI = GUICreate("(UDF Created) ListView Create", 500, 400) GUISetOnEvent($GUI_EVENT_CLOSE, "ExitProg") $TAB = GUICtrlCreateTab(0, 0, 498, 398) $Tab0 = GUICtrlCreateTabItem("ItemNumber0") $Tab1 = GUICtrlCreateTabItem("ItemNumber1") $hListView = GUICtrlCreateListView("#|A|B|C|D|E|F|G|H|I|J|K|L|M", 2, 22, 450, 330, -1, BitOR($LVS_EX_GRIDLINES, $LVS_EX_HEADERDRAGDROP, $LVS_EX_FULLROWSELECT, 0x00010000, $LVS_EX_SUBITEMIMAGES)) $Handle = GUICtrlGetHandle($hListView) ;~ >>> You can still dance to the lights of that listview without these !!! ;~ _GUICtrlListView_SetColumnWidth($hListView, 0, Number($SearchTableREF[1])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 1, Number($SearchTableREF[2])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 2, Number($SearchTableREF[3])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 3, Number($SearchTableREF[4])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 4, Number($SearchTableREF[5])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 5, Number($SearchTableREF[7])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 6, Number($SearchTableREF[8])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 7, Number($SearchTableREF[6])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 8, Number($SearchTableREF[9])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 9, Number($SearchTableREF[10])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 10, Number($SearchTableREF[11])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 11, Number($SearchTableREF[12])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 12, Number($SearchTableREF[13])) ;~ _GUICtrlListView_SetColumnWidth($hListView, 13, Number($SearchTableREF[14])) ;~ Dim $B_DESCENDING[_GUICtrlListView_GetColumnCount($hListView)] ;~ _GUICtrlListView_SetUnicodeFormat($hListView, True) $Button = GUICtrlCreateButton("DanceClub Refresh", 0, 360, 120, 20) GUICtrlSetOnEvent(-1, "DanceClubPartyLightsTurnOn") $Button2 = GUICtrlCreateButton("Normal Refresh", 150, 360, 120, 20) GUICtrlSetOnEvent(-1, "NormalRefresh") $Button2 = GUICtrlCreateButton("FIXED Refresh", 300, 360, 100, 20) GUICtrlSetOnEvent(-1, "WORKINGFIXFORTHEISSUE") $Tab2 = GUICtrlCreateTabItem("ItemNumber2") GUICtrlCreateTabItem("") GUISetState() ; Loop until user exits While 1 WEnd Func DanceClubPartyLightsTurnOn() _GUICtrlListView_DeleteAllItems($hListView) ; Load items For $i = 0 To 100 GUICtrlCreateListViewItem($i & "|http://www.autoitscript.com/forum/index.php?showtopic=70502|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDASD|" _ & "ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd", $hListView) Next EndFunc ;==>DanceClubPartyLightsTurnOn Func WORKINGFIXFORTHEISSUE() GUISetState(@SW_LOCK) _GUICtrlListView_DeleteAllItems($Handle) ; Load items For $i = 0 To 100 GUICtrlCreateListViewItem($i & "|http://www.autoitscript.com/forum/index.php?showtopic=70502|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDASD|" _ & "ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd", $hListView) Next GUISetState(@SW_UNLOCK) EndFunc ;==>DanceClubPartyLightsTurnOn Func NormalRefresh() _GUICtrlListView_DeleteAllItems($hListView) ; Load items For $i = 0 To 100 MyGUICtrlCreateListViewItem($i & "|http://www.autoitscript.com/forum/index.php?showtopic=70502|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDAasdasddddasdasdasdasdasd|ASDASD|ASDASD|" _ & "ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd|ASDAasdasddddasdasdasdasdasd", $hListView) Next ;;; USING THIS FUNCTION >> ;;; because of _UDF lack of ability to support unicode properly. ;;; because of built-in flickering property, [it just flashes like a milion times during the updates]. EndFunc ;==>NormalRefresh Func ExitProg() Exit EndFunc ;==>ExitProg ; #FUNCTION# ==================================================================================================================== ; Name...........: MyGUICtrlCreateListViewItem ; Description ...: Create and insert items directly into the listview, Unicode supported! ; Syntax.........: MyGUICtrlCreateListViewItem($sText, $nCtrlID[, $nIndex = -1]) ; Parameters ....: $sText - Text of the item and subitems seperated by seperation char. [Default "|"] ; $nCtrlID - Listview control ID. ; $nIndex - Item's index. [Default -1, will add at last location] ; Return values .: Nothing. ; Author ........: Unknown, Supplied by: ChrisL @ http://www.autoitscript.com/forum/index.php?showtopic=70227&view=findpost&p=515453 ; Modified.......: Armand. ; =============================================================================================================================== Func MyGUICtrlCreateListViewItem($sText, $nCtrlID, $nIndex = -1) Local $stLvItem = DllStructCreate("uint;int;int;uint;uint;ptr;int;int;int;int;") Local $stText = DllStructCreate("wchar[260]") Local $arText = StringSplit($sText, "|") If $nIndex = -1 Then $nIndex = GUICtrlSendMsg($nCtrlID, $LVM_GETITEMCOUNT, 0, 0) DllStructSetData($stText, 1, $arText[1]); Save the item text in the struct DllStructSetData($stLvItem, 1, BitOR($LVIF_TEXT, $LVIF_PARAM)) DllStructSetData($stLvItem, 2, $nIndex) DllStructSetData($stLvItem, 6, DllStructGetPtr($stText)) ; Set the lParam of the struct to the line index - unique within the listview DllStructSetData($stLvItem, 9, $nIndex) $nIndex = GUICtrlSendMsg($nCtrlID, $LVM_INSERTITEMW, 0, DllStructGetPtr($stLvItem)) If $nIndex > -1 Then ; Insert now the rest of the column text For $i = 2 To $arText[0] DllStructSetData($stText, 1, $arText[$i]) DllStructSetData($stLvItem, 3, $i - 1); Store the subitem index GUICtrlSendMsg($nCtrlID, $LVM_SETITEMTEXTW, $nIndex, DllStructGetPtr($stLvItem)) Next EndIf $stText = 0 $stLvItem = 0 EndFunc ;==>MyGUICtrlCreateListViewItem [u]My Au3 Scripts:[/u]____________(E)Lephant, A Share download manager (RS/MU etc)Http1.1 Console, The Ez Way!Internet Reconnection Automation Suite & A Macro Recording Tool.SK's Alarm Clock, Playing '.MP3 & .Wav' Files._________________Is GOD a mistake of the Humanity Or the Humanity is a mistake of GOD ?!
GaryFrost Posted May 5, 2008 Posted May 5, 2008 (edited) This should resolve your issues, this is what I just committed to the next beta: "attachment removed" BTW your bug report is a NO BUG. Edited May 8, 2008 by GaryFrost SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now