[Modules] ListEx (all OS / DPI)

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
loulou2522
Enthusiast
Enthusiast
Posts: 501
Joined: Tue Oct 14, 2014 12:09 pm

Re: [Modules] ListEx (all OS / DPI)

Post by loulou2522 »

Thorsten1867 wrote:Update:
  • Flag #NoButtons for CSV
@loulou2522
Please try it.
instruction
ListEx::ExportCSV(#List, "tempo2.csv", listex::#NoButtons| listex::#HeaderRow,";","")
Result:
;RUM;IBAN;ICS;MONTANT;LIBELLE;
1;012020220152331;FR76;FR5;100,00; ;
It seems thatthe element 0 (checkbox put automaticaly by the system is alway copied
"";"RUM";"IBAN";"ICS";"MONTANT";"LIBELLE";""
"0";"0012020220152331";"FR76";"FR";"100,00";" ";""
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

Update:
  • Flag #NoCheckBoxes for CSV
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
loulou2522
Enthusiast
Enthusiast
Posts: 501
Joined: Tue Oct 14, 2014 12:09 pm

Re: [Modules] ListEx (all OS / DPI)

Post by loulou2522 »

I try and all seems to be good
THansks Thorsten
ruslanx
User
User
Posts: 46
Joined: Mon Jun 06, 2011 8:28 am

Re: [Modules] ListEx (all OS / DPI)

Post by ruslanx »

Code: Select all

  Procedure   SetVScrollPosition_()
    Define.f ScrollPos
    
    If IsGadget(ListEx()\VScrollNum)
      
      ScrollPos = ListEx()\Row\Offset
      If ScrollPos > ListEx()\VScroll\MaxPos : ScrollPos = ListEx()\VScroll\MaxPos : EndIf
      
      ListEx()\VScroll\Position = ScrollPos
      
      SetGadgetState(ListEx()\VScrollNum, ScrollPos)
      
      If ListEx()\Focus : SelectElement(ListEx()\Rows(), ListEx()\Row\Focus) : EndIf
      
    EndIf
    
  EndProcedure  
If ListEx()\Focus : SelectElement(ListEx()\Rows(), ListEx()\Row\Focus) : EndIf

if is commened -> all Ok.

Got this error, after this code:

Code: Select all

    ListEx::ClearItems(#List)   ; !!!!!!!!!!!
    
    ForEach ScanList()
      ListEx::AddItem(#List, ListEx::#LastItem, #LF$ + ............ )
    Next    
    
    ListEx::Sort(#List, 4, ListEx::#Sort_Descending, ListEx::#SortTime)   ; ??????????
[ERROR] SelectElement(): SelectElement(): index value can Not be negative.


without "ListEx::ClearItems(#List)" Or "without ListEx::Sort(#List, ...)" - no error




and How to set ProgressBar Font (percent) ???? can you try ?


... and if I set 2 columns with buttons or last column is buttons .. buttons not work.
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

Updates: Bugfixes
ruslanx wrote:How to set ProgressBar Font (percent) ?

Code: Select all

ListEx::SetFont(#List, FontID(#Font_Arial9B), #False, 6)
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
loulou2522
Enthusiast
Enthusiast
Posts: 501
Joined: Tue Oct 14, 2014 12:09 pm

Re: [Modules] ListEx (all OS / DPI)

Post by loulou2522 »

Hi Thorsten1867,
I have two problem with On following intruction when the focus is on
ListEx::AddColumn(#List, ListEx::#LastItem, "MONTANT",100, "montant", ListEx::#Float|ListEx::#Editable); |ListEx::#FitColumn
1 - THe curosr disapppear
2' How can i validate an integer (ex 4000 without comma) or an float with 2 decimals ( ex 5600,03) actually if the number is withput comma i am alwway oblige to put the decimal point and 1 or Two zero afftet
Thans in advance
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

Update: Bugfixes

@loulou2522

Code: Select all

ListEx::AddColumn(#List, ListEx::#LastItem, "Integer", 85, "", ListEx::#Integer|ListEx::#Editable)

ListEx::AddColumn(#List, 6, "Float", 85, "", ListEx::#Float|ListEx::#Editable)
ListEx::SetColumnMask(#List, 6, "0.00")
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
ruslanx
User
User
Posts: 46
Joined: Mon Jun 06, 2011 8:28 am

Re: [Modules] ListEx (all OS / DPI)

Post by ruslanx »

Thorsten1867 wrote:Updates: Bugfixes
ruslanx wrote:How to set ProgressBar Font (percent) ?

Code: Select all

ListEx::SetFont(#List, FontID(#Font_Arial9B), #False, 6)
Thank you! now work, after bugfix.
ruslanx
User
User
Posts: 46
Joined: Mon Jun 06, 2011 8:28 am

Re: [Modules] ListEx (all OS / DPI)

Post by ruslanx »

Thorsten1867, is posible to change color of List ComboBox (front, back color) ? or to add your custom combobox to List gadget ?? thx.
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

Update:
  • - use ComboBoxEx if available
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
User avatar
mrv2k
User
User
Posts: 51
Joined: Fri Jan 20, 2012 3:40 pm
Location: SE England
Contact:

Re: [Modules] ListEx (all OS / DPI)

Post by mrv2k »

Hi

I'm getting a strange behavior when I add a lot of rows. I need over 40,000 rows and if I add them, as you scroll down and click rows, the wrong line is highlighted and the GetState command starts to report the wrong row number. You can reproduce it in the include file by adding...

Code: Select all

        
For I=1 To 10000
   ListEx::AddItem(#List, ListEx::#LastItem, "Harriet")
Next
loulou2522
Enthusiast
Enthusiast
Posts: 501
Joined: Tue Oct 14, 2014 12:09 pm

Focus on listex

Post by loulou2522 »

How can i put focus on 4th row of the first colum ?
Thanks
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

Update: SetState() - Set the focus on an (editable) cell when the 'Column' parameter is used.

Code: Select all

ListEx::SetState(#List, 4, 1)
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
User avatar
Thorsten1867
Addict
Addict
Posts: 1366
Joined: Wed Aug 24, 2005 4:02 pm
Location: Germany

Re: [Modules] ListEx (all OS / DPI)

Post by Thorsten1867 »

mrv2k wrote:I'm getting a strange behavior when I add a lot of rows.
Bugfixes: DPI
Translated with http://www.DeepL.com/Translator

Download of PureBasic - Modules
Download of PureBasic - Programs

[Windows 11 x64] [PB V5.7x]
loulou2522
Enthusiast
Enthusiast
Posts: 501
Joined: Tue Oct 14, 2014 12:09 pm

Re: [Modules] ListEx (all OS / DPI)

Post by loulou2522 »

Error with new version and PB 5.72
PureBasic.asm (50953)
MOV EBX 4294967296
error: value out of range
Can you see please

version
#Version = 20022401
#ModuleEx = 19112100
Post Reply