-
September 9th, 2004, 04:00 AM
#1
How to Restore Encrypted Files
Hi Guru's
I want to restore encrypted file. For that i am using WriteEncryptedFileRaw API. When I am writting code in C- style it is working fine but same code is not working in c++ style code.
I am working in vc++ 6.0 under Windows 2000 professional.
Any body have any idea please help me.
Thank in advance
-
September 9th, 2004, 05:54 AM
#2
Re: How to Restore Encrypted Files
Way too few details to say anything sensible...
Please post some code.
Do you get compilation errors using the "C++ style"? Or runtime errors?
-
September 9th, 2004, 06:37 AM
#3
Re: How to Restore Encrypted Files
Hi Marc
In a Application, i Call function WriteEncryptedFileRaw .
DWORD ii = WriteEncryptedFileRaw(&WriteCallback, &hf, pvContext) ;
It gives error code 1917.
DWORD WINAPI WriteCallback(PBYTE pbData, PVOID pvCallbackContext, PULONG ulLength)
{
HANDLE *phRawFile=(HANDLE *)pvCallbackContext;
unsigned long nBytesRead=0;
bool bStop=false;
if(!ReadFile(*phRawFile,(LPVOID)pbData,*ulLength,&nBytesRead,0))
{
bStop=true;
}
*ulLength=nBytesRead;
// nTotalBytes+=nBytesRead;
printf("\n %u", nBytesRead);
return bStop;
}
How i solve the problem ........
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|