Jump to content

ControlListView Problem


Nezoic
 Share

Recommended Posts

Alright so I'm writing a script that basically reads what song is currently playing in Windows Media Player. My problem is that using the following.

ControlListView("Windows Media Player", "", "ATL:SysListView322", "GetSelected")

Only tells you what is selected, where as the currently playing song is Highlighted and not necessarily considered selected. Is there a way to impliment something like "GetHighlighted" instead?

Link to comment
Share on other sites

  • 2 months later...

I kinda gave up on this a while ago, but ran across something else similar to this problem so figured I'd bump this again if anyone has any ideas on how to determine if an item is 'Highlighted' and not 'Selected' in a listview.

Link to comment
Share on other sites

I kinda gave up on this a while ago, but ran across something else similar to this problem so figured I'd bump this again if anyone has any ideas on how to determine if an item is 'Highlighted' and not 'Selected' in a listview.

After some further research I think I sorta figured my problem, basically the "highlighted" item in the list view is just a different colored background text and not a different control state.

Now the question is, can AutoiIT read the text color or background color of an item in a listview? if it can then I should be able to just read all of the items and tell which has a different background essentialy that would be the song currently playing.

Edited by Nezoic
Link to comment
Share on other sites

  • 3 months later...

Did you get the ControlListView resolved. I have done GUI programming before with VisualTest and SilkTest and did not have any problems. However, the license is rather expensive so when I found AutoIt, I got very excited. I cannot give the code since I am doing this for my client. However, I did this from an ATI Media dialog to select a item in the listbox.

ControlListView ( "ATI Multimedia Center Configuration", "", "ListBox1", "Select",1 ) after I set the window active. No matter what I do, I cannot use this ControlListView which I would like very much to. The following

MouseMove(40,112)

MouseDown("left")

MouseUp("left")

Sleep(1000)

works well but not guaranteed long term solution. Any resolution and comments. My development is picking up fast but spending too much time on ControlListView function. Thanks.

Dr SherlockAlways a way

Link to comment
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
 Share

  • Recently Browsing   0 members

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