|
CodeVarma wrote: Why Virtual Constructor doesn't exist ?
Virtual implies partial information. In other words, only the interface is known as opposed to the exact object type. You need complete information about an object in order to create it.
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi to all,
How I can use "Tab Control" in a Dialog?
I had searched for it, but the method was to create a new Class inherited from 'CTabCtrl'.
Can't I use simple Member Variable for "Tab Control" of 'CTabCtrl' type in that Dialog?
Thanks & Best Regards,
Aniket Salunkhe
|
|
|
|
|
|
WhiteSky wrote: Hope I understood your question
Take an example that in Dialog I have a ComboBox 'IDC_COMBO1'. Let member variable attached to it is 'm_cmbCombo1' of 'CComboBox' Class. So to add data in it we can directly use AddString(), InsertString(),..etc.
Similary can't I use a Member variable 'm_tabTab1' of 'CTabCtrl' Class( for a Tab Control) to AddPages & other operation using help of other classes like 'CPropertyPage', 'CPropertySheet',..
'CTabCtrl' has a methods, InsertItem() & other. So using that methods only, can't I use Tab Control ( OR add Dialogs to Tab Control)....instead of Inheriting a new Class from 'CTabCtrl'.
|
|
|
|
|
I dont understand Is your problem CTabCtrl that you cant insert items to it?
|
|
|
|
|
ya, ( how to insert Dialog using Member Fubctions of CTabCtrl Class? )
|
|
|
|
|
See
<br />
m_Tab1.Create(WS_CHILD|WS_VISIBLE,CRect(0,0,150,45),this,1);<br />
<br />
TC_ITEM TabCtrlItem;<br />
TabCtrlItem.mask = TCIF_TEXT|TCIF_PARAM|TCIF_STATE;<br />
TabCtrlItem.dwState=TCIS_HIGHLIGHTED ;<br />
<br />
CStringArray m_GetString;<br />
m_GetString.Add("Item1");<br />
m_GetString.Add("Item2");<br />
m_GetString.Add("Item3");<br />
for(int i=0;i<m_GetString.GetCount();i++)<br />
{<br />
TabCtrlItem.pszText = CT2A(m_GetString.GetAt(i));<br />
TabCtrlItem.lParam=i;<br />
m_Tab1.InsertItem( i, &TabCtrlItem );<br />
}<br />
<br />
|
|
|
|
|
WhiteSky wrote: for(int i=0;i {
TabCtrlItem.pszText = CT2A(m_GetString.GetAt(i));
error in these line. 'CT2A' : undeclared identifier
WhiteSky wrote: m_Tab1.InsertItem( i, &TabCtrlItem );
InsertItem() will add tabs in Tab Control.... instead of that can I add dialogs ( other newly created dialogs) in Tab Control as a new tab?
|
|
|
|
|
if you use vs2005 you can LPTSTR() instead CT2A or see
<br />
TCHAR lp[120];<br />
lp[0]='\0';<br />
strcat(lp,"test");<br />
TabCtrlItem.pszText = lp;
Aniket Salunkhe wrote: can I add dialogs ( other newly created dialogs) in Tab Control as a new tab?
See CPropertyPage Class
[^]and see examples in this page
|
|
|
|
|
Hi All,
I need to convert a word file to text. How it can be possible in VC++,
Please Help me
Thanks in Advance
George K Jolly
|
|
|
|
|
you have to know the word format, which is proprietary format... so, good luck
|
|
|
|
|
Using Word automation, open the file and save it as a text file.
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi all,
Can someone plz point me to a site or give me some advice on getting the currently logged on user (windows system).
Thanx in advance.
Regards
Programm3r
|
|
|
|
|
Will GetUserName() work for you?
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Thanx .... already came right.
Regards
Programm3r
|
|
|
|
|
I've derived a class from CButton, i draw the states. i use the BS_OWNDERDRAW style. i've read that i can't use both BS_PUSHBUTTON and BS_OWNDERDRAW.
problem starts that when i have a dialog contains this button, and i am on focus on a different dialog, pressing this button will only set the focus to the first dialog (the one that the button is on) and not operate the BN_CLICK message on the button. pressing on the button again will operate it....it is not a common behaviour of CButton...
how can i resolve that
thanks in advanced
Yaron
Interface basics click here :
http://www.codeproject.com/com/COMBasics.asp
don't forget to vote
|
|
|
|
|
|
thanks
Interface basics click here :
http://www.codeproject.com/com/COMBasics.asp
don't forget to vote
|
|
|
|
|
Hi,
i am using SHBrowseForFolder() function to traverse through the local system drives and shared network drives. But if i select a shared network drive which is password protected it does not ask for username and password. Due to which i was unable to traverse the shared drive. Can anybody tell me how to unable this facility or how to capture the double click of mouse on the tree shown in Browse For Folder dialog.
Thanks.
|
|
|
|
|
I've been stuck on this problem all day. I have an ini file, code to read/write to it correctly, and now I want to move all the configuration from the main window to a new TreePropSheet dialog. Everything starts out going fine, it opens, everything runs, when you go to the configuration the window comes up and the values are not there, nor can they be set. I want to know what is wrong with my code, why it isn't loading values, and why even if it doesn't load when you change the dialog it doesn't activate the Apply button as expected.
The project is here: http://eludevisibility.org/MeowDB.zip[^]
|
|
|
|
|
It will remember the input between pages now but it still will not read or write to the .ini file.
|
|
|
|
|
I'm trying to build a project on x64 config but gives some link error. This project builds fine on win32 configuration.It uses a library file namely htmlhelp.lib under the DDK path $(DDKXProot)\lib\w2k\i386\htmlhelp.lib. What should be the corresponding file for x64 configuration
|
|
|
|
|
Hello everyone,
I use editor to open a shortcut file on my Mobile device. Which content is,
--------------------
135#"\Program Files\runSample.exe"
--------------------
I am wondering what means 135#? A special sign for shortcut of Windows Mobile?
thanks in advance,
George
|
|
|
|
|
maybe the ID of its icon in some library ?!
|
|
|
|
|
Thank you toxcct!
Do you have any official documents about this?
regards,
George
|
|
|
|