CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    May 2009
    Posts
    88

    regarding enabling of textbox

    well i wish to control the disabling of a edit box by user selecting from a set of option button that is a edit box placed front of that particular option button should be enabled if the user selects that option.......please tell me how can i do so.......the above controls are placed on a dialog box that is been called from the view.cpp.....................
    i have disabled the edit boxes initially by properties pane.......

  2. #2
    GCDEF is offline Elite Member Power Poster
    Join Date
    Nov 2003
    Location
    Florida
    Posts
    12,637

    Re: regarding enabling of textbox

    EnableWindow(TRUE);

  3. #3
    Join Date
    May 2009
    Posts
    88

    Re: regarding enabling of textbox

    sorry but how to use this??and where to use this??my control name is IDC_EDIT4 and variable associated is m_z

  4. #4
    Join Date
    Oct 2002
    Location
    Timisoara, Romania
    Posts
    14,360

    Re: regarding enabling of textbox

    If m_z is a control variable, then you can say:
    Code:
    m_z.EnableWindow(TRUE); // or FALSE
    On the other hand you can say:
    Code:
    CWnd* wnd = GetDlgItem(IDC_EDIT4);
    wnd->EnableWindow(TRUE); // or FALSE
    Marius Bancila
    Home Page
    My CodeGuru articles

    I do not offer technical support via PM or e-mail. Please use vbBulletin codes.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured