HOW TO PRINT FILE TO NOTEPAD IN GUI?
DEFINE VARIABLE ReturnCode AS INTEGER NO-UNDO.
PROCEDURE WinExec EXTERNAL "KERNEL32.DLL":
DEFINE INPUT PARAMETER ProgramName AS CHARACTER.
DEFINE INPUT PARAMETER VisualStyle AS LONG.
DEFINE RETURN PARAMETER StatusCode AS LONG.
END PROCEDURE.
/**************************************************/
/* NOTE: VisualStyle parameters are as follows: */
/* 1 = Normal */
/* 2 = Minimized */
/**************************************************/
RUN WinExec (INPUT "notepad c:log.txt", INPUT 1, OUTPUT ReturnCode).
IF ReturnCode >= 32 THEN
MESSAGE "Application was Started" VIEW-AS ALERT-BOX.
ELSE
MESSAGE "Application Failed" VIEW-AS ALERT-BOX.
/****************************************************/
/* RETURN CODE DESCRIPTION */
/* If the function is successful, the return value */
/* from WinExec identifies the instance of the */
/* loaded module. Otherwise, the return value is an */
/* error value between 0 and 32. */
/* */
/* 0 System was out of memory, executable */
/* file was corrupt, or relocations */
/* were invalid. */
/* 2 File was not found. */
/* 3 Path was not found. */
/* 5 Attempt was made to dynamically link */
/* to a task, or there was a sharing or */
/* network protection error. */
/* 6 Library required separate data */
/* segments for each task. */
/* 8 There was insufficient memory to */
/* start the application. */
/* 10 Windows version was incorrect. */
/* 11 Executable file was invalid. Either */
/* it was not a Windows application or */
/* there was an error in the .EXE image.*/
/* 12 Application was designed for a */
/* different operating system. */
/* 13 Application was designed for */
/* MS-DOS 4.0. */
/* 14 Type of executable file was unknown. */
/* 15 Attempt was made to load a real-mode */
/* application (developed for an earlier*/
/* version of Windows). */
/* 16 Attempt was made to load a second */
/* instance of an executable file */
/* containing multiple data segments */
/* that were not marked read-only. */
/* 19 Attempt was made to load a compressed*/
/* executable file. The file must be */
/* decompressed before it can be loaded.*/
/* 20 Dynamic link library (DLL) file was */
/* invalid. One of the DLLs required to*/
/* run this application was corrupt. */
/* 21 Application requies Microsoft */
/* Windows 32-Bit extensions. */
/****************************************************/
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/443058/viewspace-914010/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- How to set up printers for GUI?GUI
- WPF open image and print as pdf file
- How to build a jar file by mavenUIJARMaven
- How to Convert Class File to Java File Online?Java
- How to use Qt Designed Ui fileQTUI
- How to dynamically evaluate a tag within a java fileJava
- Oracle ASM How many allocation units per fileOracleASM
- How to read Oracle 10046 trace fileOracle
- How to copy a datafile from ASM to a file system not using RMANASM
- How to get the exact duration of an audio file in js All In OneJS
- How to serve uncommon file in WebDAV using IIS in Win ServerWebServer
- How To Configure The "/etc/hosts" File On Linux [ID 242490.1]Linux
- How to load multiple Spring bean configuration fileSpringBean
- JavaScript print()JavaScript
- js printJS
- PHP 列印函式之 print print_rPHP函式
- how to check unsolved conflicts file list in git merge?Git
- How to dynamically evaluate a tag within a java file?(上個發錯了,重發)Java
- print the result sqlSQL
- How To Restore 12cR1DB to New Host File System using RMAN(一)REST
- Python print函式用法,print 格式化輸出Python函式
- 字串函式 print ()字串函式
- python print 用法Python
- java-- Print流Java
- print基礎用法
- guiGUI
- notepad++ 批次操作
- [oradebug命令學習2]How to Use Oradebug to Get Trace File Name and Location
- Android KitKat Print框架Android框架
- pycharm print 加顏色PyCharm
- angular指令實戰-notepadAngular
- C# Main point of a NotePadC#AI
- Notepad++配置備份
- print 與 println 的區別
- unixODBC without the GUIGUI
- notepad怎麼寫pythonPython
- 高效的使用 Notepad++ 工具
- notepad++批量頭尾追加