|
잘되네요~ ^^정말 고맙습니다~
Lyn 님이 쓰신 글 :
: if (ContextSaveDialog->Execute()) //기본 filename = "a.txt"
: {
: AnsiString info = ContextSaveDialog->FileName;
: AnsiString str;
:
: str = "블라블라";
:
: FILE *file = fopen(info.c_str(),"wt");
: fwrite(str.c_str(),str.Length(),1,file);
: fclose(file);
: }
:
: 박진수 님이 쓰신 글 :
: : 파일을 저장하기 위해, 다이얼로그박스를 사용했습니다.
: :
: : ContextSaveDialog->Execute(); //기본 filename = "a.txt"
: :
: : AnsiString info = ContextSaveDialog->FileName;
: : AnsiString str;
: :
: : str = "블라블라";
: :
: : FILE *file = fopen(info.c_str(),"wt");
: : fwrite(str.c_str(),str.Length(),1,file);
: : fclose(file);
: :
: :
: : 이렇게 했거든요.
: :
: : 그런데 이게 취소를 눌러도 계속 저장이 됩니다.
: :
: : 그래서 다이얼로그박스에서 취소를 눌렀을때 함수를 빠져나가려고 하는데요.
: :
: : if문을 쓰면 될것 같은데 조건을 잘 모르겠네요.
: :
: : 조건을 좀 알려주세요~
|