CTaskDialog::SetProgressBarPosition
진행률 표시줄의 위치를 조정 합니다.
void SetProgressBarPosition(
int nProgressPos
);
매개 변수
- [in] nProgressPos
진행률 표시줄에 위치 합니다.
설명
이 메서드는 예외를 throw 된 (MFC)를 확인 합니다. 매크로 경우 nProgressPos 진행률 표시줄 범위에 있지 않습니다.진행률 표시줄 범위를 변경할 수 있습니다 CTaskDialog::SetProgressBarRange.
예제
// TODO: Replace the strings below with the appropriate message,
// main instruction, and dialog title
CString message("This is an important message to the user.");
CString mainInstruction("Important!\nPlease read!");
CString title("Alert Dialog");
CTaskDialog taskDialog(message, mainInstruction, title,
TDCBF_YES_BUTTON | TDCBF_NO_BUTTON | TDCBF_CANCEL_BUTTON );
// Add a marquee progress bar.
taskDialog.SetProgressBarMarquee();
taskDialog.DoModal();
// Remove the marquee bar and replace it with a standard progress bar
taskDialog.SetProgressBarMarquee(0);
taskDialog.SetProgressBarRange(0, 100);
taskDialog.SetProgressBarPosition(75);
taskDialog.SetProgressBarState();
taskDialog.DoModal();
요구 사항
헤더: afxtaskdialog.h
참고 항목
참조
CTaskDialog::SetProgressBarMarquee