[Python] Importing text file in DXL script?

Discussão em 'Python' iniciado por Stack, Março 11, 2025.

  1. Stack

    Stack Membro Participativo

    I am looking for a solution which helps to import a text file in the code, I am doing this to remove the hard coded values. Instead, I would want to call a text file and read values, which does the mapping. Making the code independent of projects. Any Idea how to do it ?

    OleAutoObj createWrapperObj(Object obj) {
    OleAutoArgs args = create
    OleAutoObj wrapper = null
    print oleMethod(d2e, "CreateObjectWrapper", args, wrapper)

    olePut(wrapper, "ModuleName", name(m))
    olePut(wrapper, "aObjectType", unicodeString(obj."aObjectType"))
    olePut(wrapper, "TestDescription", unicodeString(obj."Object Short Text"))
    olePut(wrapper, "TestPictureName", unicodeString(obj."ID"))
    olePut(wrapper, "TestFocus", unicodeString(obj."Test_Focus"))

    return wrapper }


    Thank you

    Continue reading...

Compartilhe esta Página