[?]: i want to add audio to Wincc v6.0 objects

ProTool, WinCC flexible, WinCC, PP/OP/TP/TD/MP
ptruongtdh
Posts: 2
Joined: Wed Jun 08, 2011 3:04 am

[?]: i want to add audio to Wincc v6.0 objects

Post by ptruongtdh »

I'm working with Wincc, i want to add audio to objects.
When the sensors effect to the system then the light flashing turn on and audio.
But i've done light flashing and audio i cannot.
Someone help me about that.
thanks alot.
ptruongtdh
Posts: 2
Joined: Wed Jun 08, 2011 3:04 am

Re: [?]: i want to add audio to Wincc v6.0 objects

Post by ptruongtdh »

Nobody help me...??????? :(
hmi222
Posts: 6
Joined: Mon Mar 28, 2011 5:24 pm

Re: [?]: i want to add audio to Wincc v6.0 objects

Post by hmi222 »

yu can add a global script.
in this script yu can call the Windows API Function "Playsound" and replay a wav-file
from the Harddisk!
Yu have to include the Mmsystem.h 'cause Function is located in winmm.dll

After yu did that
yu call the script when yur sensor is on.

For the reference watch here:
http://msdn.microsoft.com/en-us/library ... s.85).aspx

Have fun!