How to edit windows?(buttons,text)

i want to make something like spoiler button that when onclicked shows text and when clicked again hides it i can only create the text window please help


P.S. i'm new to c++
Shows some text where? On the button? If so, use SetWindowText.
What you really want to know is windows API, does not matter what programming language are you using.
C++ does not know what a 'button' is, in fact does not know what a computer screen is.
i understand that btw in c++ button,text,texfield are all called window as far as i know and i want to know how to change their properties like what text it shows or where it is stuff like that..

Last edited on
is that really in c++?
Technically, c.
If you want to show/hide the text of a button you can use SetDlgItemText() and/or GetDlgItemText().

SetDlgItemText():
http://msdn.microsoft.com/en-us/library/windows/desktop/ms645521(v=vs.85).aspx

GetDlgItemText();
http://msdn.microsoft.com/en-us/library/windows/desktop/ms645489(v=vs.85).aspx
MSDN has a list of common controls and how to manipulate them here:

http://msdn.microsoft.com/en-us/library/windows/desktop/bb773169(v=VS.85).aspx
Topic archived. No new replies allowed.