发布于 2011-09-15 20:16:48
1楼
为什么非要用vb呢?c也是一样的,方法不是目的,结果才是目的
#include "apdefap.h"
int gscAction( void )
{
#pragma code("Winmm.dll")
void WINAPI PlaySoundA(char* pszSound ,char* hmode,DWORD dwFlag);
#pragma code()
DWORD A1,A2,A3,A4,A5,A6,A7;
DWORD B1,B2,B3,B4,B5,B6,B7;
A1=GetTagDWord("YQ_ALARM_1");
A2=GetTagDWord("YQ_ALARM_2");
A3=GetTagDWord("YQ_ALARM_3");
A4=GetTagDWord("YQ_ALARM_4");
A5=GetTagDWord("YQ_ALARM_5");
A6=GetTagDWord("YQ_ALARM_6");
A7=GetTagDWord("COMM_ALARM");
B1=GetTagDWord("YQ_ALARM_SAVE_1");
B2=GetTagDWord("YQ_ALARM_SAVE_2");
B3=GetTagDWord("YQ_ALARM_SAVE_3");
B4=GetTagDWord("YQ_ALARM_SAVE_4");
B5=GetTagDWord("YQ_ALARM_SAVE_5");
B6=GetTagDWord("YQ_ALARM_SAVE_6");
B7=GetTagDWord("COMM_ALARM_SAVE");
if(
((A1^B1)&A1)
((A2^B2)&A2)
((A3^B3)&A3)
((A4^B4)&A4)
((A5^B5)&A5)
((A6^B6)&A6)
((A7^B7)&A7)
)
SetTagBit("yq_alarm_out",1);
if (GetTagBit("yq_alarm_out"))
PlaySoundA("c:\\winnt\\Media\\chord.wav",NULL,1);
SetTagDWord("YQ_ALARM_SAVE_1",A1);
SetTagDWord("YQ_ALARM_SAVE_2",A2);
SetTagDWord("YQ_ALARM_SAVE_3",A3);
SetTagDWord("YQ_ALARM_SAVE_4",A4);
SetTagDWord("YQ_ALARM_SAVE_5",A5);
SetTagDWord("YQ_ALARM_SAVE_6",A6);
SetTagDWord("COMM_ALARM_SAVE",A7);
return 0;
}
活到老,学到老!为了生活学习吧!