Question: Use of imported DLL

Hi,

I'm trying to get a hold of using DLL with Maple at the moment.

Just to give you some background informations.

My Headerfile:

[code]

#include
using namespade std;

namespace WAVEFUNC
{
          class
          {
          public:
                 static __declspec(dllexport) void play(string filename);
          };
}

[/code]

My Source Code:

[code]

#include
#include
#include
#include
#include "wave.h"
#pragma comment( lib, "winmm.lib" )

using namespace std;

namespace WAVEFUNC
{
    void WAVECLASS::play(string filename)
    {
        string pfadname2 = "D:\\Projekt\\";
        string pfadname = pfadname2 + filename;
        const char* pfadToConst = pfadname.c_str();
        if (!PlaySound(pfadToConst, 0, SND_FILENAME))
        {
            cout << "Der Sound konnte nicht abgespielt werden";
        }
    }
}

[/code]

Ok, thats it. My Goal is to simply play a .wav file inside Maple.

Out of these to codes i created a wave.dll.

Now i took these steps in Maple:

[code]

wave := define_external (

'play',

'filename'::(boolean[4]),

'lib' = "wave.dll");

[/code]

[code]

play(filename);

[/code]

Only answer from Maple is: play(filename) as i typed in.

 

So i need some suggestion what can or should i do as next step ?
Or did i make a big mistake somewhere above ?

Please Wait...