Skip to main content

I have a Workspace that generates a .jpeg file with a named coordinate file. wld. Is there no way to generate the .jgw file or rename it to .jgw after translation?

Use the FeatureWriter transformer instead of the JPEG writer and follow the Summary port by a SystemCaller transformer to rename the file.


Use the FeatureWriter transformer instead of the JPEG writer and follow the Summary port by a SystemCaller transformer to rename the file.

@erik_jan, helped me a lot. This is way. But the systemcaller don't work properly. I use this command: C:\\Users\\Usuario\\Desktop\\teste /ren *.wld *.jgw, but nothing happens.

 


Try this command line:

ren C:\\Users\\Usuario\\Desktop\\teste\\*.wld *.jgw


Try this command line:

ren C:\\Users\\Usuario\\Desktop\\teste\\*.wld *.jgw

This is the help for the DOS RENAME command:

 

ren /?

 

Renames a file or files.RENAME [drive:][path]filename1 filename2.REN [drive:][path]filename1 filename2.Note that you cannot specify a new drive or path for your destination file.

 


If you need to rename a file using the SystemCaller, pass the whole thing below as the command line:

c:\windows\system32\cmd.exe /c "ren c:\temp\source_file.txt destination_file.txt"

You cannot use the "ren" command directly since it isn't an executable by itself, only a function defined inside the command line shell. This is not a limitation of FME, it's just how Windows is :-)


If you need to rename a file using the SystemCaller, pass the whole thing below as the command line:

c:\windows\system32\cmd.exe /c "ren c:\temp\source_file.txt destination_file.txt"

You cannot use the "ren" command directly since it isn't an executable by itself, only a function defined inside the command line shell. This is not a limitation of FME, it's just how Windows is :-)

Thanks @david_r, I did not know that.

 

Or create a batch file with this command line and call the batch file. In that case you do not need to call the cmd.exe

 


Thanks @david_r, I did not know that.

 

Or create a batch file with this command line and call the batch file. In that case you do not need to call the cmd.exe

 

Agree, that's also a good solution.

 


Thank you all, solved my problem.