when we create the window, we can choose some styles. but i see 2 problems:
- how can i hide the border?(i have seen the msdn styles, but theres no const for that)
- how can i change the styles after create the window?

This article might be of interest to you. Codeproject.com has one of the largest repositories of free Windows code that you will find on the internet. You will find examples of almost anything you want to do there.

AFAIK there is none. Here is the list of valid styles. There are many other styles but they are specific to window type such as buttons, dialog boxes, check boxes, etc.

Edited 3 Years Ago by Ancient Dragon

having test more and i found it.
when we create a window, we must choose what we need. theres some standard const's too ;)
when we need change it: we use the SetWindowLong() function very cool.
readers don't forget use GWL_STYLE for normal styles and GWL_EX_STYLE for EX styles;)

imagine that i need a window without any border(just the rectangule backcolor). what combination styles i can use?

if i use NULL(no style) the window stays with textbox style :(

Edited 3 Years Ago by cambalinho

finally i did ;)

// Step 2: Creating the Window
    hwnd = CreateWindowEx(
        WS_EX_APPWINDOW, //see here
        g_szClassName,
        "The title of my window",
         WS_OVERLAPPED|WS_POPUP , //see here
        CW_USEDEFAULT, CW_USEDEFAULT, 500, 500,
        NULL, NULL, hInstance, NULL);

explain to me what i'm confuse: the 1st and 4th arguments are for styles(they are both styles). can you explain better to me the diference?
and if i click 2 times(on task bar) the window isn't minimized.. it's a normal thing or i can activate that?

For detailed explanation of each argument you need to read this article. There are two functions -- CreateWindow() and CreateWindowEx(). If you compare the arguments of the two functions the only difference is the first argument, which are additional window styles not used in the first function.

Comments
thanks

i don't understand why not only 1 parameter for styles. but i have seen(i have tested now) they do a combination of the both styles(extend windows styles with windows styles). that's why i never get the borderless style ;)
hey i learned more than i thot today ;)
thanks for all

Edited 3 Years Ago by cambalinho

i need understand better about combinations styles for don't give me problems... but seems the msdn link isn't the best :(

It's almost a waste of time learning win32 api because it has been supersedded by .NET Framework. Your time would be more well spent by learning Windows Forms using CLR/C++, C# and VB.NET languages, all which use .NET Framework functions. It wouldn't surprise me if win32 api was someday (in the next 10 years) obsolete and no longer supported.

This question has already been answered. Start a new discussion instead.