|
if the function is a member of a class, you must declare it static, so that it wont have the implicit this parameter...
by the way, i may be wrong (i see you're talking about the .NET Framework) but the C++/CLI forum may be more appropriate for your question.
|
|
|
|
|
it should be either global or public static of a class.
SaRath.
"Where I am from, there is no plan B. So, take advantage of today becuase tomorrow is not promised. - 50 Cent"
My Blog | Understanding State Pattern
Last modified: Wednesday, August 09, 2006 9:20:41 AM --
|
|
|
|
|
Sarath. wrote: either
nope. it should be both !!!
|
|
|
|
|
ooops.. sorry man.. it was a mistake I meant either in global or in public static scope. I shall correct it
SaRath.
"Where I am from, there is no plan B. So, take advantage of today becuase tomorrow is not promised. - 50 Cent"
My Blog | Understanding State Pattern
|
|
|
|
|
It should be a static function.
|
|
|
|
|
i think answering something that was posted about 2 hours before is not the best thing to do, especially if you don't provide much info...
|
|
|
|
|
hehe, I did not read the other answers
|
|
|
|
|
I'm writing VC++ .net framework code.
I need to retrieve the windows WM_DEVCHANGE message
Shall I use virtual void WndProc( Message* m ) override function or LRESULT CALLBACK WindowProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) function??
How shall I add either of them to my Form class???
May you write down the format?
|
|
|
|
|
Hi,
I'm backing up files.. i want to know a better way of updating modified files.. now i just delete the old file and make a copy of modified file..
say if the file is in GB and just one line is appended in the last, for this i have to make a copy of data in GB.. is there any way to found which line is modified..
comparing files will be more expensive than make a copy, so any other suggestions or it is possoble to update a file like this..
Do your Duty and Don't expect the Result
|
|
|
|
|
Just a thought...
Check out ezpatch and RTPatch programs. As far as I remember, they store one copy of the file. Later they just store the differences between the file versions.
It might be one way to go.
|
|
|
|
|
I have created an add-in to do many things in the visual studios 6.0 environment. In this add-in I display things to the macro tab which is on the "Output Window" which also has the tabs Build,Debug,Find in Files1,Find in Files2 tabs. I am using IApplication* p_app->PrintToOutputWindow() function for showing messages and other things on the macro tab.
1. Is there a way to automatically display the macro tab after showing a printing a message on it?
2. Is there any way to clear this window programmatically?
Chris
|
|
|
|
|
Thanks but nothing is working i have tried everyting ! my code remaine the same !
Please someone help me !
void CMyList::OnOK()
{
UpdateData();
CWaitCursor wait; // Display a wait cursor
int x = m_list.GetItemCount();
for (int j = 0; j < x; j++) // For each item in the list
{
CString strWord;
strWord = m_list.GetItemText(j, 0); // Get the word
strWord.TrimLeft(); // Remove leading spaces
strWord.TrimRight(); // Remove trailing spaces
// Overwrite the old word with the new trimmed word
m_list.SetItemText(j, 0, strWord);
}
CString sName = _T("Name");
m_name.GetWindowText(sName);
LVFINDINFO stInfo = {0};
stInfo.flags = LVFI_STRING;
stInfo.psz = sName;
int nItem = m_list.FindItem( &stInfo );
if( nItem != -1 )
{
// the item is in the list control
CString sSecondColumnText = m_list.GetItemText( nItem, 1 );
// set the text to the second edit box
m_rezult.SetWindowText( sSecondColumnText );
}
}
///////////////////////////////////////////////////////////////////////
----------------------------------
| Name | City | Country |
----------------------------------
| George| London| England |
-----------------------------------
|George |NewYork | USA |
-----------------------------------
for ex :
all i whant is to find if george - London - England exist !
or
all i whant is to find if george - NewYork - USA exist !
m_name , m_city , m_rezult ! m_rezult <----- Country!!!!
Thank you !
Bravoone
|
|
|
|
|
|
Can you give me an example on how to find an item in second column ?...etc - 3d column... ? Please !!!!!
Bravoone
|
|
|
|
|
<br />
CString find ="test1";<br />
CStringArray string1;<br />
CString search;<br />
for(int nIndex = 0; nIndex < m_Ctrl1.GetItemCount(); nIndex++)<br />
{ <br />
search= m_Ctrl1.GetItemText( nIndex, 0 );
if(search==find)<br />
string1.Add(search);<br />
}<br />
|
|
|
|
|
Flaviu_2006 wrote: Can you give me an example on how to find an item in second column ?...
You could have saved yourself and others a lot of time by specifying this up front rather than after umpteen suggestions have been offered.
"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,
Could anyone tell me how to detect the play of a video file (any video file like AVI, WMV, MPEG etc...)?
If any application (like RealPlayer or Windows Media Player) plays the video file, my application should recieve a notification.
Thanks in advance,
Pavan
-- modified at 7:57 Wednesday 9th August, 2006
Regards,
Pavan
|
|
|
|
|
Do you want to play these files?
|
|
|
|
|
I dont want to play the files. I just want a notification when some video file is played by some other application like RealPlayer, Windows Media Player etc...
Regards,
Pavan
|
|
|
|
|
I think we can do something with the pins connected of a filter. But im not done anything related to these stuffs.
check it in that way. you may be get some info on the same.
SaRath.
"Where I am from, there is no plan B. So, take advantage of today becuase tomorrow is not promised. - 50 Cent"
My Blog | Understanding State Pattern
|
|
|
|
|
Sarath,
Thanks for your reply. I will try on the filters and pins. Meanwhile if you get some more info please do keep posting.
Regards,
Pavan
|
|
|
|
|
Hello friends,
I am facing problem how to load the bitmap to dialog form in MFC. Can anyone help me in this matter. Can any one help me in this matter?. Can explain how to load the bit map with a sample code in MFC.
Hoping for a reply on this issue.
From
Phijo
|
|
|
|
|
If you want to load bitmap from your resource then use LoadBitmap(..)
Refer LoadBitmap[^]
if the bitmap is a file in your PC then use LoadImage(...)
Refer LoadImage[^]
Do your Duty and Don't expect the Result
|
|
|
|
|
Import bitmap-> create a new picture control select properties then select type = bitmap and image = "your image" !!!!
Bravoone
|
|
|
|
|
See CImage::Load or LoadImage
CImage::Load(...) then use CImage::BitBlt(...) and in the end use CImage::Detach()
|
|
|
|