Sign in to follow this  
Followers 0
Marcodl

listview subitem icon using COPYDATA message

4 posts in this topic

Hi all,

i'm working on a little monitor tool that check state of my server ( CPU load, free ram, services, etc etc ... )

is based on a single exe, that for every server launch WMI query, and insert data in a listview using subitem icons/bitmap

the tool working well, but it's too slow, cause wait that every WMI query exit before next server starting check.

Looking into the forum i found this tool using WMIQueryASync to get data and this metod working like a charm. So i modify the WMI query to match my counter and the result is wonderfull.

There's only 1 i need. Subitem icons :)

looking into the code, but don't find a way to add it with the metod used by SkinnyWhiteGuy

If a computer is online, I run the Plugin script with the name of that computer as one paramater passed into it. The other is a special value used to only run the queries we need for the columns we actually show. The plugins use ExecQueryAsync, along with GetAsync for registry values, to ask for each bit of information we need, and returns what it finds via a COPYDATA send message to our main script. To keep things running smoothly, all the main script does when it receives that message is pull the data out of the structure, store it in a queue, and then send itself a PostMessage with our special value to let the program know that, when it has time, there is new data to update the GUI with. Thanks to Uten for this method, as this keeps the script from waiting that much while the COPYDATA message is processed (which does block anything else from happening).

Hope this 2 screen explain what i need.

1. With SkinnyWithGuy script

Posted Image

2. With my script

Posted Image

i don't know if it's possible, but if someone has an idea he's welcome :)

Share this post


Link to post
Share on other sites



no one have idea or tell me if is it possible ?

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

It should be possible. Load the icons in the mainscript and give a list with the handles/indices to the child process I think.

Edited by ProgAndy

*GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

AFAIK subitem icons are not possible in a standard listview control.

Edit: As a work-around you could set the background color of the subitems.

Edited by KaFu

Share this post


Link to post
Share on other sites

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
Sign in to follow this  
Followers 0