How to create a text file in Apple Script?

`set theName to text returned of (display dialog "Please, enter name of your file:" default answer "" with icon note buttons {"Cancel", "Continue"} default button "Continue")

set New_script_path to "/Users/" & theUser & "/Library/Application Support/GD Saver/Scripts/" & theName & ".txt"

--I need to create a text file in New_script_path
Answered by makabaka1880 in 713661022
do shell script "touch " & New_script_path
Accepted Answer
do shell script "touch " & New_script_path
Accepted Answer

You can do this without shelling out:

set p to "/Users/quinn/test.txt"
set fd to open for access POSIX file p
close access fd

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

How to create a text file in Apple Script?
 
 
Q