|
now there is no error
But when i m accessing it my MessageMap function like this:-
recv_val *obj_recv = static_cast<recv_val*>(lparam);
its giving an error:-
error C2440: 'static_cast' : cannot convert from 'long' to 'struct recv_val *'
recv val is also a structure in other class in which i m having my messagemap
struct recv_val
{
CString Recv_URL;
CString Recv_name;
int Recv_index;
};
|
|
|
|
|
sulabh_expert@rediffmail.com wrote: recv_val *obj_recv = static_cast(lparam);
See replies below.
-- modified at 3:29 Tuesday 20th March, 2007
|
|
|
|
|
same error is coming..........
|
|
|
|
|
Use reinterpret_cast.
recv_val *obj_recv = reinterpret_cast<recv_val*>(lParam);
|
|
|
|
|
use reinterpret_cast<>() instead
|
|
|
|
|
sulabh_expert@rediffmail.com wrote: struct recv_val
{
CString Recv_URL;
CString Recv_name;
int Recv_index;
};
Make sure the struct is properly defined. In the sender side you defined as int, CString, CString...
You can typecaste as below,
struct recv_val* pStruct = (recv_val*)(LPVOID)lParam;
Do your Duty and Don't expect the Result
|
|
|
|
|
using C style cast is the simplicity mistake...;P
|
|
|
|
|
thanku all my problem got solved..................
|
|
|
|
|
I am facing same issue.
My message received at other side but I can access/cast structure at receiving side.
Can you specify which one solution works for you?
regards,
Divyang Mithaiwala
|
|
|
|
|
sulabh_expert@rediffmail.com wrote: recv val is also a structure in other class in which i m having my messagemap
struct recv_val
{
CString Recv_URL;
CString Recv_name;
int Recv_index;
};
The structures must match.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
|
Hi
All
I want to customize menu in my application in VC++ 6.0.In my application i want to display Marathi/Hindi font in menu, so how can i done it.
Regards
Atool
|
|
|
|
|
|
i have to implement http authentication using vc++ and i m new to vc++ please guide me how to make a sample application to implement this.
thanks
|
|
|
|
|
Hi
Ajay
Which version on VC++ ur using , so that i can guide u.
Regards
Atul
|
|
|
|
|
thanks atul for helping
my version is VC++ 6.0
and i want to know about how i can implement http auth and proxy authentication
thanks
|
|
|
|
|
Hi!
I'm doing something similar to this, but I'm using Visual C++ 2008..
I tried using libCurl but still can't make it work. Hoping someone can help me. Thanks in advance!
|
|
|
|
|
This WM_DEVICECHANGE handler is not being fired when i insert a normal CD(i.e Non Autorun type). can you help how to detect insertion or removal of such CD
Thanks in advance
R e h a n
|
|
|
|
|
VC_RYK wrote: This WM_DEVICECHANGE handler is not being fired when i insert a normal CD(i.e Non Autorun type).
this is because windows deactivated it. you must set windows to enable it, because you cannot force a CD/DVD to auto start if no autorun runs on te system
|
|
|
|
|
Thanks Dear But how will i enable it in windows?
|
|
|
|
|
What is the value of HKLM\System\CurrentControlSet\Services\CDRom and HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoDriveTypeAutoRun
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
HKLM\System\CurrentControlSet\Services\CDRom =0
HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoDriveTypeAutoRun = i dont have this Option in System, i have till(HKCU\Software\Microsoft\Windows\CurrentVersion\internet setting
Please do help me out
|
|
|
|
|
VC_RYK wrote: HKLM\System\CurrentControlSet\Services\CDRom =0
This should be set to 1 if you want autorun to work.
VC_RYK wrote: HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoDriveTypeAutoRun = i dont have this Option in System
Do you have HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoDriveTypeAutoRun instead? In either case, see here for how to use it.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
I want Autorun as i insert my CD/DVD, if i am writing Autorun.inf so what i should write and where should i put it.
Thanks in advance
R e h a n
-- modified at 1:07 Tuesday 20th March, 2007
|
|
|
|
|
VC_RYK wrote: where should i put it
at the root of the CD/DVD
|
|
|
|