Hi user483281,
You can let your NPAPI communicate to JavaScript via NPN_Invoke. NPN_Invoke will allow you to invoke a method on a given NPObject.
For example, you can construct your method NPN_GetStringIdentifier, and use that to execute a method in your popup.
You can refer to this article, on how to communicate back to JavaScript from NPAPI plugin. The example shown there is a simple console.debug("Hello from C++")
Update
I noticed you want to open the xml file right after. Did you save the XML file in the location of the extension folder?
C:\Users\[user]\AppData\Local\Google\Chrome\User Data\Default\Extensions\[extension_id]\[extension_version]
Then you can open it with chrome.extension.getURL([file]);
But, it would be great if you return the XML file and open it within the extension itself.