Re: get text from listbox



It is a listbox as I can find the hwnd using the classname ListBox, plus Spy++ tells me it is a listbox.

RBS

"Dave" <nobody@xxxxxxxxxxx> wrote in message news:eZMMwzy9FHA.916@xxxxxxxxxxxxxxxxxxxxxxx
Arrrrrggggg

No wonder you are having problems, it is NOT a listbox but a LISTVIEW. a completely different animal.

None of the code you have been supplied with will work for ListViews, everybody has been helping you on the asumption that you had a listbox there. A similar call for a Listview needs to know which column you want to read from as well as the item index.

The listview control with columns and stuff is part of the Common Controls.

Start this thread again but this time use the word Listview in the title, I'm sure you will get a response that will sort your problem for you.

Best Regards
Dave O.

"RB Smissaert" <bartsmissaert@xxxxxxxxxxxxxxxx> wrote in message news:%23IjeWms9FHA.1224@xxxxxxxxxxxxxxxxxxxxxxx
Not sure that could work.
The listbox has 7 columns, 1 for an icon and 6 with strings.
The number of charaters in all these 6 strings together can come up to about 300 characters.
The garbled text is only about 5 characters.
This is an example output for all the listbox items:


?BCà
h&Ex
У?x
¤?
°Dv
@.Cà
ÿv
ø:?`
(hv
ðC`
`C
(C
ØÄrà
?@
xâv`
83E`
`gv`
XÞC
ÞC
Ov
XÐm


RBS


"mscir" <mscir@xxxxxxxxx> wrote in message news:ptudnbaRTLc-5RLeRVn-pw@xxxxxxxxxxxxxxxxx
Karl E. Peterson wrote:
Juergen Thuemmler wrote:

Karl,
I don't have anyway to test this (unless you can point me to a
commonly available unicode listbox?), but I wonder how this might
work?

as I said already, the garbled text "¸îA`" is typically for an owner drawn listbox, and I don't know any (common valid) method to get the real text.

Yeah, I hear ya there. It all seemed to get confused when the references to
a "string of question marks" came out. If it's owner-drawn, he's probably
hosed.

Is it possible to convert the garbled text in a function, comparing the English output and the garbled text, assuming someone could figure out how to write the decoding function?


Mike




.



Relevant Pages

  • Re: Treeviews
    ... (re Listview) is in the realm where you have put your ... Editor and GUI classes. ... route I went - record editing on the left and a Listbox on the right. ... Then I see one of my smart buddies in Answer Exchange using a Treeview ...
    (comp.lang.cobol)
  • Re: in listbox eine zeile grau machen
    ... Mit der ListBox ist dies nur mit Aufwand möglich, ... ListView aus den Windows Common Controls 6.0 greifen. ... With TreeView1 ... .FullRowSelect = True ...
    (microsoft.public.de.vb)
  • Re: The making of intellisense - is this the way?
    ... When user types "." ... have to search HashTable and fill the listview. ... > 1) 1 listbox. ... > Class ABC ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: MultiColumn ComboBox
    ... With ListView 6.0 you can set the FullRowselect property to True to mimic ListBox behaviour. ... If you base a combobox on a named range by setting the combobox's ...
    (microsoft.public.excel.programming)
  • Re: Modern user interface elements will be added to MFC!
    ... In SWF, a ListBox doesn't necessarily hold strings, but objects and ... comboboxes containing strings are IMO still the common case. ... with a blunt axe. ...
    (borland.public.delphi.non-technical)