|
The strcat(string1, string2) looks suspicious: since the strcat function stores the result of concatenation in the first string, the string1 passed from Visual Basic may not have enough room for concatenated destination string.
|
|
|
|
|
how we can change the mouse cursor
thank u in advance;
sree
|
|
|
|
|
HCURSOR SetCursor(
HCURSOR hCursor // handle to cursor
);
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
sorry.what i mean is changing the mouse cursor shape from arrow to hand.
thank u in advance;
sree.
|
|
|
|
|
if you want to change shape use
HCURSOR hcur=LoadCursor(AfxGetApp()->m_hInstance,(LPCTSTR)IDC_HAND);
SetCursor(hcur);
whitesky
|
|
|
|
|
i got one error IDC_HAND undeclared identifier
|
|
|
|
|
sree_as wrote: i got one error IDC_HAND undeclared identifier
- IDC_HAND
- Windows 98/Me, Windows 2000/XP: Hand
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
I think you should instantiate the CWaitCursor class like this:
CWaitCursor pLengthyOperation; Good luck and keep the good coding! CWaitCursor Class[^]
|
|
|
|
|
See my post below.
And Yes SetCursor is used to set the shape of the cursor.
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
|
As said above, you could use SetCusrsor, see to that you use :: global scope to use it. ::SetCursor(hcursor)
<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--
[My Current Status]
|
|
|
|
|
again same error IDC_HAND undeclared identifier
|
|
|
|
|
<br />
#ifndef IDC_HAND<br />
#define IDC_HAND MAKEINTRESOURCE(32649) <br />
#endif<br />
Put these lines of the code somewhere at the top of the file where you are using IDC_HAND.
It will work
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
-- modified at 5:32 Monday 12th June, 2006
|
|
|
|
|
thank u very much.
but it's not working as we intended.hand symbol is not getting
|
|
|
|
|
Put Sleep(10000); after the statement SetCursor() and you will be able to see the cursor in the shape of the hand
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
Hey, try this : Go to insert menu, select resource, select Cursor type, click on import, now you select any .cur file you want to display. So many types are available in C:\windows\cursors directory. Now your cursor is included in your resource. Now, when you look into your resource.h file, you'll find a new entry,
#define IDC_CURSOR1 135 , (you could change the name to IDC_CURSOR1 to IDC_HAND or anything accordingly.
now try this code :
<br />
SetClassLong(m_hWnd,GCL_HCURSOR,(LONG)LoadCursor(AfxGetInstanceHandle(), MAKEINTRESOURCE(IDC_CURSOR1)));<br />
<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--
[My Current Status]
|
|
|
|
|
thank u vunik it's working
|
|
|
|
|
Hi again
Sorry I should say that I want to change the caption of "Dialog based" FORM in visual C++ 6.
I use SetWindowText but get exception.
Regards
Mahdi
|
|
|
|
|
You should follow the same thread
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
Can you be more specific whats error? and how to use SetWindowText
whitesky
|
|
|
|
|
You probably are calling SetWindowText in a wrong place. Try calling it in OnInitDialog at the end.
Otherwise give us more details regarding the exception. Maybe the passed string is invalid?
|
|
|
|
|
The most likely reason for the exception is that the window isn't created.
Call SetWindowText() from the OnInitDialog function.
|
|
|
|
|
yes my guess is exception maybe he dont have window
whitesky
|
|
|
|
|
could u pls paste your code here ?
Loka Samastha Sukhino Bhavanthu..!!!
( May all beings be happy and free )
|
|
|
|
|