modifying filenamesyntax

  • Hi,


    Im trying to create a special filename syntax but run into difficullies, not being a programmer
    I wanted to save radiograph images by the name,sex,age,and birthday of the patients


    With the family name in UPPER CASE, first name in lower case, Middle initial in UPPER case and removing the caret used as space between
    in these the dicom.


    These will require lua programming? the name and age are the ones the seem to require those?


    Thanks for any help


    ajgg

  • Hi,


    The normal filenamesyntax provides most of the functionality, except splitting up the name. Lua filename generation can easily do this all but you will need to look into lua string processing to get this done. This is some template code.


    FileNameSyntax=lua:dofile('makefilename.lua')


    put this in file 'makefilename.lua'

    Code
    local n = Data.PatientName
    -- process n here
    return n .. Data.PatientSex .. Data.PatientAge .. Data.PatientBirthDate .. Data.SOPInstanceUID .. '.dcm'


    Marcel

Participate now!

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