Results 1 to 3 of 3

Thread: Launching a file

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Sep 2000
    Location
    England
    Posts
    94

    Launching a file

    Hey Guys

    Is there anyway (lol course theres a way). To launch a file for instance test.zip from c and get it to be opened by the default file viewer on the system.


    Cheers
    Peter
    "Let's all join forces, rule with an iron hand...and prove to all the world, metal rules the land..."
    -- Judas Priest

    My email is [email protected]

  2. #2

    Thread Starter
    Lively Member
    Join Date
    Sep 2000
    Location
    England
    Posts
    94
    I found how to do it if anyones interested

    ShellExecute

    look it up in msdn
    "Let's all join forces, rule with an iron hand...and prove to all the world, metal rules the land..."
    -- Judas Priest

    My email is [email protected]

  3. #3
    Frenzied Member Vlatko's Avatar
    Join Date
    Aug 2000
    Location
    Skopje, Macedonia
    Posts
    1,409
    It is not reccomended but you could also use this:
    WinExec
    The WinExec function runs the specified application.

    This function is provided for compatibility with 16-bit Windows. Win32-based applications should use the CreateProcess function.

    UINT WinExec(
    LPCSTR lpCmdLine, // address of command line
    UINT uCmdShow // window style for new application
    );
    I am become death, the destroyer of worlds.
    mail:[email protected]

    • Visual Basic 6.0 & .NET
    • Visual C++ 6.0 & .NET
    • ASP
    • LISP
    • PROLOG
    • C
    • Pascal

Posting Permissions

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



Click Here to Expand Forum to Full Width