News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Main application Tab Control question

Started by z941998, April 23, 2011, 02:30:34 AM

Previous topic - Next topic

z941998

Hi all, I want to create an app that has Tab Control in the main clIEnt window area (ie. I do not want to use a dialog box).

I read in the SDK how to do this.  Everything is fine except that the SDK refers to WC_TabConrol as a extended window style.

When I tried to complie I get an error message indicating undefined extended style.  I searched the masm lib include files and did not find it.

What should be used to create a tab control within the main app?


Gunner

szWndClsTab             BYTE    "SysTabControl32", 0


is the class to use in CreateWindowEx
~Rob (Gunner)
- IE Zone Editor
- Gunners File Type Editor
http://www.gunnerinc.com

dedndave

also, win32 constants are case sensitive
so, if it were defined, it would be WC_TABCONTROL
in C programs, that is defined as the string that Rob showed you
that doesn't quite work the same way in ASM, so you need to define the string and, in the INVOKE parameter, use:
offset szWndClsTab

z941998

I lost some hair on this one.  I was also refered to another post (search for Tabber.zip) that demon-strats what the both of your replys states.

My app is up and running now.

Thanks
Steve

dedndave

don't feel too bad
i am losing hair on a simple tooltip demo - lol
not the program, so much as getting it to work with a manifest

it's ok - a learning experience that will pay off in the future (if i don't forget it all)

Slugsnack

a few tips. when you create content windows for the tab, make them as children of the tab control, not the parent window. also if you do that you will notice some colour discrepancies. in this case you will find EnableThemeDialogTexture very useful..

also consider using resources instead of pure win32 api createwindow/ex. it's much the same unless you want to do something very complex and custom