0

I have a Fortran file where at a certain point I have to write a command line into a batch file. This works well:

CHARACTER*260 TLINE1
. . .
TLINE1= 'c:\Programme\OriginLab\Origin2015\Origin92_64.exe'
. . .   
WRITE(4,'(1A260)')TLINE1

and in my Batch-File I get

c:\Programme\OriginLab\Origin2015\Origin92_64.exe

Now I want to add another Text. I want to have in my Batch-File this line:

start "" c:\Programme\OriginLab\Origin2015\Origin92_64.exe 

My problem now is that I cannot write the ""-characters into that line directly. I tried this but it won`t work:

CHARACTER*260 TLINE1
. . .   
TLINE1= 'start "" c:\Programme\OriginLab\Origin2015\Origin92_64.exe'
. . .
WRITE(4,'(1A260)')TLINE1

Do I have to wrap these characters somehow?

edit:

I tried:

TLINE1= 'start '"' c:\Programme\OriginLab\Origin2015\Origin92_64.exe'
TLINE1= 'start '""' c:\Programme\OriginLab\Origin2015\Origin92_64.exe'
TLINE1= 'start '"''"' c:\Programme\OriginLab\Origin2015\Origin92_64.exe'

but nothing worked. Fortran didn`t compile. Message: error#6054 A character data type is required in this context

I got the solution for my question:

  TLINE1= ' c:\Programme\OriginLab\Origin2015\Origin92_64.exe'
  T1A = 'start "" '
  TLINE2 = ' -c %TEMP%\amix'
  TLINEGES =trim(T1A)//trim(TLINE1)//trim(TLINE2)
user3443063
  • 1,455
  • 4
  • 23
  • 37

0 Answers0