User Tag List

Results 1 to 10 of 10

Thread: Directory and Filenames

  1. #1
    Clicker Fusion 2.5 Developer

    Join Date
    Aug 2006
    Location
    Colorado
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Directory and Filenames

    Hi all,

    I need some help. I want to continue to make my program better. It's basically a frontend for a DOS program. Now, up to know, it's been working well, but I wanted to add a new feature.

    So far, I'm stuck it seems.

    In the current version, the user can open up WAV files for converting them to a format known as ADX using a DOS-based encoder. Now, the way my frontend is set up is to run the encoder with this:

    adxencd.exe <path>\<filename>.wav <path>\<filename>.adx

    <path> is always the same as the source path. Say I open up a file called music1.wav in a folder called Music in the C: drive, this is what my frontend will send to the encoder:

    adxencd.exe C:\Music\music1.wav C:\Music\music1.adx

    For now, that's been working fine, but now I want to give the user the option to output to a new folder if they wish. That's what I'm having trouble with. Here's the deal:

    I want to be able to have a string with the <path> without the filename attached and THEN add the <filename> at the end, but I can't with either the Common Dialog Box Object or File Object. So, in turn, I want a string that shows this:

    <path> + "\" + <filename>

    Anyway I can isolate the file name and the path?

    Thanks in advance.

    Jesse~

  2. #2
    Clicker Fusion 2.5 Developer

    Join Date
    Aug 2006
    Location
    Colorado
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    So...no one can help me then? :/

    Jesse~

  3. #3
    Clickteam Clickteam

    Join Date
    Jun 2006
    Location
    California, USA
    Posts
    1,247
    Mentioned
    0 Post(s)
    Tagged
    1 Thread(s)

    Re: Directory and Filenames

    You can launch the File Object - Open directory selector. Use the source directory as the default. Once the user selects a directory and clicks OK you can poll the File Object for the File selector - Get resulting pathname. (which will be the one the user selected) This will be the full path including the drive. From there you can append + "\" + <filename>
    DT
    Special Projects Director

  4. #4
    Clicker Fusion 2.5 Developer

    Join Date
    Aug 2006
    Location
    Colorado
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    Yes, but my problem is that I don't want the user to have to type in the filename. I want them to be able to select the filename from the Open File Selector and then what I want the program to do is be able to seperate the path and the filename so I can have control over where the file being encoded goes to.

    Something so simple seems like a pain. :|

    Jesse~

  5. #5
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUnicode Add-onInstall Creator

    Join Date
    Jul 2006
    Posts
    1,018
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    Maybe you're looking for this...

    You can split the full path of a file with the File object:
    e.g. "C:\folder\file.exe"
    [color:#FF0000]-->[/color]
    DriveName$( "File", "C:\folder\file.exe") [color:#FF0000]-->[/color] C:
    DirectoryName$( "File", "C:\folder\file.exe") [color:#FF0000]-->[/color] \folder\
    FileName$( "File", "C:\folder\file.exe") [color:#FF0000]-->[/color] file
    ExtensionName$( "File", "C:\folder\file.exe") [color:#FF0000]-->[/color] .exe

  6. #6
    Clicker Fusion 2.5 Developer

    Join Date
    Aug 2006
    Location
    Colorado
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    I'll try that out when I'm done! Thanks for the info.

    Jesse~

  7. #7
    Clickteam Clickteam

    Join Date
    Jun 2006
    Location
    California, USA
    Posts
    1,247
    Mentioned
    0 Post(s)
    Tagged
    1 Thread(s)

    Re: Directory and Filenames

    Yes, just like Gustav reiterated.

    example here:
    www.skiosk-esd.com/clickteam/MMF2_examples/filenames.mfa
    DT
    Special Projects Director

  8. #8
    Clicker Fusion 2.5 Developer

    Join Date
    Aug 2006
    Location
    Colorado
    Posts
    79
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    You guys are awesome! That's JUST what I needed! Thanks so much for the information Gustav and for the file DT. This will help me out SO much!

    Jesse~

  9. #9
    Clickteam Clickteam

    Join Date
    Jun 2006
    Location
    California, USA
    Posts
    1,247
    Mentioned
    0 Post(s)
    Tagged
    1 Thread(s)

    Re: Directory and Filenames

    No problem. We all need help from time to time. Just remember, at some point someone who is new to MMF will be asking a question and...
    DT
    Special Projects Director

  10. #10
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUnicode Add-onInstall Creator

    Join Date
    Jul 2006
    Posts
    1,018
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Directory and Filenames

    You're welcome!

Similar Threads

  1. Directory
    By Janman in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 21st October 2009, 12:51 PM
  2. [Request] PAID - Short (8.3) and Long Filenames
    By Dines in forum Extension Development
    Replies: 10
    Last Post: 12th May 2009, 08:39 PM
  3. Directory Packer
    By Benicle in forum Multimedia Fusion 2 - Technical Support
    Replies: 8
    Last Post: 2nd November 2007, 07:16 AM
  4. UP Directory
    By 8u8n in forum Multimedia Fusion 2 - Technical Support
    Replies: 7
    Last Post: 22nd September 2007, 03:49 AM
  5. UP Directory
    By 8u8n in forum File Archive
    Replies: 2
    Last Post: 21st September 2007, 05:49 PM

Posting Permissions

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