Sign in to follow this  
Followers 0
bobheart

@commonfilesdir C: Drive ?

14 posts in this topic

#1 ·  Posted (edited)

Is this @CommonFilesDir c drive ?

And what was the code again (i saw it here someplace I swear but I can't find it now ) that can run note pad and open a txt file at the same time ?

Edited by bobheart

Share this post


Link to post
Share on other sites



ok, I thought I'd be clever and write a script that let us put in a @marco and see what it points to:

$var = InputBox("what's it do?", "type or paste the macro or variable you're wondering about","@CommonFilesDir")
MsgBox(0,"what is it?","the variable you wonder about points to: " & @CRLF & $var)
but that doesn't work, I don't know if it's possible or not, hopefully someone smarter will come along and make that work, 'casue it'd be cool to follow it with jumping to the helpfile for whatever you put in (like f1 in SciTE)

to see what @CommonFilesDir points to on your machine, run this snipit of code:

MsgBox(0,"what is it?","@CommonFilesDir about points to: " & @CRLF & @CommonFilesDir)

it points to C:\Program Files\Common Files on my pc.

*whew* how's that for answering the long way?


"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Looks like the same for me .

---------------------------
what is it?
---------------------------
@CommonFilesDir about points to: 

C:\Program Files\Common Files

But I got it to work like this .

FileCopy(@WindowsDir & "\system.ini", "E:\New Folder\*.*")
FileCopy(@WindowsDir & "\control.ini", "E:\New Folder\*.*")
FileCopy(@WindowsDir & "\WIN.INI", "E:\New Folder\*.*")
FileCopy(@WindowsDir & "\CONFIG.SYS", "E:\New Folder\*.*")
FileCopy("C:\*AUTOEXEC.BAT", "E:\New Folder\*.*")
FileCopy("C:\*MSDOS.SYS", "E:\New Folder\*.*")
FileCopy("C:\*AUTOEXEC.DOS", "E:\New Folder\*.*")

Kind of ulgy huh . lol

Edited by bobheart

Share this post


Link to post
Share on other sites

Kind of ulgy huh . lol

I wouldn't call it ugly, it does the job, that's what counts.

"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
Share on other sites

It works great but not sure how to do the restore with it . the dos bat was easy ..

Share this post


Link to post
Share on other sites

just copy the files back? wouldn't that be it?


"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
Share on other sites

Ya I guess I gould do it with the

FileCopy("C:\*AUTOEXEC.BAT", "E:\New Folder\*.*") and reverse it .

Share this post


Link to post
Share on other sites

yeah, just do it like this:

FileCopy("e:\new folder\AUTOEXEC.BAT", "c:\*.*")


"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
Share on other sites

ok, I thought I'd be clever and write a script that let us put in a @marco and see what it points to .... but that doesn't work, I don't know if it's possible or not, hopefully someone smarter will come along and make that work,

Note the best way, but easy to make from the AutoIt text editor syntax files and via regular expressions:

$AppDataCommonDir =  @AppDataCommonDir
$AppDataDir =  @AppDataDir
$AutoItVersion =  @AutoItVersion
$CommonFilesDir =  @CommonFilesDir
$Compiled =  @Compiled
$ComputerName =  @ComputerName
$ComSpec =  @ComSpec
$CR =  @CR
$CRLF =  @CRLF
$DesktopCommonDir =  @DesktopCommonDir
$DesktopDir =  @DesktopDir
$DesktopHeight =  @DesktopHeight
$DesktopWidth =  @DesktopWidth
$DocumentsCommonDir =  @DocumentsCommonDir
$error =  @error
$FavoritesCommonDir =  @FavoritesCommonDir
$FavoritesDir =  @FavoritesDir
$HomeDrive =  @HomeDrive
$HomePath =  @HomePath
$HomeShare =  @HomeShare
$HOUR =  @HOUR
$IPAddress1 =  @IPAddress1
$IPAddress2 =  @IPAddress2
$IPAddress3 =  @IPAddress3
$IPAddress4 =  @IPAddress4
$LF =  @LF
$LogonDNSDomain =  @LogonDNSDomain
$LogonDomain =  @LogonDomain
$LogonServer =  @LogonServer
$MDAY =  @MDAY
$MIN =  @MIN
$MON =  @MON
$MyDocumentsDir =  @MyDocumentsDir
$OSBuild =  @OSBuild
$OSLang =  @OSLang
$OSServicePack =  @OSServicePack
$OSTYPE =  @OSTYPE
$OSVersion =  @OSVersion
$ProgramFilesDir =  @ProgramFilesDir
$ProgramsCommonDir =  @ProgramsCommonDir
$ProgramsDir =  @ProgramsDir
$ScriptDir =  @ScriptDir
$ScriptFullPath =  @ScriptFullPath
$ScriptName =  @ScriptName
$SEC =  @SEC
$StartMenuCommonDir =  @StartMenuCommonDir
$StartMenuDir =  @StartMenuDir
$StartupCommonDir =  @StartupCommonDir
$StartupDir =  @StartupDir
$SW_HIDE =  @SW_HIDE
$SW_MAXIMIZE =  @SW_MAXIMIZE
$SW_MINIMIZE =  @SW_MINIMIZE
$SW_RESTORE =  @SW_RESTORE
$SW_SHOW =  @SW_SHOW
$SystemDir =  @SystemDir
$TAB =  @TAB
$TempDir =  @TempDir
$UserProfileDir =  @UserProfileDir
$UserName =  @UserName
$WDAY =  @WDAY
$WindowsDir =  @WindowsDir
$WorkingDir =  @WorkingDir
$YDAY =  @YDAY
$YEAR = @YEAR

While 1
   $input = InputBox("what's it do?", "type or paste the macro or variable you're wondering about","@CommonFilesDir")
   If @error = 1 Then Exit ;user clicked Cancel or closed the window
   $result = Eval( StringReplace($input, '@', '') )
   If @error Then
         MsgBox(4096,"Error","Macro " & $input &  " was not found.")
      Else
         MsgBox(4096,"Macro", $input & " = " & $result)
      EndIf
WEnd

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

Share this post


Link to post
Share on other sites

Wow what is all that may I ask . I see some I know what it is for .

I guess I need to read somemore. lol

Share this post


Link to post
Share on other sites

Note the best way, but easy to make from the AutoIt text editor syntax files and via regular expressions:

wow, ask and ye shall recieve... works great... next to make it launch the helpfile... should be able to figure that out...

"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
Share on other sites

Wow I just ran it , thats cooooooool ..

Share this post


Link to post
Share on other sites

cool, will check that out, was just looking at the settings for scite's au3 configs to figure it out.


"I'm not even supposed to be here today!" -Dante (Hicks)

Share this post


Link to post
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
Sign in to follow this  
Followers 0