"^" character in patient name

  • Hi,


    I have an ultrasound machine that for some reason adds carets "^" to the end of patient name (something like "I AM PATIENT^^^").

    I have an exportconverter in dicom.ini to convert received US studies to a pdf file in folders with date\patientname.pdf. To achieve this, I use a .bat file with parsed command line parameters to irfanview...

    Problem is, when PatientName has those "^" characters, the command line is broken because "^" gets a special command meaning in DOS...


    So the my question is, what is the easiest way to filter out those "^" characters in patient name? I have zero knowledge in lua scripting.. If the solution goes that way, a simple example could be a start for me...


    Thanks..

  • Thanks, Marcel, that changes the patient name exactly as expected.



    I have other steps to run after name is updated (create folders and run a .bat file with parameters) for pdf creation, like this:


    "ImportConverter1 = mkdir d:\ExamesJPG\%V0008,0020\%V0010,0010\ ; save jpg to d:\PDF\%V0008,0020\%V0010,0010\%V0008,0018.jpg ; system d:\iview.bat "d:\PDF\%V0008,0020\%V0010,0010\%V0008,0018.jpg" "/append=d:\ExamesJPG\%V0008,0020\%V0010,0010\%V0010,0010.pdf" "/cmdexit"


    The ImportConverter does not work anymore after the [lua] command.. So I guess I should create a file.lua with all those steps to make it work?

  • Hi,


    you add [lua] in the end of dicom.ini, and only the lua import converter there. Only use 0 (etc) as in ImportConverter0 once, either in lua or not.


    Marcel


    Great, it worked! Thanks for your help.. It was not clear to me that the files are processed first by the lua lines and then by the dicom.ini importcoverter.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!