|
poda123 wrote: Does any one know how to create a .dat file.
In exactly the same way as you would any other file. A file's extension has no bearing on how it is created.
poda123 wrote: The file should only be opened using specified program and
not by other editors.
This is rather difficult, if at all, to achieve.
poda123 wrote: For example,Yahoo messenger archieves are stored in
.dat file format.
But that does not imply that YM could open any .dat file, only those that it created.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hello Friends,
I want to change the Cursor when mouse is on Button.
This I want to do in ATL.
Abhijeet
|
|
|
|
|
You Can use SetCursor . Use CComModule::m_hInst as first parameter.
|
|
|
|
|
Alternatively, you can derive a class from CButton, implement a static method RegisterClass that will retrieve the BUTTON class info using GetClassInfo(Ex), then replace the class name with your class name, window procedure with yours and also the class hCursor with the desired cursor.
A similar technique can be found in MSDN for custom dialog classes.
|
|
|
|
|
Hi All
Is there any alternative function for atof() which accept wchar_t datat and convert to float.
Thanks
Atool
Atool
|
|
|
|
|
_wtoi
you can find it, togheter with _ttoi , the generic one, in MSDN, if you search for atoi , haven't you?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
CPallini wrote: _wtoi
How does that relate to floating-point numbers?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Sorry I was sure we were talking about atoi !!
It seems that atof has not a wide-string cousin.
Workarounds, I guess, maybe:
(1) using WideCharToMultiByte and then atof .
(2) using swscanf
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
The C runtime reference lists all the forms of functions including a table with the generic
text versions.
F1 is your friend
try _wtof
|
|
|
|
|
Hi
I want to add a com dll in my c++ project. I also post this query before and one experts suggets me to use explicit linking
and i follow the suggested steps.But now object of dll has been created but it disply exception.
i psate the code here
#import "Redemption.dll" no_namespace
HRESULT In=CoInitialize(NULL);
if ( SUCCEEDED ( In ) )
{
IRDOSession* Session=NULL;
iRDOStoresPtr ptr;
HRESULT hr =CoCreateInstance( __uuidof(RDOSession),
NULL,
CLSCTX_INPROC_SERVER,
//CLSCTX_LOCAL_SERVER,
__uuidof(IRDOSession),
(void**) &Session
);
if ( SUCCEEDED ( hr ) )
{
// Call methods using pISL here.
//Session->Logon(" ",NULL,NULL,NULL,NULL,NULL);
ptr=Session->Stores->AddPSTStore("c:\w.pst",NULL,"New");
}
Session->Release();
CoUninitialize();
}
the object is accessing all members but when called it display exception.
Plz tell what the prblem is.I got confused.
manu
|
|
|
|
|
manu_2205 wrote: ptr=Session->Stores->AddPSTStore("c:\w.pst",NULL,"New");
Try to replace the \ character with a double backslash (\\)
You should get at least a compiler warning, since escape-w isn't a valid escape character (or is it?).
Stores->AddPSTStore("c:\\w.pst",NULL,"New");
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
I try Again it display exception.
Even it has a Logon() function .It also disply run time error.
I am not getting what the problem is .
When i debug the application it open .tli file and disply exception.
manu
|
|
|
|
|
I want to tell that
IRDOSession :- is a interface
RDOSession:-It is coclass
manu
|
|
|
|
|
Hi manu,
try passing BSTR or unicode strings as the parameter value.
do not pass strings like "" etc,
give some value like L"myValue".
^-^
@|@
- redCat
|
|
|
|
|
What function?Whats values of input this function and what return value?
|
|
|
|
|
hi friends,
I got a problem while using this mciSendCommand(....) function. Actually I want to play PAL video files so I used the MCI_SETVIDEO using mciSendCommand(...) function for setting it as PAL video but I am getting the error returned from that function as MCIERR_MISSING_PARAMETER
void InitialiseMCIWindow()
{
UINT ut;
MCI_GENERIC_PARMS gen;
if((c_Player=MCIWndCreate(hwndParent,AfxGetInstanceHandle(),
WS_CHILD | MCIWNDF_SHOWNAME |
MCIWNDF_SHOWMODE |
WS_VISIBLE , m_sPath))==0)
MessageBox("Error in initialise");
gen.dwCallback = MCI_DGV_SETVIDEO_ITEM | MCI_DGV_SETVIDEO_SOURCE | MCI_DGV_SETVIDEO_SRC_PAL ;//
ut = MCIWndGetDeviceID(c_Player);
MCIERROR err = mciSendCommand((MCIDEVICEID)ut,MCI_SETVIDEO,MCI_NOTIFY,(DWORD_PTR) (LPMCI_GENERIC_PARMS) &gen);
if( MCIERR_MISSING_PARAMETER == err )
MessageBox("Error Got");
// if(err == 0)
// MessageBox("Success");
// else
// MessageBox("Failed");
.............
}
Can anyone help me with this problem???
With regards
Raja Bose
|
|
|
|
|
Just a thought, does gen need to be initialised?
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
first of all i like to thank u for replying ....
Still i am getting the error message even without gen initialisation ... without gen initialisation can u tell me how to set the source video as PAL
Thank u,
With regards
Raja Bose
|
|
|
|
|
I'm not very familiar with the commands, but according to MSDN http://msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_mcisendcommand.asp[^]
the command looks like this:
MCIERROR mciSendCommand(
MCIDEVICEID IDDevice,
UINT uMsg,
DWORD fdwCommand,
DWORD_PTR dwParam
);
where dwParam is a pointer to a structure that contains parameters for the command message.
So the command itself is contained in the struct.
Try to find a sample and start from there. Good luck.
Alcohol. The cause of, and the solution to, all of life's problems - Homer Simpson
|
|
|
|
|
gen.dwCallback should be the HWND of the window to receive the notification message when the
command completes since you're using MCI_NOTIFY.
the MCI_DGV_xxx flags should be combined (OR'd) with MCI_NOTIFY in the third param to
mciSendCommand().
Mark;
|
|
|
|
|
first of all i appreciate your kind help
Thank u very much for replying ..... Its working fine ....
Thanks a lot............
With regards
-- modified at 6:54 Thursday 4th January, 2007
Raja Bose
|
|
|
|
|
You're very welcome
|
|
|
|
|
Did you set dwValue member of the structure you used?
|
|
|
|
|
hello,
I have problem with plus. i couldnt get right total number!
And also I ld to know how to store all list of total number. coz i ld to compare them wh is biggest and smallest.
int n = 0;
cin>>n;
for ( i = 0; i < 3*n; ) {
cout << "Hand #" << n<< '\n';
for ( int j = 0; i < 52 && j < 3; i++, j++ ){
cout << deck[i].suit << deck[i].face <<" ";
deck[i].value++;
}
cout<<deck[i].value<<endl<<endl;
}
sample result:
S5 HK H6 total 6
|
|
|
|
|
davvid wrote: for ( int j = 0; i < 52 && j < 3; i++, j++ ){ cout << deck[i].suit << deck[i].face <<" "; deck[i].value++; }
I don't see how this can work. j will go up to 52, because it increases with i. deck[i].value is incremented, but never used in any way. It looks like it's all a mess.
I also don't see how this code relates to your question.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|