|
|
Next, if your problem is to display a menu, try TrackPopupMenu or TrackPopupMenuEx members of CMenu class.
|
|
|
|
|
SaRath C wrote: Add message handler for NM_RCLICK
why not for WM_CONTEXTMENU ?
nave
|
|
|
|
|
yes WM_CONTEXTMENU of course with one if.if hwnd==m_list.hwnd
whitesky
|
|
|
|
|
See like this
<br />
void CAnswerDlg::OnNMRclickList1(NMHDR *pNMHDR, LRESULT *pResult)<br />
{<br />
HMENU hmenu,hmenuPopup;<br />
CPoint point;<br />
GetCursorPos(&point);<br />
hmenu = LoadMenu(AfxGetApp()->m_hInstance,(LPCTSTR) IDR_MENU1); <br />
hmenuPopup = GetSubMenu(hmenu, 0); <br />
TrackPopupMenu(hmenuPopup, TPM_LEFTALIGN | TPM_LEFTBUTTON, <br />
point.x,point.y, 0,m_List1.m_hWnd, NULL); <br />
DestroyMenu(hmenu); <br />
*pResult = 0;<br />
}<br />
whitesky
|
|
|
|
|
Dear guys,
I am trying to build an application using OMAKE,
the error is "fatal error RC1109: error creating TusMsvFE.res"
what could be the reason ?
Velayudhan
|
|
|
|
|
make sure that the file is not read only. that may be a reason for this.
SaRath.
"Don't Do Different things... Do Things Differently..."
Understanding State Pattern in C++
|
|
|
|
|
no , file is not read only
but when i deleted the tusmsvfe.res file from the folder and then builded, no error is there.
But again, when I modify resource, error comes,
what may be the reason ?
|
|
|
|
|
When I modify string like this
\nExts\nExts\nMyDocTypes(*.aaa;*.bbb)\n.aaa;.bbb\nExts.Doc\nExts Doc
then in "FileOpen" dialog file types are displayed:
MyDocTypes (*.aaa, *.bbb)
And I'd like it to be displayed like when I'm creating "FileOpen" dialog by myself - then file types are displayed like this:
MyDocType1 (*.aaa)<br />
MyDocType2 (*.bbb)<br />
MyDocType3 (*.ccc)<br />
MyDocType4 (*.ddd)<br />
All files (*.*)
How could I do this? )
~~~~
-- modified at 6:07 Thursday 8th June, 2006
|
|
|
|
|
I think it should be:
"MyDocType1 (*.aaa)\0*.aaa\0MyDocType2 (*.bbb)\0*.bbb\0MyDocType3 (*.ccc)\0*.ccc\0MyDocType4 (*.ddd)\0All files (*.*)\0*.*\0";
this is this.
|
|
|
|
|
See Here[^] maybe it is some helpful to you
whitesky
|
|
|
|
|
Hi
This is my first project on web services using MFC. I just have gone through Add Web Reference
menu item to add a web service. But while creating web service proxy file, it is giving the following error which I did not understand.
Creating web service proxy file for com.oracle.us.ecmbuild ...
sproxy : error SDL1000 : Not enough storage is available to complete this operation.
sproxy : error SDL1001 : failure in processing WSDL file: "c:\Documents and Settings\venkat\My Documents\Visual Studio Projects\ODriveNotifier\com.oracle.us.ecmbuild\RemoteLoginManager.wsdl".
I searched a lot on the net. I did come across questions which are same as this but I could not find the answer. Where is the problem? I appreciate any small help.
Thank you,
venkat.
|
|
|
|
|
can somebody tem me how to fetch date from mysql into vc++(MFC)
as mysql format is yyyy-mm-dd and mfc format is dd-mm-yyyy
now which function i use to fetch date as it is stored in mysql table
gourav dogra jfjunf
|
|
|
|
|
"Fetching" a date field is done exactly as you would for any other type of field (i.e., number, text). If the date is stored as yyyy-mm-dd, then I suspect you do not have a date field but rather a text field that just happens to hold the date. Can you confirm?
In this article, I retrieve several date fields from an Access database. It may give you some clues.
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
can we insert dialog box in between listbox items in runtime.
please tell me the solution.
or give me some samples
vasu.
-- modified at 5:29 Thursday 8th June, 2006
|
|
|
|
|
I am afraid you still don't make any sense
You know you're obsessed with computer graphics when you're outside and you look up at the trees and think, "Wow! That's spectacular resolution!"
|
|
|
|
|
vasusree wrote: can we insert dialog box in between listbox items in runtime.
No. What exactly do you mean by this?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
means when we select the listbox item then we should get the dialog exactly below that and below listbox items should be below that dialog
|
|
|
|
|
vasusree wrote: means when we select the listbox item then we should get the dialog exactly below that...
Below what? Which dialog?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Can you explain the difference between Thread,Process,
Event,Mutex and Semaphore.
I only know it is much related to Multithreading.
It would be greatly appreciated if someone explains in detail.
Thank you.
|
|
|
|
|
|
why should a call back function be static when its called from an another class?
say we have a class A and class B
assume that class A calls a function in B say "b" and passes the address of an another function in A say "a".
then to get get this working why is it a must that the function "a" be static.....we are passing the address of the member function as whole rt?.....
|
|
|
|
|
namaskaaram wrote: why should a call back function be static when its called from an another class?
It is not only when it has to be called from another class: it is whenever your callback function is a member function of a class.
The difference between static member functions and non-static member functions is that for the non-static one, there is an implicit parameter that is passed to the function: the address of the instance of your class (the this pointer). As static member functions are shared across all instances of your class (and thus don't belong to a particular instance, thus cannot access non-static data from one instance), there is no implicit 'this' parameter that is passed.
This of course change the prototype of the callback function (because of the implicit parameter), that's why static and non-static member functions behave differently.
Cédric Moonen
Software developer
Charting control
|
|
|
|
|
how to set the col width and row height according client rect and make the cells full fill with the client area.
I calc the value as follow way, but it still can't meet the rect....
BOOL CPgDialog::OnInitDialog()
{
CRect clrect;
long row=0,col=0;
m_grid.SetRows(20); // total rows 20
m_grid.SetCols(20); // total cols 20
m_grid.GetClientRect(&clrect);
long lwidth =clrect.Width()/m_grid.GetRows()*14.4; // inch?
long lheight = clrect.Height()/m_grid.GetCols()*14.4;
for (col=0;col< m_grid.GetCols();col++)
{
m_grid.SetColWidth(col,lwidth);
}
for (row=0;row
|
|
|
|
|
Are your sure that SetColWidth and SetRowHeight functions requires size in other units than pixels? Try without your "14.4 " multiplier.
|
|
|
|