Professional Web Applications Themes

Save Photos from CD To Hard Drive - Macromedia Director Basics

I have seen a CD where there is a catalog of photos, you can choose either hi-res or lo-res photos and click a "save" button. The windows Save dialoge comes up and I can save the photo to where I want it on my hard drive. Any ideas on how this was done in Director?...

  1. #1

    Default Save Photos from CD To Hard Drive

    I have seen a CD where there is a catalog of photos, you can choose either
    hi-res or lo-res photos and click a "save" button. The windows Save dialoge
    comes up and I can save the photo to where I want it on my hard drive.

    Any ideas on how this was done in Director?

    JP Heidi Guest

  2. #2

    Default Re: Save Photos from CD To Hard Drive

    You will need an Xtra to save out binary data to a file. Check out binaryIO at [url]www.updateStage.com[/url]
    Charles Parcell Guest

  3. #3

    Default Re: Save Photos from CD To Hard Drive

    The free FileXtra4 xtra can copy external files from the
    CD to a selected drive, using external image files is the inexpensive
    way out, the xtra could use the actual fileName property of a linked
    external member to locate the file.


    There is a commercial xtra that can export director images to a newly
    created file, should there be some special security reason not to use
    external files.
    JB Guest

  4. #4

    Default Save Photos from CD to Hard Drive

    My original question:

    I have seen a CD where there is a catalog of photos, you can choose either
    hi-res or lo-res photos and click a "save" button. The windows Save dialog
    comes up and I can choose where I want to save the photo to.

    JB Replied using fileXtra4 would do the trick, however:

    fx_FileCopy seems to copy to a pre-specified location (I want a
    user-interactive function)

    fx_FileSaveAsDialog gives me a user-interactive window so that I can save a
    file where I choose, but I am confused as to what file it is saving?

    Any other ideas? Thanks.

    JP Heidi Guest

  5. #5

    Default Re: Save Photos from CD to Hard Drive

    You should be able to accomplish the task using those 2 functions a
    little experimenting with sample code should get you on track.

    fx_FileSaveAsDialog should give you the full destination path for
    fx_FileCopy.


    I am not looking at FileXtra4 commands, in general you provide the
    default file name to fx_FileSaveAsDialog, the user can select the
    destination folder and optionaly rename the file in this dialog, then
    just provide fx_FileCopy the full path to the source file on the CD and
    the destination path given by fx_FileSaveAsDialog.

    To avoid the user renaming the file as it's copied one idealy would use
    a folder select dialog function, these are not commonly available in
    xtras, it's possible, using string manipulation to ignore the filename
    entered by user, replacing the end of the fx_FileSaveAsDialog returne
    path with the normal file name.
    JB Guest

  6. #6

    Default Re: Save Photos from CD to Hard Drive

    I am using this code:

    on mouseUp me
    fxObj = xtra("FileXtra4").new()
    folderPath = fxObj.fx_FolderSelectDialog("Select a folder to copy this file.
    This operation is cancelled without confirmation if an invalid path is
    selected.")
    if folderPath <> "" then
    result=baMsgBox("File will be copied to: "&folderpath, "Confirmation
    required..." , "OKCancel", "Information" , 1)
    if result="OK" then
    baCopyFileProgress( the moviePath & "Photos\Ralph\RALPH01.JPG" ,
    folderpath&"\RALPH01.JPG" , "always", "Copying file... ", "Cancel", 2 )
    end if
    end if
    fxObj = 0
    end

    and i am getting an object expected error when i build the exe, not before.
    was thinking the relitve path was wrong , but i think everything on that end
    is right...


    I have the exe file on the root
    then the other folders ie. Photos

    PLEASE HELP, and be easy with the explination. i am still new to all of this

    red2004 Guest

  7. #7

    Default Re: Save Photos from CD to Hard Drive

    I got this script from www.domaj.com -- another good forum:

    property filePath, toPath, theName, theTitle, overwrite

    on getPropertyDescriptionList me
    p_list = [:]
    addProp p_list, #filePath, [#format : #string, #default : the moviePath &
    "YourPhotoName.tif", #comment : "Base file-to-save path relative to the
    movie:"]
    addProp p_list, #toPath, [#format : #string, #default : "C:\", #comment :
    "Path to start from in save dialog:"]
    addProp p_list, #theName, [#format : #string, #default :
    "YourPhotoName.tif", #comment : "Name of file displayed in the dialog box:"]
    addProp p_list, #theTitle, [#format : #string, #default : "Save as:",
    #comment : "Text in the bar on the dialog box:"]
    addProp p_list, #overwrite, [#format : #boolean, #default : true, #comment :
    "Prompt before overwriting existing file (windows only)?:"]
    return p_list
    end

    on mouseUp me
    fxObj = new(xtra "FileXtra4")
    if the platForm contains "win" then
    theFile = fxObj.fx_FileSaveAsDialog(toPath, "YourPhotoName.tif", theTitle,
    overwrite)
    else
    theFile = fxObj.fx_FileSaveAsDialog(toPath, theName, theTitle)
    end if
    put fxObj.fx_FileCopy(the moviePath & "YourPhotoName.tif", theFile)
    fxObj = 0
    end

    JP Guest

Similar Threads

  1. Where is that hard drive?
    By Chuck in forum Ubuntu
    Replies: 4
    Last Post: February 5th, 07:08 AM
  2. Save Quiz scores on the users hard drive
    By dcort0 in forum Macromedia Flash Actionscript
    Replies: 7
    Last Post: March 4th, 07:00 PM
  3. save projector to hard drive
    By leanne827 webforumsuser@macromedia.com in forum Macromedia Director Lingo
    Replies: 1
    Last Post: July 28th, 04:43 PM
  4. [PHP] USB Hard Drive
    By Robert Cummings in forum PHP Development
    Replies: 0
    Last Post: July 23rd, 05:01 PM
  5. Replies: 7
    Last Post: July 13th, 03:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139