Jump to content

Recommended Posts

Posted

Awesome.

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted

@LarsJ Are you planning to add this to your UDF which you relase recently.

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted

I just realize that you are doing what I asked here:

 

I hope you also work on Header improvement, as I asked for.
Is it also in your current scope/field of work ?

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted

Thank you for all the feedback. Always nice with some feedback.

mLipok, The plan is to code a UDF. Otherwise it will be too difficult and time consuming to use the controls. It'll probably become an independent UDF. If you need both colors and controls you have to include both UDFs.

Before I can code a UDF I need to know which functionality it should support and which controls should be included. The possibilities regarding controls are almost endless. You can even create your own custom control similar to the MonthCal control (create a small GUI without title bar and borders and add some controls (which could include a ListView)). I also need to know if there are any issues with the existing code. So far I have just made a few notes.

The post that you have quoted, was one of the posts I had in mind when I created the examples. This post was another. I'll add the functionality to a header control. It should be very easy.

Posted (edited)

Some suggestions: Include the option to populate the combo with unique items existing within the column - adding new items as you go. Or make it highly customizable so that such examples are easy to create - along with autocomplete.

I would be cautious with headers, because a single click is often used to interact with a column eg. for sorting. I think it best if this functionality isn't affected (although I imagine it probably won't be - it's still worth mentioning).

Edited by czardas
Posted
  On 5/16/2016 at 8:51 AM, LarsJ said:

Thank you for all the feedback. Always nice with some feedback.

Expand  

I agree this is nice to get any feedback.

  On 5/16/2016 at 8:51 AM, LarsJ said:

mLipok, The plan is to code a UDF. Otherwise it will be too difficult and time consuming to use the controls. It'll probably become an independent UDF. If you need both colors and controls you have to include both UDFs.

Expand  

Good to know.
How you want to solve the problem with registering the same message for example WM_NOTIFY  in two different UDF ?
I propose this:

 

 

  On 5/16/2016 at 8:51 AM, LarsJ said:

Before I can code a UDF I need to know which functionality it should support and which controls should be included. The possibilities regarding controls are almost endless. You can even create your own custom control similar to the MonthCal control (create a small GUI without title bar and borders and add some controls (which could include a ListView)). I also need to know if there are any issues with the existing code. So far I have just made a few notes.

Expand  

At first glance I would like to see this feature: TreeView and RadioButton, Checkboxes.
I wonder as only over whether they are really needed, I am looking for some specific needs of use.
Basically what we already showed, it is sufficient, until someone needs justify further functionality.

 


I think one will surely be needed: ListView Inside ListView.

#include <array.au3>

Local $aOuter[5][2]
Local $aInner[2][2] = [[1,2],[3,4]]


For $iOuter_idx = 0 To UBound($aOuter) -1
    $aOuter[$iOuter_idx][0] = Chr(65+ $iOuter_idx)
    $aOuter[$iOuter_idx][1] = $aInner
Next

_ArrayDisplay($aOuter,'$aOuter')
_ArrayDisplay($aInner,'$aInner')

 

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted (edited)
  On 5/16/2016 at 12:23 PM, mLipok said:

I think one will surely be needed: ListView Inside ListView.

Expand  

I'm not entirely convinced about this. A ListView is what it says it is - i.e. a control which displays lists for the end-user to interact with. If you want to have a table of lists then you have introduced a third dimension, and there are much better ways display 3D data such as line breaks within cells, or even zooming into the cube. A table of tables is less user friendly and more akin to the internal gubbins of a complex engine. How many nested ListView controls do you envisage embedding and how large is your computer screen? You can have the same functionality by simply linking cells to other tables for the user to open in a separate window or new tab.

Edited by czardas
Posted
  On 5/17/2016 at 6:27 AM, czardas said:

You can have the same functionality by simply linking cells to other tables for the user to open in a separate window or new tab.

Expand  

Good concept.
I must check it.

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted

In a UDF I think I would use the four functions SetWindowSubclass, GetWindowSubclass, RemoveWindowSubclass and DefSubclassProc (coded in WinAPIShellEx.au3) for message handling. Then it's easy for a user to add his own WM_NOTIFY message handler.

I also think I would use a function parameter to specify how the control should be opened. Then it should be possible to avoid conflicts with existing functionality.

The purpose of the examples is to edit a cell in a ListView. Coupled with this, I think the idea of ListView inside ListView is a little on the margins. Perhaps it may be the subject of a second example. My own idea with the ListView was to be able to select a value for 2 or 3 neighboring cells at once.

