Jump to content

Fileinstall


trids
 Share

Recommended Posts

This is the first time I'm using FileInstall .. so I might be doing something wrong. But here is my code, and it returns 0 but doesn't actually place the file B) Oh and I am running the compiled version of the script

;Get the destination form the user    
    $sPathDest = FileSelectFolder ("Destination for new MDB", "::{20D04FE0-3AEA-1069-A2D8-08002B30309D}", 1 )  ;open at MyComputer, 1 = allow "New Folder"
    if @error then
        exit  ;user pressed cancel
    endif
    
;If there is already a file there, then first get the go-ahead    
  ;??????????
  ;??????????
  ;??????????
  ;??????????
  ;??????????
  ;??????????
  ;??????????


;ok proceed!    
    $nRC = FileInstall("D:\Trids\Au3zip\Test.mdb",$sPathDest,1)
    
    Msgbox (4096 +32,"","$nRC=" & $nRC)
    
Exit

:whistle: Am I missing something?

Edit: NT4 sp6a + AU3 v 3.0.94.0

Edited by trids
Link to comment
Share on other sites

  • Developers

$nRC = FileInstall("D:\Trids\Au3zip\Test.mdb",$sPathDest,1)
You need to add te filename where you want to copy the file to behind the target directory..

$nRC = FileInstall("D:\Trids\Au3zip\Test.mdb",$sPathDest & "\Test.mdb",1)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Ick! :angry: .. sorry for the hassle!

I misread the helpfile: 0 actually means not cool B)

BTW, JdeB .. if I just append a "\" (with no destination filename) it also works..

$nRC = FileInstall("D:\Trids\Au3zip\Test.mdb",$sPathDest & "\",1)

.. Hmm . now THAT might be useful to put into the help topic :whistle:

Link to comment
Share on other sites

  • Developers

BTW, JdeB .. if I just append a "\" (with no destination filename) it also works..

.. Hmm . now THAT might be useful to put into the help topic  :whistle:

Learning new features/shortcuts everyday !! B)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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