Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/.htaccess/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# VS 2013 Xact音频引擎文件未找到异常_C#_Audio_Monogame_Content Pipeline - Fatal编程技术网

C# VS 2013 Xact音频引擎文件未找到异常

C# VS 2013 Xact音频引擎文件未找到异常,c#,audio,monogame,content-pipeline,C#,Audio,Monogame,Content Pipeline,我正在尝试创建Windows monogame应用程序,其中我必须同时播放多个声音。当我发现一个解决方案正在使用时。然而,当涉及到音频引擎实例的创建时,它抛出File not found exception 在此代码行: audioEngine = new AudioEngine("Content/Audio/GameAudio.xgs"); 如何着手纠正此错误?愚蠢的问题时间:Content/Audio/GameAudio.xgs是否存在?它的完整路径是什么?但是我遵循的教程

我正在尝试创建Windows monogame应用程序,其中我必须同时播放多个声音。当我发现一个解决方案正在使用时。然而,当涉及到音频引擎实例的创建时,它抛出
File not found exception

在此代码行:

        audioEngine = new AudioEngine("Content/Audio/GameAudio.xgs");

如何着手纠正此错误?

愚蠢的问题时间:Content/Audio/GameAudio.xgs是否存在?它的完整路径是什么?但是我遵循的教程有相同的路径。。他们将音频文件夹放在内容文件夹中,并使用此路径。好的,我会尝试完整的路径:)@StephenKennedy:现在我给出的是:audioEngine=new audioEngine(“C:/Users/computer/documents/visual studio 2013/Projects/proj1/proj1/proj1.Windows/Content/Audio/GameAudio.xgs”);现在我得到了:mscorlib.dll中发生了“System.AggregateException”类型的异常,但未在user.dll中处理code@jincyabraham关于上面的注释,您需要了解一些关于在代码中提供路径的内容。路径应该是相对于源代码的,你真的希望它能工作吗?@HarikrishnanT:相对于源代码意味着什么?从当前工作目录类型?我就是这样试的。如果是这样,请查看上面给出的代码。这与本教程的方式完全相同——提供路径。愚蠢的问题时间:Content/Audio/GameAudio.xgs存在吗?它的完整路径是什么?但是我遵循的教程有相同的路径。。他们将音频文件夹放在内容文件夹中,并使用此路径。好的,我会尝试完整的路径:)@StephenKennedy:现在我给出的是:audioEngine=new audioEngine(“C:/Users/computer/documents/visual studio 2013/Projects/proj1/proj1/proj1.Windows/Content/Audio/GameAudio.xgs”);现在我得到了:mscorlib.dll中发生了“System.AggregateException”类型的异常,但未在user.dll中处理code@jincyabraham关于上面的注释,您需要了解一些关于在代码中提供路径的内容。路径应该是相对于源代码的,你真的希望它能工作吗?@HarikrishnanT:相对于源代码意味着什么?从当前工作目录类型?我就是这样试的。如果是这样,请查看上面给出的代码。这与本教程的方式完全相同——提供路径。