Executing DOS commands from inside an image

This is a discussion on Executing DOS commands from inside an image within the C Programming forums, part of the General Programming Boards category; Hello all, Can I have DOS commands inside an image file, perhaps using C programming? Whenever the image is opened ...

  1. #1
    Registered User
    Join Date
    Jun 2006
    Posts
    130

    Executing DOS commands from inside an image

    Hello all,

    Can I have DOS commands inside an image file, perhaps using C programming?
    Whenever the image is opened the DOS commands are executed.

    FYI: I know that I can use system function to call DOS commands.




    Thanks

  2. #2
    Ex scientia vera
    Join Date
    Sep 2007
    Posts
    478
    No. That would require some way to exploit the image handling code, which, FYI, has actually been done, but that was patched.

  3. #3
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,211
    That seems like a rather odd thing to want to do.

  4. #4
    and the hat of sweating
    Join Date
    Aug 2007
    Location
    Toronto, ON
    Posts
    3,545
    Let me guess, you want to insert "format C:" into the image right?

  5. #5
    Registered User
    Join Date
    Jun 2006
    Posts
    130
    Well, I was looking for a way enabling me to execute .bat file when clicking on an image, i.e. appending .bat file underneath the image. I thought that I can do this using C programming, since I did not find any helpful tool

  6. #6
    Ex scientia vera
    Join Date
    Sep 2007
    Posts
    478
    Quote Originally Posted by Moony View Post
    Well, I was looking for a way enabling me to execute .bat file when clicking on an image, i.e. appending .bat file underneath the image. I thought that I can do this using C programming, since I did not find any helpful tool
    The reason for why you failed to find a 'helpful tool' to aid you in this task is simply that successfully doing what you're trying would break all laws of computing, granted that you were to do it without making something work in a way it wasn't intended to work.

    (NB: Please note that the "laws of computing" reference was only to enunciate the point. Please don't list the laws of computing and point out how I was wrong, and why. I will murder you if you do so.)

  7. #7
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,211
    Quote Originally Posted by Moony View Post
    Well, I was looking for a way enabling me to execute .bat file when clicking on an image, i.e. appending .bat file underneath the image. I thought that I can do this using C programming, since I did not find any helpful tool
    Probably because your request is bizarre.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Executing system commands cross platform
    By markucd in forum C++ Programming
    Replies: 6
    Last Post: 11-04-2005, 08:56 AM
  2. executing cmd.exe commands?
    By Dragoon_42 in forum C++ Programming
    Replies: 3
    Last Post: 11-03-2005, 12:22 PM
  3. File systems?? (Winxp -> DOS)
    By Shadow in forum Tech Board
    Replies: 4
    Last Post: 01-06-2003, 09:08 PM
  4. How to change a mouse cursor in console mode
    By GaPe in forum Windows Programming
    Replies: 10
    Last Post: 07-03-2002, 08:42 AM
  5. How-To: Load Pictures in MFC. Code Inside.
    By Xei in forum C++ Programming
    Replies: 1
    Last Post: 05-16-2002, 10:17 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21