A ComboBox in a Header control could be very useful for filter functionality and similar. So far I have thought to use two different UDFs for the Header and the ListView.

I have added all the suggestions to my notes. Thank you.

Posted

If there is someone who wants to take up the challenge to make these examples into a real UDF, then you are more than welcome. Create your own example with the UDF version. You'll probably get a lot of likes. I'll not interfere at all. On the other hand I'll not guarantee that I'll not make my own version. Let me know if someone will take up the challenge. You can PM me if you want.

  • Moderators
Posted

LarsJ,

I do not wish to put off anyone from taking up the challenge, but there is an existing UDF for editing ListViews using edits, combos and DTPS (along with many other functionalities).

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

  Reveal hidden contents

 

Posted

Yes, I have seen. However, there is also interest in these examples. There was demand for the functionality that I have referred to in bottom of post 7. And you need a little bit of competition to keep you sharp.

Regards Lars.

  • Moderators
Posted

LarsJ,

  Quote

 And you need a little bit of competition to keep you sharp

Expand  

Always room for healthy competition - bring it on!

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

  Reveal hidden contents

 

Posted (edited)

The main purpose of the examples is to be able to edit cells in a virtual ListView with many rows. The code in first post works very well with a virtual ListView. Here is an example with 100,000 rows and 16 columns. Data stored in an array. It takes a few seconds to fill the array.

You can increase the number of rows to 1,000,000 in top of the code, but it takes longer time to fill the array. When the array is filled the rows are flying over the screen. Even on my old XP. You can edit every single cell with a ComboBox.

It works seamlessly except for a few issues with keyboard support and horizontal scrolling. They are not fully coordinated. This is just test code.

If data was stored in a database the ListView would show up immediately. Because AutoIt already supports SQLite databases and we have UDFs that supports ADO functionality and thus connection to other databases, this is the real interesting perspectives of these examples.

ListViewEditingCells.7z

Edited by LarsJ
Posted (edited)
  On 5/18/2016 at 4:14 PM, LarsJ said:

If data was stored in a database the ListView would show up immediately. Because AutoIt already supports SQLite databases and we have UDFs that supports ADO functionality and thus connection to other databases, this is the real interesting perspectives of these examples.

Expand  

Very interesting.

In VirtualKeyboard.au3 - awesome, cursor inidcation.
 

 


VirtualKeyboard.au3 Feature request: Add feature to preset which column can be edited

 


VirtualKeyboard.au3 Feature request:

Please modify this to show in   GuiWin title:

  1. if cell is going to be edited (is clicked and edit mode is in progress)
  2. if cell was edited and changed
  3. if cell was edited and not changed

Having this I will try to show example combined with ADO.au3 - I mean realtime recordset editing.

 


VirtualKeyboard.au3 Feature request:

Add button to enable / disable EDIT feature, this would be handy to be able  normally select rows after edit.

 


VirtualKeyboard.au3 - When I try to type any text on keyboard, and I'm not in cell editing mode, then listview jumps to first row. Why ?

 


Please try to attach files in ZIP, I ask about this because there is nice feature in Windows systems which gives you an easy and friendly way to use ZIP files, with out unziping files, so there is only downloading + click >> SciTE showing you the script.

 

Edited by mLipok

Signature beginning:
Please remember: "AutoIt"..... *  Wondering who uses AutoIt and what it can be used for ? * Forum Rules *
ADO.au3 UDF * POP3.au3 UDF * XML.au3 UDF * IE on Windows 11 * How to ask ChatGPT for AutoIt Codefor other useful stuff click the following button:

  Reveal hidden contents

Signature last update: 2023-04-24

Posted

The code in post 17 is only test code. But hopefully there are no errors in the code in post 1.

My plan to make cell editing work for virtual listviews is to split up the process in a few smaller steps each of which is reasonably affordable:

  1. Implement cell editing for a few small examples (more or less completed)
  2. Implement the code in the examples in a UDF that works for normal listviews
  3. Modify the code in the UDF to also work for virtual listviews
Posted (edited)

After playing around with EditControlKeyboard.au3, I discovered that dragging the first column to a different location prevents this from working correctly.

_GUICtrlListView_SetExtendedListViewStyle( $idListView, BitOr($LVS_EX_DOUBLEBUFFER, $LVS_EX_FULLROWSELECT, $LVS_EX_HEADERDRAGDROP) )

If you drag the first column back to its original location, it starts working again.

Edit: This only seems to affect column 0. I don't intend to allow my row index column to be dragged anyway, but not everyone uses a hidden row index column, so you might want to try and fix this.

Edited by czardas

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...