Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

WS_VISIBLE

Status
Not open for further replies.

bubak

Programmer
Jun 25, 2001
208
SK
I have two buttons, IDC1, IDC2
After pressing IDC2 this is done:
CButton *cb=(CButton*)GetDlgItem(IDC1);
cb->ModifyStyle(WS_VISIBLE,0);
But button1 doesn't go invisible, it will just get unenabled. Why ?
thx
bubak
 
sorry bout the thread, this-RedrawWindow() was it ;-)
 
The button could be visible, but without borders ant transparent. The correct is to make a combination between its style and WS_VISIBLE flag.
in pseudocode is:

x=get the style of the button;
cb->ModifyStyle(WS_VISIBLE|x,0);
John Fill
1c.bmp


ivfmd@mail.md
 
Hello John,
His problem is already solved but you made a small mistake with
cb->ModifyStyle(WS_VISIBLE|x,0);

because the sintax for ModifyStyle is:
BOOL ModifyStyle( DWORD dwRemove, DWORD dwAdd, UINT nFlags = 0 );

:)

[Romanian commentary:]
Ion, cum sa fac sa fiu si eu membru in Round Table, aici pe forum, trebuie indeplinite niste conditii?
Multumesc,


s-)

Blessed is he who in the name of justice and good will, shepards the week through the valley of darknees...
 
[Romanian commentary:]
Ion, ei singuri mi-au propus. Eu o sa incerc sa te propun. John Fill
1c.bmp


ivfmd@mail.md
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top