- Messages
- 1,068
- Country

I thought that I wrote this xml code properly but only the button and Tooltip work. There is no audio from the wav file. I have it in the dsd folder in SOUND in P3D V4.5 and the complete gauge is in the GAUGE folder. Here is the code:
I am also attaching the complete gauge folder so that it can be tested to see where I am making a mistake.
XML:
<Gauge Name="P2Toggle" Version="1.0">
<Element>
<Select>
<Value>(L:P2Toggle,bool)</Value>
<Case Value="0"><Image Name="P2OFF.bmp" Luminous="Yes" ImageSizes="27,27"/></Case>
<Case Value="1"><Image Name="P2ON.bmp" Luminous="Yes" ImageSizes="27,27"/></Case>
</Select>
</Element>
<Mouse>
<Cursor Type="Hand"/>
<Tooltip>%((L:P2Toggle,bool) 1 ==)%{if}P2 (ON)%{end}%((L:P2Toggle,bool) 0 ==)%{if}P2 (OFF)%{end}</Tooltip>
<Click>(L:P2Toggle, bool) ! (>L:P2Toggle, bool)</Click>
</Mouse>
<Element>
<Select>
<Value>
(L:P2Toggle,bool) 1 ==
(L:dsd_fsx_sound_id_09,number) 0 ==
and
if{
2 (>L:dsd_fsx_sound_id_09,number)
1 (>K:P2Toggle)
}
(L:P2Toggle,bool) 0 ==
(L:dsd_fsx_sound_id_09,number) 0 !=
and
if{
0 (>L:dsd_fsx_sound_id_09,number)
(>K:P2OFF)
0 (>K:P2Toggle)
}
</Value>
</Select>
</Element>
</Gauge>
I am also attaching the complete gauge folder so that it can be tested to see where I am making a mistake.


