473,509 Members | 2,918 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ColumnHeaderCollection

I have a function Called HeaderCol() that builds up and
returns a Column Header Collection.

How do I assign this to my listview in my calling
function ?

Thanks
Nov 20 '05 #1
8 1740
"AnonMan" <an*******@discussions.microsoft.com> schrieb
I have a function Called HeaderCol() that builds up and
returns a Column Header Collection.

How do I assign this to my listview in my calling
function ?


You don't have to assign it because you have to pass the Listview to the
constructor of the ColumnHeaderCollection.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #2
"AnonMan" <an*******@discussions.microsoft.com> schrieb
I have a function Called HeaderCol() that builds up and
returns a Column Header Collection.

How do I assign this to my listview in my calling
function ?


You don't have to assign it because you have to pass the Listview to the
constructor of the ColumnHeaderCollection.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #3
"Armin Zingler" <az*******@freenet.de> schrieb
"AnonMan" <an*******@discussions.microsoft.com> schrieb
I have a function Called HeaderCol() that builds up and
returns a Column Header Collection.

How do I assign this to my listview in my calling
function ?


You don't have to assign it because you have to pass the Listview to
the constructor of the ColumnHeaderCollection.


....which means that the ColumnHeaderCollection is automatically assigned to
the Listview.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #4
"Armin Zingler" <az*******@freenet.de> schrieb
"AnonMan" <an*******@discussions.microsoft.com> schrieb
I have a function Called HeaderCol() that builds up and
returns a Column Header Collection.

How do I assign this to my listview in my calling
function ?


You don't have to assign it because you have to pass the Listview to
the constructor of the ColumnHeaderCollection.


....which means that the ColumnHeaderCollection is automatically assigned to
the Listview.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #5
Thanks,

Supposing I have an array of column headers I want to
assign to the listview:

I currently use

for icount = 0 to ubound(myarray)
ListView1.Columns.Add(myarray
(iCount).ToString, 100, HorizontalAlignment.Left)
next icount

I was curious if I could have a function that builds up
any set of columns and return/assign them to any
new listview I create in the form of a column collection.

-----Original Message-----
"Armin Zingler" <az*******@freenet.de> schrieb
"AnonMan" <an*******@discussions.microsoft.com> schrieb
> I have a function Called HeaderCol() that builds up and > returns a Column Header Collection.
>
> How do I assign this to my listview in my calling
> function ?
You don't have to assign it because you have to pass the Listview to the constructor of the ColumnHeaderCollection.


....which means that the ColumnHeaderCollection is

automatically assigned tothe Listview.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

.

Nov 20 '05 #6
Thanks,

Supposing I have an array of column headers I want to
assign to the listview:

I currently use

for icount = 0 to ubound(myarray)
ListView1.Columns.Add(myarray
(iCount).ToString, 100, HorizontalAlignment.Left)
next icount

I was curious if I could have a function that builds up
any set of columns and return/assign them to any
new listview I create in the form of a column collection.

-----Original Message-----
"Armin Zingler" <az*******@freenet.de> schrieb
"AnonMan" <an*******@discussions.microsoft.com> schrieb
> I have a function Called HeaderCol() that builds up and > returns a Column Header Collection.
>
> How do I assign this to my listview in my calling
> function ?
You don't have to assign it because you have to pass the Listview to the constructor of the ColumnHeaderCollection.


....which means that the ColumnHeaderCollection is

automatically assigned tothe Listview.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

.

Nov 20 '05 #7
"AnonMan" <an*******@discussions.microsoft.com> schrieb
Thanks,

Supposing I have an array of column headers I want to
assign to the listview:

I currently use

for icount = 0 to ubound(myarray)
ListView1.Columns.Add(myarray
(iCount).ToString, 100, HorizontalAlignment.Left)
next icount

I was curious if I could have a function that builds up
any set of columns and return/assign them to any
new listview I create in the form of a column collection.

Pass the listview to the function as an argument. In the function, pass the
listview to the constructor of the ColumnHeaderCollection.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #8
"AnonMan" <an*******@discussions.microsoft.com> schrieb
Thanks,

Supposing I have an array of column headers I want to
assign to the listview:

I currently use

for icount = 0 to ubound(myarray)
ListView1.Columns.Add(myarray
(iCount).ToString, 100, HorizontalAlignment.Left)
next icount

I was curious if I could have a function that builds up
any set of columns and return/assign them to any
new listview I create in the form of a column collection.

Pass the listview to the function as an argument. In the function, pass the
listview to the constructor of the ColumnHeaderCollection.
--
Armin

http://www.plig.net/nnq/nquote.html
http://www.netmeister.org/news/learn2quote.html

Nov 20 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3944
by: Buddy | last post by:
Hello, Does anyone know how I can tell the ListView NOT to display the three dots when it thinks the text will not fit in the column. E.g. 'Hello World' will be displayed as 'Hello...' if the...
2
2275
by: Sagaert Johan | last post by:
Hi I have set the columreorder to true Is there a way to get/set the current columnorder, so i can restore the order from a saved setting ? Johan
1
1970
by: Stefan Urech | last post by:
Hi, i'm building a own ListView-Control. For that, i wrote a new ColumnHeader-Collection, which implements IList. So far, so good. In the Designer of VS.Net, i see the collection as a Property...
7
12487
by: Martin Schulze | last post by:
Hello, i tried to compose myself a custom usercontrol which is derieved from System.Windows.Forms.UserControl. It contains 2 comboboxes and one textbox (which are also custom controls, but...
0
292
by: AnonMan | last post by:
I have a function Called HeaderCol() that builds up and returns a Column Header Collection. How do I assign this to my listview in my calling function ? Thanks
7
3538
by: Laurent Navarro | last post by:
Hello, I'm creating a control including a listview. I would like to be able to set the columns through the Design Tool in Visual Studio, so I created a parameter to access the columns of my...
1
2980
by: bonk | last post by:
I have a very simple UserControl (derived from System.Windows.Forms.UserControl) that contains several ListViews. The UserControl exposes a single public property: public...
1
1699
by: Johnny J. | last post by:
I've made an inherited ListView control with a customized ColumnHeader Type. I've overwritten the Columns property with a collection of my custom ColumnHeader items. Now I would like to implement...
0
1276
by: Johnny J. | last post by:
I posted this last week, but didn't get any reply. I'm trying again now, because I'm getting desperate - I've tried everything I can think of myself. PLEASE help somebody. I've made an inherited...
0
7234
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7344
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7412
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7069
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7505
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5652
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5060
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4730
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3216
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.