Jump to content

How to create an empty File


 Share

Recommended Posts

Hi i need a fast way to create an empty file with autoit. Can anyone help me?

Thx for help

<{POST_SNAPBACK}>

Try

#include <File.au3>
$File="test1.txt"
_FileCreate ( $File )

Probably need latest Beta


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

ok thx it works ;)

but now i need the way to split a string

$file = "bla_twt_sdf_234234.txt"

$file2 = StringSplit($file,".txt")

$filename = $file2&".rdy"

_FileCreate($filename)

it doesnt works :P

<{POST_SNAPBACK}>

How's about

#include <File.au3>

$ext=".rdy"
$file="bla_twt_sdf_234234.txt"
$file1=StringTrimRight($file, 4)
$filename=$file1 & $ext
_FileCreate($filename)


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...