Results 1 to 10 of 10

*.bat

This is a discussion on *.bat within the Tech Support forums, part of the Knight Online (ko4life.com) category; i have been wondering if there is a way to make a .bat (MS-DOS Batch File) play a *.wav file? ...
Page: 1


  1. #1
    Flay
    Guest

    Default

    i have been wondering if there is a way to make a .bat (MS-DOS Batch File) play a *.wav file?
    is there a code for it.

    And, is there a way to run a *.bat file in a webpage?

  2. #2
    Hypnos
    Guest

    Default

    i have been wondering if there is a way to make a .bat (MS-DOS Batch File) play a *.wav file?
    is there a code for it.[/b]
    If you know what the user uses to play .wav files, yes. Like this might work for WMP:
    Code:
    @echo off
    C:\Program Files\Windows Media Player\wmplayer.exe music.wav
    Of course, this is assuming C: is your drive.

    But I'm not sure why you would want a batch file for that. A shortcut would most likely work better, but I really don't know what you want this for.


    And, is there a way to run a *.bat file in a webpage?[/b]
    God no. That would be a huge security hole.

  3. #3
    Flay
    Guest

    Default

    God no. That would be a huge security hole.[/b]
    yeah i know, but i intend this to be for my own use, not really for other ppl.
    the thing u said about the .wav didnt really work. :S

    and, i dont really want to open media player or another player.
    ok how about this
    i know how to make a .exe program run a .wav file, is there a way i could run the batch file or convert the batch file code into c++ code?

  4. #4
    Protoss Arbiter Senior Member
    Join Date
    Mar 2006
    Location
    California
    Posts
    2,296

    Default

    yeah i know, but i intend this to be for my own use, not really for other ppl.
    the thing u said about the .wav didnt really work. :S[/b]
    ActiveX control.

  5. #5
    Flay
    Guest

    Default

    what?

  6. #6
    Hypnos
    Guest

    Default

    and, i dont really want to open media player or another player.
    ok how about this
    i know how to make a .exe program run a .wav file, is there a way i could run the batch file or convert the batch file code into c++ code?[/b]
    How exactly is it suppose to play if it won't be in a player? WAV files don't play themselves..

    C++? If you're trying to add music or sound to a C++ application, you're going about it a horrible way.

    system() is the function to execute a program in C++. You could put the batch lines in an array and run them through system() with a for each loop.


    Again, I have to ask what exactly you're trying to accoplish? What is this for exactly?

  7. #7
    Flay
    Guest

    Default

    telnet program >.<

  8. #8
    420 Senior Member karysa's Avatar
    Join Date
    Aug 2006
    Location
    LoVin the GanJa since '92
    Posts
    947

    Default

    He has a .bat file and wants it to play a .wav when a certain event happens. Try explaining what you&#39;re trying to do a little more clearly

  9. #9
    bazzeeka
    Guest

    Default

    Code in C++ get a tutorial from google . Its probly like just coding a wmp file on a website you can hide the player but the file will still play.

  10. #10
    Pwner4Last
    Guest

    Default

    shutdown -s

    oke ?

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
  •