Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - SetVisible problem
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

SetVisible problem

 Post Reply Post Reply
Author
Message
robosport View Drop Down
Groupie
Groupie


Joined: 20 June 2005
Location: United States
Status: Offline
Points: 62
Post Options Post Options   Thanks (0) Thanks(0)   Quote robosport Quote  Post ReplyReply Direct Link To This Post Topic: SetVisible problem
    Posted: 29 April 2008 at 5:31am
I'm using CommandBars->FindControl( xtpControlButton, menuItemID, FALSE, TRUE ); to locate a hidden CXTPControl* and then calling SetVisible member of the CXTPControl to show it.
 
I have confirmed (debugger step throughs and asserts) I'm finding the pointer to the control just fine everytime, but sometimes when I call SetVisible( TRUE ) the control stays hidden.  I know the call is being made with the TRUE parameter but the control remains hidden - sometimes but not always .
 
Is there something else I need call after SetVisible to force a control, menu, interface, etc. to update?
 
Thanks!
 
 
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 29 April 2008 at 7:59am
Hi,
FindControl is very bad solution - user can remove this control, copy to some toolbar etc. Use Update handlers or Actions.
 
See Actions sample.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.063 seconds.