- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Hi
I have two doubts:
1-Depending on the value of a variable I want to change the caption of a QWIN dialog ( before calling DLGMODAL for sure).
DLGSET(DLG,IDD_DIALOGX,DLG_TITLE,..) did not work.
How to do it?
2- In an old console program I created a progress bar (thanks to Jugoslav's ThreadDlg ), and some messagebox (instead of using write(6,*)).
I want to minimize the black console window. How to do it?
Rebuilding as a qwin project, the framewindow could be miinimized, but I would like to know if and how it can be done in a console app.
I know in a pure windows project the same could be done, but not by me,at least in near future.
Thanks
Geraldo
I have two doubts:
1-Depending on the value of a variable I want to change the caption of a QWIN dialog ( before calling DLGMODAL for sure).
DLGSET(DLG,IDD_DIALOGX,DLG_TITLE,..) did not work.
How to do it?
2- In an old console program I created a progress bar (thanks to Jugoslav's ThreadDlg ), and some messagebox (instead of using write(6,*)).
I want to minimize the black console window. How to do it?
Rebuilding as a qwin project, the framewindow could be miinimized, but I would like to know if and how it can be done in a console app.
I know in a pure windows project the same could be done, but not by me,at least in near future.
Thanks
Geraldo
링크가 복사됨
5 응답
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
1) There's separate DlgSetTitle routine. I think the way you wrote it is actually far more consistent with other DFLOGM interfaces, but it doesn't work :-(.
2) Don't be so affraid of Windows applications. If you replace PROGRAM...END PROGRAM statements with INTEGER FUNCTION WinMain(blah, blah... END FUNCTION and recompile as Fortran Windows Application, any existing dialog-based or console application will work (but won't produce console window or output to it). You just have to be careful not to perform a WRITE(*, -- it will cause a crash; you have to either comment it out or redirect to a file. It doesn't have to have any RegisterClass, CreateWindow or GetMessage thingo -- plain number crunching or DlgModal works (just don't fall into trap of letting AppWizard generate the code for you).
Minimizing/hiding console window is a bigger pain than replacing PROGRAM with WinMain. You'd have to find the console window by its title using FindWindow API, then ShowWindow(SW_MINIMIZE or SW_HIDE) on it.
Jugoslav
2) Don't be so affraid of Windows applications. If you replace PROGRAM...END PROGRAM statements with INTEGER FUNCTION WinMain(blah, blah... END FUNCTION and recompile as Fortran Windows Application, any existing dialog-based or console application will work (but won't produce console window or output to it). You just have to be careful not to perform a WRITE(*, -- it will cause a crash; you have to either comment it out or redirect to a file. It doesn't have to have any RegisterClass, CreateWindow or GetMessage thingo -- plain number crunching or DlgModal works (just don't fall into trap of letting AppWizard generate the code for you).
Minimizing/hiding console window is a bigger pain than replacing PROGRAM with WinMain. You'd have to find the console window by its title using FindWindow API, then ShowWindow(SW_MINIMIZE or SW_HIDE) on it.
Jugoslav
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Jugoslav
Norman Lawrence's Guide to Win App helped me a lot in Qwin app, but full Win App seemed toooo complicated. Will try the bare win project you suggested.
Thanks for the tips.
Norman Lawrence's Guide to Win App helped me a lot in Qwin app, but full Win App seemed toooo complicated. Will try the bare win project you suggested.
Thanks for the tips.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Everything worked ok.
The blah.. blah I toke from a Steve Lionel reply.
As I could not find how to change the project type from Console to Windows Application I had to create a new project with another name. Is it possible to change the project type so the .exe keeps the same name?
Thanks
Geraldo
The blah.. blah I toke from a Steve Lionel reply.
As I could not find how to change the project type from Console to Windows Application I had to create a new project with another name. Is it possible to change the project type so the .exe keeps the same name?
Thanks
Geraldo
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I think it's enough to change /subsystem:console to /subsystem:windows on Project/Settings/Link tab (you have to retype it, there's no dialog control for it).
Jugoslav
Jugoslav
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
The change you suggested worked ok.
Thanks. You are the real on line help for CVF.
Geraldo
Thanks. You are the real on line help for CVF.
Geraldo