Each folder also contains a patient specific file called "IMG.dcm" used as a template for the conversion. Patient specific metadata is inserted from the template into the newly created request.dcm file.
For an individual folder called "foldername" containing the "REF.jpg" file, and the template file "IMG.dcm", the following command line (including the spaces) will create a usable "request.dcm" file in the same folder:
Code: Select all
[i]img2dcm foldername\REF.jpg foldername\request.dcm -stf foldername\IMG.dcm -k "Ser iesDescription"=REQUEST -k "Modality"=OT -k "SeriesNumber"=200 -k "ImageNumber"= 1"[/i]
What I need to do is create a batch file to loop this command through every folder in the directory, all differently named but all containing the required files. It is crucial the newly created file be placed within its parent folder.
Any help would be greatly appreciated for what is a fairly daunting project for a someone without an IT or computing background.