Create view in a CTabCtrl
-
I have created a CTabCtrl in a CView and would like to insert a CScrollView into it. I don't quite get it; should I use CWnd::Create or CWnd::CreateEx (I don't think I really need the dwExStyle). I've tried both but it doesn't seem to work (probably just me being stupid and handling wrong variables). Thank's for all your help /DrZOO :confused: (using VC.NET) Chics are for fags!
-
I have created a CTabCtrl in a CView and would like to insert a CScrollView into it. I don't quite get it; should I use CWnd::Create or CWnd::CreateEx (I don't think I really need the dwExStyle). I've tried both but it doesn't seem to work (probably just me being stupid and handling wrong variables). Thank's for all your help /DrZOO :confused: (using VC.NET) Chics are for fags!
-
Hello rbc This is how my code for creating a CTabCtrl in a CView CRect rcClient(......); m_TabWeek.Create(TCS_FIXEDWIDTH | WS_CHILD | WS_VISIBLE, rcClient, this, 0x1006); m_TabWeek.SetItemSize(CSize(45, 23)); csTabtext = ctWeek.Format("%W"); // If the label is "static" you only need to set pszText LPTSTR lpszTabtext = new TCHAR[csTabtext.GetLength()+1]; _tcscpy(lpszTabtext, csTabtext); TabItem.pszText = lpszTabtext; if(m_TabWeek.InsertItem(index, &TabItem) == -1) { AfxMessageBox("Unable to create week tab"); return false; } You're welcome! /DrZOO Chics are for fags!