Unfortunately the filenames of the resources are not included in the the exported exe. The Ide exporter and Runtime would have to be modified to include a list of the filenames, which doesn't look to easy to do. I looked into it when I was making the resource plugin.
Could you change the function you use to take the name of the resource as a parameter instead of the resource name? Then use a sub-event for each resource. That way you wouldn't have to worry about removing resources causing indexes to change.
<img src="http://dl.dropbox.com/u/5426011/pics/xaudio2.PNG" border="0" />