Forum Discussion

msalvador's avatar
msalvador
Frequent Contributor
5 years ago
Solved

getActiveXObject couldn't close file

Hi guys, I'm using getActiveXObject to parse an xml file. This instruction is in a function, when I call this function twice, I have an error, I suppose because file is already open. So there is a...
  • msalvador's avatar
    msalvador
    5 years ago

    I got it, I found the bug.

    Original:

    function Get_Translate_Mgs_Static_File() // Get static file
    {
    if (Const_lib.Language== "it")
    return Get_Translate_Mgs_Static_File = "c:\\DL Console\\messages.it.xtb"
    else if (Const_lib.Language== "en_US")
    return Get_Translate_Mgs_Static_File = "c:\\DL Console\\messages.xtb"
    
    }
    


    Now work

     

    function Get_Translate_Mgs_Static_File() // Get static file
    {
    if (Const_lib.Language== "it")
    return  "c:\\DL Console\\messages.it.xtb"
    else if (Const_lib.Language== "en_US")
    return  "c:\\DL Console\\messages.xtb"
    
    }

    Tanks