Go Back   Rhinocerus > Newsgroup > Newsgroup comp.lang.pascal.misc > Newsgroup comp.lang.pascal.delphi.misc

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 08-17-2003, 08:03 PM
m_vw
Guest
 
Posts: n/a
Default Problem with Listview columns

Hello,

When I add columns to my list view while programming they don't show
up when I run my program. But when I inculde the following code in an
formcreate procedure they do show up:

with ListView1 do
begin
Items.Clear;
Columns.Clear;
ViewStyle := vsReport;
NewColumn := Columns.Add;
NewColumn.Caption := 'Subject';
NewColumn := Columns.Add;
NewColumn.Caption := 'From';
NewColumn := Columns.Add;
NewColumn.Caption := 'Account';
Columns[0].Width:=246;
Columns[1].Width:=225;
Columns[2].Width:=80;
end;

Why isn't it working the normal way?

Maurice
--
The fact that you are a newbie does not mean you have to behave like one.

Life goes on,long after the thrill of living is gone.
from 'Jack and Diane' by J. Mellencamp

http://m-vw.cjb.net/
Follow your Euro bills: http://www.eurobilltracker.com/index.php?referer=256
Reply With Quote
Alt Today
Advertising
 
and become member of Rhinocerus
Standard Sponsored Links

  #2 (permalink)  
Old 08-18-2003, 06:12 AM
dean
Guest
 
Posts: n/a
Default Re: Problem with Listview columns

works fine with me (D6 prof)

dean

"m_vw" <mvw@nospam.com> schreef in bericht
news:4gnvjvgvvld9h2ith5n3m7c3obrsk3enhr@4ax.com...
> Hello,
>
> When I add columns to my list view while programming they don't show
> up when I run my program. But when I inculde the following code in an
> formcreate procedure they do show up:
>
> with ListView1 do
> begin
> Items.Clear;
> Columns.Clear;
> ViewStyle := vsReport;
> NewColumn := Columns.Add;
> NewColumn.Caption := 'Subject';
> NewColumn := Columns.Add;
> NewColumn.Caption := 'From';
> NewColumn := Columns.Add;
> NewColumn.Caption := 'Account';
> Columns[0].Width:=246;
> Columns[1].Width:=225;
> Columns[2].Width:=80;
> end;
>
> Why isn't it working the normal way?
>
> Maurice
> --
> The fact that you are a newbie does not mean you have to behave like one.
>
> Life goes on,long after the thrill of living is gone.
> from 'Jack and Diane' by J. Mellencamp
>
> http://m-vw.cjb.net/
> Follow your Euro bills:

http://www.eurobilltracker.com/index.php?referer=256


Reply With Quote
  #3 (permalink)  
Old 08-18-2003, 07:30 PM
Nicholas Sherlock
Guest
 
Posts: n/a
Default Re: Problem with Listview columns

m_vw wrote:
> Hello,
>
> When I add columns to my list view while programming they don't show
> up when I run my program. But when I inculde the following code in an
> formcreate procedure they do show up:


Hm.. is the viewstyle set to vsReport at designtime? There are heaps of
little options there to play with.

Cheers,
Nicholas Sherlock


Reply With Quote
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Problem with DDE reading in Excel Columns proper --? does William W. Viergever Newsgroup comp.soft-sys.sas 0 04-21-2006 05:57 PM
Re: Problem with DDE reading in Excel Columns proper --? does jakeboot@gmail.com Newsgroup comp.soft-sys.sas 0 04-21-2006 05:45 PM
Re: Problem with DDE reading in Excel Columns proper --? does data _null_; Newsgroup comp.soft-sys.sas 0 04-21-2006 05:26 PM
Re: Problem with DDE reading in Excel Columns proper --? does Terjeson, Mark Newsgroup comp.soft-sys.sas 0 04-21-2006 03:11 PM



All times are GMT. The time now is 01:37 PM.


Copyright ©2009

LinkBacks Enabled by vBSEO 3.3.0 RC2 © 2009, Crawlability, Inc.