Rexx - charout



此函式用於一次向檔案寫入一個字元。檔名作為引數輸入到函式中。

語法

charout(filename) 

引數

  • filename − 這是需要將字元寫入到的檔名。

返回值

如果所有字元都成功寫入檔案,則此函式返回 0。如果函式失敗,則返回未能寫入檔案的字元數。

示例

/* Main program */ 
status = charout(Example.txt,E) 
status = charout(Example.txt,x) 
status = charout(Example.txt,a) 

執行上述程式時,字元“E”、“X”和“a”將新增到檔案 Example.txt 中。

rexx_functions_for_files.htm
廣告

© . All rights reserved.