1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Strange handling of a .BAT file

Discussion in 'Support' started by branch, Apr 28, 2010.

  1. branch

    Joined:
    Jul 26, 2008
    Messages:
    14
    Likes Received:
    0
    Hi Guys,
    Windows XP SP2 TCC 11.00.48
    I have a Windows application that calls a batch file. It is shelling to TCC.
    The .bat file is in d:\App\source. However when it runs the correct results do not occur. If I put a DIR into the .bat file it shows it is running in d:\

    If I run the .bat file under CMD it works fine.

    Any thoughts or suggestions appreciated.

    Regards,

    Ian
     
  2. roytam1

    Joined:
    Apr 1, 2010
    Messages:
    43
    Likes Received:
    0
    Please post the content of that batch file.
     
  3. branch

    Joined:
    Jul 26, 2008
    Messages:
    14
    Likes Received:
    0
    This is it in part. It just repeats for different .dpk files

    "C:\Program Files\Embarcadero\RAD Studio\7.0\bin\DCC32.EXE" esbpcs_base_dt_d14.dpk -B -N"d:\ESBPCS5\d14" -LE"d:\ESBPCS5\d14" -LN"d:\ESBPCS5\d14" -U"d:\ESBPCS5\d14" -$A+B-C-D-H+I-J-L-M-N+O+P+Q-R-S-T-U-V+W-X+Y-
    "C:\Program Files\Embarcadero\RAD Studio\7.0\bin\DCC32.EXE" esbpcs_base_db_rt_d14.dpk -B -N"d:\ESBPCS5\d14" -LE"d:\ESBPCS5\d14" -LN"d:\ESBPCS5\d14" -U"d:\ESBPCS5\d14" -$A+B-C-D-H+I-J-L-M-N+O+P+Q-R-S-T-U-V+W-X+Y-
    "C:\Program Files\Embarcadero\RAD Studio\7.0\bin\DCC32.EXE" esbpcs_base_db_dt_d14.dpk -B -N"d:\ESBPCS5\d14" -LE"d:\ESBPCS5\d14" -LN"d:\ESBPCS5\d14" -U"d:\ESBPCS5\d14" -$A+B-C-D-H+I-J-L-M-N+O+P+Q-R-S-T-U-V+W-X+Y-

    Ian
     
  4. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,859
    Likes Received:
    83
    Do you have a TCSTART file that is changing your current directory?

    Rex Conn
    JP Software
     
  5. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,952
    Likes Received:
    30
    On Wed, 28 Apr 2010 04:37:33 -0400, branch <> wrote:

    |Hi Guys,
    |Windows XP SP2 TCC 11.00.48
    |I have a Windows application that calls a batch file. It is shelling to TCC.
    |The .bat file is in d:\App\source. However when it runs the correct results do not occur. If I put a DIR into the .bat file it shows it is running in d:\
    |
    |If I run the .bat file under CMD it works fine.

    If an app runs TCC, TCC (when it starts) will have the current durectory
    specified by that app, the default being that app's own current directory.
    That's how Windows works. Where the batch file **is** doesn't matter at all.
    Either the app is telling TCC to start in d:\ or TCC is changing to d:\ after
    starting because of something in a TCSTART file.
    --
    - Vince
     
  6. branch

    Joined:
    Jul 26, 2008
    Messages:
    14
    Likes Received:
    0
     

Share This Page