Jump to content

Temp Dir UDF


DaProgrammer
 Share

Recommended Posts

;===============================================================================
;
; Function Name:    _CreateTempDir()
; Description:      Creates a temp folder.
;
; Requirement(s):   None.
; Return Value(s):  $TempDir - Full Path to the newly created Temp Directory
;
; Author(s):        KJ
;
;===============================================================================
Func _CreateTempDir()
    Local $string ,  $i
    For $i= 1 To 10
        $string &= Chr(Random(97, 122, 1))
    Next
    DirRemove(@TempDir & "\" & $string & "\",1)
    DirCreate(@TempDir & "\" & $string & "\")
    Return @TempDir & "\" & $string & "\"
EndFuncoÝ÷ Ù«­¢+Ù±½°
½¹ÍÐÀÌØíQµÁ¥Èô}
ÉÑQµÁ¥È ¤()¥±¥¹Íѱ° ÅÕ½ÐíèÀäÈí½Õµ¹Ñ̹MÑÑ¥¹ÌÀäÈí-(ÀäÈí5ä½Õµ¹ÑÌÀäÈíMÉ¥ÁÑÌÀäÈìĹ©ÁÅÕ½Ðì°ÀÌØíQµÁ¥È°Ä¤(¸¸¸(¸¸¸(¸¸¸)¥ÉIµ½Ù ÀÌØíѵÁ¥È°Ä¤

Edited by DaProgrammer
Link to comment
Share on other sites

Your function will not work ... you cannot use variables for the parameters of FileInstall(). Have you tested it? It may run as a script but it will not work compiled, which takes away the whole point of FileInstall() ...

Edited by Hallman
Link to comment
Share on other sites

  • Moderators

In fairness... he probably never compiled and ran it... it just does a filecopy then...

On the other hand, before releasing something, maybe you should rtm on the functions you are using, and test it in each of the stages :) (releasing things blindly no matter how small and obscure the script could cause more harm than good if you don't understand everything that actually goes on).

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

  • Moderators

Correct u all are :) my bad, it worked as script and i didn't compile so heres a new version. look at post 1.

http://www.autoitscript.com/forum/index.ph...c=34805&hl=

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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...