Click here to Skip to main content
15,913,854 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: HWND_TOP to make a dialog topmost??? Pin
KingsGambit8-Feb-10 7:27
KingsGambit8-Feb-10 7:27 
AnswerRe: HWND_TOP to make a dialog topmost??? Pin
Iain Clarke, Warrior Programmer8-Feb-10 1:34
Iain Clarke, Warrior Programmer8-Feb-10 1:34 
GeneralRe: HWND_TOP to make a dialog topmost??? Pin
Arrin8-Feb-10 2:37
Arrin8-Feb-10 2:37 
GeneralRe: HWND_TOP to make a dialog topmost??? Pin
Iain Clarke, Warrior Programmer8-Feb-10 2:59
Iain Clarke, Warrior Programmer8-Feb-10 2:59 
QuestionChallenges of running an application on multi core environment Pin
coder21k7-Feb-10 21:11
coder21k7-Feb-10 21:11 
AnswerRe: Challenges of running an application on multi core environment Pin
Iain Clarke, Warrior Programmer8-Feb-10 0:00
Iain Clarke, Warrior Programmer8-Feb-10 0:00 
AnswerRe: Challenges of running an application on multi core environment Pin
CPallini8-Feb-10 2:04
mveCPallini8-Feb-10 2:04 
GeneralRe: Challenges of running an application on multi core environment Pin
coder21k8-Feb-10 17:44
coder21k8-Feb-10 17:44 
AnswerRe: Challenges of running an application on multi core environment Pin
ThatsAlok9-Feb-10 0:22
ThatsAlok9-Feb-10 0:22 
QuestionFind all Machines in Domain or Workgroup. Pin
Le@rner7-Feb-10 19:37
Le@rner7-Feb-10 19:37 
QuestionRe: Find all Machines in Domain or Workgroup. Pin
David Crow8-Feb-10 5:04
David Crow8-Feb-10 5:04 
AnswerRe: Find all Machines in Domain or Workgroup. Pin
Le@rner8-Feb-10 17:17
Le@rner8-Feb-10 17:17 
QuestionRe: Find all Machines in Domain or Workgroup. Pin
David Crow9-Feb-10 3:30
David Crow9-Feb-10 3:30 
QuestionA program in task bar Pin
kk.tvm7-Feb-10 19:02
kk.tvm7-Feb-10 19:02 
AnswerRe: A program in task bar Pin
«_Superman_»7-Feb-10 19:39
professional«_Superman_»7-Feb-10 19:39 
QuestionHelp - Some Registry Settings not Applicable on Server. Pin
Le@rner7-Feb-10 18:11
Le@rner7-Feb-10 18:11 
AnswerRe: Help - Some Registry Settings not Applicable on Server. Pin
Kushagra Tiwari7-Feb-10 19:13
Kushagra Tiwari7-Feb-10 19:13 
GeneralRe: Help - Some Registry Settings not Applicable on Server. Pin
Le@rner7-Feb-10 22:14
Le@rner7-Feb-10 22:14 
QuestionHOWTO: how to add watermark to bitmap/jpg file? Pin
Symfund7-Feb-10 15:03
Symfund7-Feb-10 15:03 
AnswerRe: HOWTO: how to add watermark to bitmap/jpg file? Pin
CPallini7-Feb-10 21:00
mveCPallini7-Feb-10 21:00 
Question[Solved]Loading a certificate and creating a PCCERT_CONTEXT returns 2148086027 [modified] Pin
mmavipc37-Feb-10 11:55
mmavipc37-Feb-10 11:55 
Edit: looks like the cert cant be base-64 encoded
cacert.cer is a X509 base64 encoded certificate
ifstream file ("cacert.cer", ios::in|ios::binary|ios::ate);
char * memblock;
int size;
if (file.is_open())
{
    size = file.tellg();
    memblock = new char [size+1];
    file.seekg (0, ios::beg);
    file.read (memblock, size);
    memblock[size]=0;
    file.close();

    cout << "Certificate file has been loaded!\n";
}
byte* byteblock = new byte;
byteblock = (byte*)memblock;
//cout << *byteblock[30] << "\n";
mycert = CertCreateCertificateContext(X509_ASN_ENCODING,byteblock,size);
if (!mycert){
    cout << "error: " << GetLastError() << "\n";
}else{
    cout << mycert->pbCertEncoded << " encoded cert\n";
}

What am I doing wrong?
modified on Sunday, February 7, 2010 6:03 PM

QuestionFormatting text based on delimeter Pin
gregarion7-Feb-10 9:22
gregarion7-Feb-10 9:22 
AnswerRe: Formatting text based on delimeter Pin
Garth J Lancaster7-Feb-10 9:47
professionalGarth J Lancaster7-Feb-10 9:47 
QuestionHow do you type the &quot;or&quot; Pin
fudgemaster7-Feb-10 5:15
fudgemaster7-Feb-10 5:15 
AnswerRe: How do you type the &quot;or&quot; Pin
CPallini7-Feb-10 5:53
mveCPallini7-Feb-10 5:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.