Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 169
Default Listview - SetFocus and Me.Repaint

Hi,
When you have a form with a listview, the selected items disapeared when you
click on any other button. (The items are still selected but you can't see
it is) I'm wondering if it is normal ??
To solve this problem, I can write Me.ListView1.SetFocus on every events of
the form like:
Private Sub MyCheckbox_Click()
Me.ListView1.SetFocus
End Sub
.... Is there a better approach?

Also, I have multipage form, so, when I change page, the checkbox deasapear
inside the listview. To solve the problem, I wrote:
Private Sub MultiPage1_Change()
Me.Repaint
End Sub
Does anyone know the difference between Me.Repaint and SetFocus. I want to
be sure the form is refresh. When the focus is off, you cannot see the
selected items. Using Me.Repaint seems to be usefull only when you change
page.
Thanks a lot!!
Alex
--
Alex St-Pierre
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Listview - SetFocus and Me.Repaint

Alex,
May be need to set the .HideSelection=False.

NickHK

"Alex St-Pierre" wrote in message
...
Hi,
When you have a form with a listview, the selected items disapeared when

you
click on any other button. (The items are still selected but you can't

see
it is) I'm wondering if it is normal ??
To solve this problem, I can write Me.ListView1.SetFocus on every events

of
the form like:
Private Sub MyCheckbox_Click()
Me.ListView1.SetFocus
End Sub
... Is there a better approach?

Also, I have multipage form, so, when I change page, the checkbox

deasapear
inside the listview. To solve the problem, I wrote:
Private Sub MultiPage1_Change()
Me.Repaint
End Sub
Does anyone know the difference between Me.Repaint and SetFocus. I want to
be sure the form is refresh. When the focus is off, you cannot see the
selected items. Using Me.Repaint seems to be usefull only when you change
page.
Thanks a lot!!
Alex
--
Alex St-Pierre



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel window repaint slow/stuck hmm Excel Discussion (Misc queries) 1 August 13th 08 02:44 PM
Form Repaint Problem ybazizi Excel Discussion (Misc queries) 0 January 18th 06 05:32 PM
Excel does not repaint nodari Excel Programming 0 May 20th 04 04:39 PM
Repaint causes form to flicker Chad Excel Programming 2 April 28th 04 01:01 AM
How to force repaint of popup commandbar? RB Smissaert Excel Programming 0 December 17th 03 01:59 PM


All times are GMT +1. The time now is 07:56 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"