Is that what you're putting in the condition, exactly? Because "filename.wav" is just a placeholder. You're supposed to replace it with the name of the file you want to play, and that file has to be in the same folder(or under) the folder the game is in. That's what "AppPath" means, the path to the location of the game's file.
Say, in your game folder, you have another folder called Sound Effects, and a sound called Jump that you want to play. Then you would have to say, "XAudio2: Autoplay file AppPath & "Sound Effects/jump.wav" " in order for it to work properly.
Let me know if you didn't quite get it, I'll try to reword it as best I can. Don't worry, though, it confused me when I first started using it, too.