Board index » off-topic » Resource-definition : Defining the appearance of a ListView - Possible ?

Resource-definition : Defining the appearance of a ListView - Possible ?


2006-06-28 01:04:21 AM
off-topic13
Hello All,
I've defined a Listview in the resource-file, but have allways needed to
add seperate code in the program itself to define its appearance (like
adding the columns and their captions to a Report-style list)
My question : can I define the Listview columns in the resource-file, and if
so how ?
A pointer to a website explaining how to do it would be enough, thank you.
:-)
Regards,
Rudy Wieser
 
 

Re:Resource-definition : Defining the appearance of a ListView - Possible ?

This is a definition of resource files and how they are constructed. Look
in it to see if it provides what you want.
tinyurl.com/ozjd7
or, in its long form
msdn.microsoft.com/library/en-us/tools/tools/resource_definition_statements.asp
. Ed
Quote
R.Wieser wrote in message
news: XXXX@XXXXX.COM ...

I've defined a Listview in the resource-file, but have allways
needed to add seperate code in the program itself to define
its appearance (like adding the columns and their captions
to a Report-style list)

My question : can I define the Listview columns in the
resource-file, and if so how ?

A pointer to a website explaining how to do it would be enough,
thank you. :-)
 

Re:Resource-definition : Defining the appearance of a ListView - Possible ?

Ed Mulroy < XXXX@XXXXX.COM >schreef in berichtnieuws
44a181f6$ XXXX@XXXXX.COM ...
Hello Ed,
Quote
This is a definition of resource files and how they are constructed. Look
in it to see if it provides what you want.
Looking at that site I realize I've seen it when I first tried to make sense
of Resource-files, and than did copy pretty-much everything it has to say to
HD. :-)
Alas, no reference to any of the "newer" controls is made ....
Nonwithstanding that, thanks for trying to help :-)
Regards,
Rudy Wieser
 

{smallsort}

Re:Resource-definition : Defining the appearance of a ListView - Possible ?

Hi Rudy,
[...]
Quote
My question : can I define the Listview columns in the resource-file, and
if so how ?
You cannot. Any control definitions in the resource file are only
parameters for _creating_ the controls.
As alternative, you can create a custom control based on the
List View. But anyway you will have to _write_ the code adding
the columns.
 

Re:Resource-definition : Defining the appearance of a ListView - Possible ?

Vasya Pupkin < XXXX@XXXXX.COM >schreef in berichtnieuws
XXXX@XXXXX.COM ...
Quote
Hi Rudy,
Hello Vasya,
Quote
[...]
>My question : can I define the Listview columns in the resource-file,
and
>if so how ?

You cannot. Any control definitions in the resource file are only
parameters for _creating_ the controls.
Thanks. I was just wondering. It would have made it a bit easier. :-)
Quote
As alternative, you can create a custom control based on the
List View. But anyway you will have to _write_ the code adding
the columns.
I'm afraid that I have never tried to make a custom control. I've
subclassed, in different programs, several of them, but never tried to make
such a control a permanent thing (I do not even know how I should do that
....)
Regards,
Rudy Wieser
Quote
--
Best regards
Vasya Pupkin.