Write text to a file: Difference between revisions
From NSIS Wiki
Jump to navigationJump to search
m (Added category links.) |
m (Adding new author and category links.) |
||
Line 1: | Line 1: | ||
{ | {{PageAuthor|rainmanp7}} | ||
== Description == | == Description == | ||
This example shows you how to write text to a new file. | This example shows you how to write text to a new file. | ||
Line 16: | Line 14: | ||
</highlight-nsis> | </highlight-nsis> | ||
[[ | [[Category:Code Examples]] |
Revision as of 14:11, 24 June 2005
Author: rainmanp7 (talk, contrib) |
Description
This example shows you how to write text to a new file.
The Script
FileOpen $9 apachesrvin.bat w ;Opens a Empty File an fills it FileWrite $9 "cd $INSTDIR\apache$\r$\n" FileWrite $9 "apache -n Apache -k install$\r$\n" FileWrite $9 "net start Apache$\r$\n" FileWrite $9 "exit$\r$\n" FileClose $9 ;Closes the empty file