Click here to Skip to main content
15,890,512 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: which tool can be used develop c++ code i.e visual studio or unix Pin
CPallini13-Oct-14 22:08
mveCPallini13-Oct-14 22:08 
GeneralSuggestion on C++ Pin
Member 1081309011-Oct-14 4:45
Member 1081309011-Oct-14 4:45 
GeneralRe: Suggestion on C++ Pin
Michael Haephrati11-Oct-14 5:33
professionalMichael Haephrati11-Oct-14 5:33 
GeneralRe: Suggestion on C++ Pin
Member 1081309011-Oct-14 6:15
Member 1081309011-Oct-14 6:15 
GeneralRe: Suggestion on C++ Pin
Michael Haephrati11-Oct-14 7:11
professionalMichael Haephrati11-Oct-14 7:11 
GeneralRe: Suggestion on C++ Pin
jschell14-Oct-14 10:54
jschell14-Oct-14 10:54 
GeneralStrange Pin
Michael Haephrati11-Oct-14 3:05
professionalMichael Haephrati11-Oct-14 3:05 
GeneralRe: Strange Pin
Freak3012-Oct-14 23:42
Freak3012-Oct-14 23:42 
GeneralRe: Strange Pin
Michael Haephrati12-Oct-14 23:45
professionalMichael Haephrati12-Oct-14 23:45 
GeneralRe: Strange Pin
Stefan_Lang13-Oct-14 2:41
Stefan_Lang13-Oct-14 2:41 
QuestionMFC Ribbon Editor Pin
Richard Andrew x6410-Oct-14 9:30
professionalRichard Andrew x6410-Oct-14 9:30 
QuestionCListBox Header Pin
D.Manivelan10-Oct-14 3:08
D.Manivelan10-Oct-14 3:08 
AnswerRe: CListBox Header Pin
jeron110-Oct-14 6:57
jeron110-Oct-14 6:57 
QuestionUndeclared identifier in API Pin
piul9-Oct-14 4:00
piul9-Oct-14 4:00 
QuestionRe: Undeclared identifier in API Pin
CPallini9-Oct-14 4:17
mveCPallini9-Oct-14 4:17 
AnswerRe: Undeclared identifier in API Pin
piul9-Oct-14 5:01
piul9-Oct-14 5:01 
AnswerRe: Undeclared identifier in API Pin
Orjan Westin9-Oct-14 5:06
professionalOrjan Westin9-Oct-14 5:06 
GeneralRe: Undeclared identifier in API Pin
Freak309-Oct-14 22:28
Freak309-Oct-14 22:28 
GeneralRe: Undeclared identifier in API Pin
Orjan Westin9-Oct-14 23:02
professionalOrjan Westin9-Oct-14 23:02 
QuestionCOM Component Pin
john56329-Oct-14 1:45
john56329-Oct-14 1:45 
AnswerRe: COM Component Pin
«_Superman_»9-Oct-14 2:26
professional«_Superman_»9-Oct-14 2:26 
QuestionC++ MFC Dialog Password encryption Vs2005 [moved] Pin
WinterC7-Oct-14 20:16
WinterC7-Oct-14 20:16 
i have done my insertion code for the registration form but now i have to do password encryption after register which i totally have no idea on how to do it in C++ MFC dialog application. please help me if u have any source files. just encrypt the password part.

C#
UpdateData();

    MYSQL *ssock;
    ssock = (MYSQL *)malloc(sizeof(MYSQL));
    mysql_init(ssock);

    conn = mysql_init(NULL);

    if (conn == NULL) {
        printf("Error %u: %s\n", mysql_errno(conn), mysql_error(conn));
        exit(1);
    }

    if (mysql_real_connect(conn, "127.0.0.1", "root", "Root", "inomatic", 0, NULL, 0) == NULL)
    {
        printf("Error %u: %s\n", mysql_errno(conn), mysql_error(conn));
        exit(1);
    }

    int tmp = atoi((LPSTR)(LPCTSTR)m_Contact);

    if(m_Password != m_CfmPassword)
        {
        MessageBox("Both Password do not match! Please enter again.");
        m_EditPassword.SetFocus();
        }
    if(m_Username == "" || m_Password=="" || m_CfmPassword =="" || m_Email =="" || m_Contact =="" || m_Company == "")
        {
        MessageBox("Please fill in all the blanks.");
        }
    else if (m_Password == m_CfmPassword)
        {
                Insert(conn,(LPSTR)(LPCTSTR)m_Username,(LPSTR)(LPCTSTR)m_Password,(LPSTR)(LPCTSTR)m_Email,tmp,(LPSTR)(LPCTSTR)m_Company,"User");
                MessageBox("Thank You! You have successfully registed into People Counter Application.");
        }
    UpdateData(FALSE);
    mysql_close(conn);
    //Clear text after register ======================================================================================================================================
    m_EditUsername.SetSel(0,-1),m_EditPassword.SetSel(0,-1),m_EditCfmPassword.SetSel(0,-1),m_EditEmail.SetSel(0,-1),m_EditContact.SetSel(0,-1),m_EditCompany.SetSel(0,-1);
    m_EditUsername.Clear();
    m_EditPassword.Clear();
    m_EditCfmPassword.Clear();
    m_EditEmail.Clear();
    m_EditContact.Clear();
    m_EditCompany.Clear();

Winter


modified 8-Oct-14 9:09am.

GeneralRe: C++ MFC Dialog Password encryption Vs2005 Pin
Nelek8-Oct-14 0:08
protectorNelek8-Oct-14 0:08 
AnswerRe: C++ MFC Dialog Password encryption Vs2005 [moved] Pin
Richard MacCutchan8-Oct-14 4:16
mveRichard MacCutchan8-Oct-14 4:16 
RantDoes this line of code bother anyone? Pin
stgagnon7-Oct-14 11:29
stgagnon7-Oct-14 11:29 

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.