CrazyEngineers
  • sahana
    sahana

    MemberMar 6, 2007

    problem in visualc++

    hi to all.
    i want to get the caption of my button control during runtime i.e when i execute.can anyone help me with it.
    Replies
Howdy guest!
Dear guest, you must be logged-in to participate on CrazyEngineers. We would love to have you as a member of our community. Consider creating an account or login.
Replies
  • uday.bidkar

    MemberMar 7, 2007

    sahana
    hi to all.
    i want to get the caption of my button control during runtime i.e when i execute.can anyone help me with it.
    Use CWnd::GetDlgItem( /*Identifier of the Button control*/) to get CWnd* of the Button window. Call GetWindowText using this pointer to get Captin of the Button.
    Are you sure? This action cannot be undone.
    Cancel
  • sahana

    MemberMar 9, 2007

    thanks a ton uday,
    i now hav a new problem.now what do i do if i want to set the caption name during run time i.e during execution if i click a button i want its caption name to be changed
    Are you sure? This action cannot be undone.
    Cancel
  • uday.bidkar

    MemberMar 11, 2007

    sahana
    thanks a ton uday,
    i now hav a new problem.now what do i do if i want to set the caption name during run time i.e during execution if i click a button i want its caption name to be changed
    Follow the same procedure but call SetWindowText instead of GetWindowText
    Are you sure? This action cannot be undone.
    Cancel
Home Channels Search Login Register