|
Yes it does not but you can insert it in the project using "Insert ActiveX Control" and select "Microsoft Masked Edit Control, version 6.0".
|
|
|
|
|
Of course. It's not quite built-in as it is an external ActiveX control, but a masked edit control nonetheless. What specific problem are you having with it? You indicated that alphanumeric text was troubling you. Does that imply that alpha-only and numeric-only are working fine? I'm just trying to narrow down if it's a specific usage of the control that's the problem, or the control as a whole. What mask/format are you trying to use?
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Whether I use a mask for numeric or no mask for just plain string, I am not able to display anything at all in the control.
I created a simple project with just the dialog and the control and I am still unable to display any string.
|
|
|
|
|
I'm having troubles to serialize my object.
I have a class called: CDecDatabase that have a member of type CObArray of CSistema object, (an array of CSistema objects).
CSistema object have 3 arrays CObArray, (arrays of objects CP1, CP2 y CP3).
All the object have a Serialize function.
First I invoke CDecDatabase::Serialize(), then, this function call Serialize() of the array of CSistema and this function call the methods Serialize() for the other arrays of CP1 CP2 and CP3 objects.
Something I have saved but this is not all the data.
I don't know if I'm serialize the objects in the right order.
Thank you.
Demian.
|
|
|
|
|
Hi,
Currently i am working on single document interface MFC to create a small update program to the database to change the values store in the fields.
However, in order to let the program run "automatically", i have to used thread. But I know nuts about threading.
I have attached the main part of the updating of the program below. pls kindly help..I have read up on books about C++ on the thread function. the book says, to create and start, i have to use AfxBeginThread and have some arguements inside. and a function UINT MyThreadFunction(LPVOID pParam).
Really need help on this as its very urgent to me... Thanks a million.
<br />
void CUpdateView::OnUpdatedb() <br />
{<br />
<br />
double propa_update = 0.814;<br />
double resp_update = 0.205;<br />
double link_update = 1.19;<br />
<br />
CUpdateDoc* pDoc = GetDocument();<br />
UseRecordset* pUseRecordset = &pDoc->m_UseRecordset;<br />
<br />
do<br />
{<br />
pUseRecordset->Edit();<br />
<br />
pUseRecordset->m_propatime = pUseRecordset->m_propatime*propa_update;<br />
pUseRecordset->m_respondtime = pUseRecordset->m_respondtime*resp_update;<br />
pUseRecordset->m_link = pUseRecordset->m_link*link_update;<br />
<br />
pUseRecordset->Update();<br />
<br />
pUseRecordset->Requery();<br />
<br />
UpdateData(true);<br />
}while(check_exit!=0);<br />
}<br />
<br />
void CUpdateView::OnExit() <br />
{<br />
check_exit=0;<br />
OnExit();<br />
}
|
|
|
|
|
Sounds like you need a worker thread (i.e., a thread with no message pump). If so, read this article. When it comes time to update the database, create the thread and put your update code in this thread. You might want to periodically post a message back to the main thread indicating progress.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Hi,
I have read the article that you gave me and have tried implementing the methods into my program.. however, that are still one error which i hope u could help me..
<br />
void CUpdateView::OnUpdatedb() <br />
{<br />
running = true;<br />
AfxBeginThread(run, this);<br />
<br />
}<br />
<br />
UINT CUpdateView::run(LPVOID p)<br />
{<br />
CUpdateView* pView = (CUpdateView*)p;<br />
pView->run();<br />
<br />
double propa_update = 0.814;<br />
double resp_update = 0.205;<br />
double link_update = 1.19;<br />
<br />
do<br />
{<br />
CUpdateDoc* pDoc = GetDocument(); UseRecordset* pUseRecordset = &pDoc->m_UseRecordset;<br />
<br />
pUseRecordset->Edit();<br />
<br />
pUseRecordset->m_propatime = pUseRecordset->m_propatime*propa_update;<br />
pUseRecordset->m_respondtime = pUseRecordset->m_respondtime*resp_update;<br />
pUseRecordset->m_link = pUseRecordset->m_link*link_update;<br />
<br />
pUseRecordset->Update();<br />
<br />
pUseRecordset->Requery();<br />
}while(check_exit!=0);<br />
<br />
return 0;<br />
}<br />
<br />
void CUpdateView::OnExit() <br />
{<br />
running = false;<br />
}
The part that i have it bold is giving mi the error..
the error message is :
'CUpdateView::GetDocument' : illegal call of non-static member function
This problem is it because i have the UINT CUpdateView::run(LPVOID p) declare as static?
see declaration of 'GetDocument'
My declaration is CUpdateDoc* GetDocument(); in CUpdateView Class
|
|
|
|
|
See if this helps:
CUpdateDoc* pDoc = pView->GetDocument();
Keep in mind that what you have will not work if the primary thread is also accessing the document or the recordset.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Hi,
Thanks for ur help.
dReaMerzZ
|
|
|
|
|
I can remember a tool a couple years back that provided a dialog editor similar to VB, where control colors, etc could be easily changed, but it was for VC++. Does anyone remember the exact product?
Jim
QTExtender - The OFFICIAL addon for QuoteTracker.
|
|
|
|
|
wasn't it the "Borland C++" one ?
TOXCCT >>> GEII power
|
|
|
|
|
Yes, Borland had a very nice one called Resource Editor. Whether it's the one in question remains to be seen.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
|
I think VS.NET has that feature.
|
|
|
|
|
Hi,
I'd like to create a toolbar in IE, so that when a user clicks it, it can 'read' the current HTML page being displayed. Does anyone have a pointer where to look for some example code?
Sort of like clicking the "view source" menu option, but then with code of my own.
thanks.
Pauwl
|
|
|
|
|
Hi,
For a normal Visual C++ program, we have a void main. But in creating a MFC single document interface, does anyone know which function is something similar to void main?
Thanks for ur help
|
|
|
|
|
The main in MFC is a "WinMainX" and is somehow "invisible" to the eye, it was wrapped by MFC code,
What do you exactly need?
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
Hi,
I would like the program to start running once i compile the program.. so i was thinking if i could add my coding in the void main then i can get it start running the minute i compile it..
dreamerzz
|
|
|
|
|
you mean while compiling it????
or you want a program to run while compiling another?
o you want to run the program as soon as it finish compiling and linking?
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
oh.. sorry for the unclear msg.. I want to run the program as soon as it finish compiling and linking.. whereby the program seems to be "automatically" running..
dreamerzz
|
|
|
|
|
Start it within the IDE using Ctrl+F5. That'll compile and link (if necessary), and then run.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
See AppModul.cpp for specific implementation details of _tWinMain.
onwards and upwards...
|
|
|
|
|
Argh... the internet connection failed just when I posted the first answer...
well... lets do it again...
You can do it in three ways:
-> if you don't need to do anything to the GUI you can use the InitInstance function in the main class.
-> if you need to interact with the main frame (the SDI document view container) you can do it in the precreatewindow function in the mainframe class.
-> if you need to interact with the view you can do it in the precreatewindow of the view class.
hope this helps...
|
|
|
|
|
Hi, Thanks for ur help.. i will give it a try and will let u know abt the results..
Thanks a million
dreamerzz
|
|
|
|
|
Hi,
thanks for the help given
dReaMerzZ
|
|
|
|