1. still gotta problem with listview

This time the listviews are on a TabItem. Made a silly mistake last 
time.  Still produces the same error. Works ok except on closing.

Is this a bug:
in my code?
in Win32lib?  (version 0.59.1  8/June/2003)
in Windows NT4?

-------------
include win32lib.ew

constant Win =
create( Window, "Listview on TabControl Problem",0,1,1,550,500,0),
 tc = create(TabControl,"",Win,20,40,500,500,0 ),
 tab1 = create(TabItem,"tab 1",tc, 0, 0, 0, 0, 0 ),
 lv1 = create( ListView,{"column 1","column 2","column 
3"},tab1,5,30,450,300,
    or_all({LVS_REPORT,LVS_SHOWSELALWAYS})),
 tab2 = create(TabItem,"tab 2",tc, 0, 0, 0, 0, 0 ),
 lv2 = create( ListView,{"column 1","column 2","column 
3"},tab2,5,30,450,300,
    or_all({LVS_REPORT,LVS_SHOWSELALWAYS}))

object index

index = addLVItem( lv1, 0, {"apple juice","orange juice","grapefruit 
juice"})
index = addLVItem( lv2, 0, {"apples","oranges","grapefruits"})

WinMain(Win,Normal)
-----------

Jerry Story

new topic     » topic index » view message » categorize

2. Re: still gotta problem with listview

Jerry, FYI, it ran and closed okay for me on Win2000...

> This time the listviews are on a TabItem. Made a silly mistake last 
> time.  Still produces the same error. Works ok except on closing.
> 
> Is this a bug:
> in my code?
> in Win32lib?  (version 0.59.1  8/June/2003)
> in Windows NT4?
> 
> -------------
> include win32lib.ew
> 
> constant Win =
> create( Window, "Listview on TabControl Problem",0,1,1,550,500,0),
>  tc = create(TabControl,"",Win,20,40,500,500,0 ),
>  tab1 = create(TabItem,"tab 1",tc, 0, 0, 0, 0, 0 ),
>  lv1 = create( ListView,{"column 1","column 2","column 
> 3"},tab1,5,30,450,300,
>     or_all({LVS_REPORT,LVS_SHOWSELALWAYS})),
>  tab2 = create(TabItem,"tab 2",tc, 0, 0, 0, 0, 0 ),
>  lv2 = create( ListView,{"column 1","column 2","column 
> 3"},tab2,5,30,450,300,
>     or_all({LVS_REPORT,LVS_SHOWSELALWAYS}))
> 
> object index
> 
> index = addLVItem( lv1, 0, {"apple juice","orange juice","grapefruit 
> juice"})
> index = addLVItem( lv2, 0, {"apples","oranges","grapefruits"})
> 
> WinMain(Win,Normal)
> -----------
> 
> Jerry Story
> 
> 
> 
> TOPICA - Start your own email discussion group. FREE!
> 
>

new topic     » goto parent     » topic index » view message » categorize

3. Re: still gotta problem with listview

----- Original Message ----- 
From: "Jerry Story" <jstory at edmc.net>
To: "EUforum" <EUforum at topica.com>
Subject: still gotta problem with listview


> 
> 
> This time the listviews are on a TabItem. Made a silly mistake last 
> time.  Still produces the same error. Works ok except on closing.
> 
> Is this a bug:
> in my code?
> in Win32lib?  (version 0.59.1  8/June/2003)
> in Windows NT4?
> 
> -------------
> include win32lib.ew
> 
> constant Win =
> create( Window, "Listview on TabControl Problem",0,1,1,550,500,0),
>  tc = create(TabControl,"",Win,20,40,500,500,0 ),
>  tab1 = create(TabItem,"tab 1",tc, 0, 0, 0, 0, 0 ),
>  lv1 = create( ListView,{"column 1","column 2","column 
> 3"},tab1,5,30,450,300,
>     or_all({LVS_REPORT,LVS_SHOWSELALWAYS})),
>  tab2 = create(TabItem,"tab 2",tc, 0, 0, 0, 0, 0 ),
>  lv2 = create( ListView,{"column 1","column 2","column 
> 3"},tab2,5,30,450,300,
>     or_all({LVS_REPORT,LVS_SHOWSELALWAYS}))
> 
> object index
> 
> index = addLVItem( lv1, 0, {"apple juice","orange juice","grapefruit 
> juice"})
> index = addLVItem( lv2, 0, {"apples","oranges","grapefruits"})
> 
> WinMain(Win,Normal)

This works correctly on Windows ME and Windows 2K. 

-- 
Derek

new topic     » goto parent     » topic index » view message » categorize

4. Re: still gotta problem with listview

Jerry,
I tried to send this to you directly, but the 2 email addresses I have =
for you are not responding.

I've found something in win32lib that might be the cause of the problem =
you were having. I'm not sure as I can't recreate it here. However, if =
you'd like to see if this does anything good, in the Win32lib routine =
destroy() find the code ....

  if id !=3D mainWindow then
        lChildren =3D findChildren(id)
        for i =3D length(lChildren) to 1 by -1 do
            destroy(lChildren[i][1])
        end for
  end if

and remove the 'if' processing by changing it to ...

    lChildren =3D findChildren(id)
    for i =3D length(lChildren) to 1 by -1 do
        destroy(lChildren[i][1])
    end for

then run the program you had problems with.

Let me know if it nakes a difference.

--=20
Derek

----- Original Message -----=20
From: "Jerry Story" <jstory at edmc.net>
To: "EUforum" <EUforum at topica.com>
Sent: Saturday, July 19, 2003 3:34 PM
Subject: RE: still gotta problem with listview


>=20
>=20
>=20
> > Is this a bug:
> > in my code?
> > in Win32lib?  (version 0.59.1  8/June/2003)
> > in Windows NT4?
> >=20
> > -------------
> > include win32lib.ew
> >=20
> > constant Win =3D
> > create( Window, "Listview on TabControl Problem",0,1,1,550,500,0),
> >  tc =3D create(TabControl,"",Win,20,40,500,500,0 ),
> >  tab1 =3D create(TabItem,"tab 1",tc, 0, 0, 0, 0, 0 ),
> >  lv1 =3D create( ListView,{"column 1","column 2","column=20
> > 3"},tab1,5,30,450,300,
> >     or_all({LVS_REPORT,LVS_SHOWSELALWAYS})),
> >  tab2 =3D create(TabItem,"tab 2",tc, 0, 0, 0, 0, 0 ),
> >  lv2 =3D create( ListView,{"column 1","column 2","column=20
> > 3"},tab2,5,30,450,300,
> >     or_all({LVS_REPORT,LVS_SHOWSELALWAYS}))
> >=20
> > object index
> >=20
> > index =3D addLVItem( lv1, 0, {"apple juice","orange =
juice","grapefruit=20
> > juice"})
> > index =3D addLVItem( lv2, 0, {"apples","oranges","grapefruits"})
> >=20
> > WinMain(Win,Normal)
> > -----------
>=20
> I solved this problem in an amateurish way by destroy() -ing the=20
> listviews on the close event.

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu