Thread: ShellExecute, strange !!

  1. #1
    Registered User
    Join Date
    Mar 2004

    Thumbs down ShellExecute, strange !!

    I dunno why, but today shellexecute works in a strange way..

    #include <stdio.h>
    #include <stdlib.h>
    #include <windows.h>
    int main(int argc, char *argv[])
      ShellExecute( NULL, "open", "calc.exe", "", "./", SW_SHOW );
      return 0;
    if i execute it, it popups a windows like if i want to save a file...
    have a loot to the atteached file..

    wha'ts going on ?

  2. #2
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Maybe it's the directory param that you are passing?

    try ShellExecute( NULL, "open", "calc.exe", "", NULL, SW_SHOW );

  3. #3
    Registered User
    Join Date
    Mar 2004
    thanx very much
    what should i write to say to the program : "work in the folder of the exe i've created!!"

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Strange results using dnsapi and windns
    By Niara in forum Networking/Device Communication
    Replies: 3
    Last Post: 08-13-2005, 10:21 AM
  2. ShellExecute() string problem
    By henrikstolpe in forum Windows Programming
    Replies: 2
    Last Post: 05-21-2003, 09:54 AM
  3. bcc32 compiling error (really strange!!)
    By jester in forum C++ Programming
    Replies: 14
    Last Post: 01-26-2002, 04:00 PM
  4. ShellExecute and popups or MessageSending
    By Unregistered in forum Windows Programming
    Replies: 0
    Last Post: 01-03-2002, 09:50 AM