cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Bottlefury
Regular Visitor

Struggling With audio files not playing properly

HI.  I have two Audio Controls - one plays a success noise, one a buzzer - they play depending on whether a record is found in a data table.  For some reason they will only play again once the other one has played.  So for example if it doesn't find a record it plays the buzz... but then if once again it doesn't find a record it wont play the buzz until a record has been found and it plays the beep.  I have in my start code this If(
!IsBlank(
LookUp(
Table1_1,
Column1 = varScan
).Column1
),
true,
false
)

 

Can anyone help?

 

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @Bottlefury ,

Make the Start a Variable (I will use varPlay here) - you need to trigger this from something - probably directly after you set varScan

If(
   !IsBlank(
      LookUp(
         Table1_1,
         Column1 = varScan
      ).Column1
   ),
   UpdateContext({varPlay: false});
   UpdateContext({varPlay: true})
)

As you can see, you need to reset the Variable for the Media Player to start.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

View solution in original post

3 REPLIES 3
WarrenBelz
Super User
Super User

Hi @Bottlefury ,

Make the Start a Variable (I will use varPlay here) - you need to trigger this from something - probably directly after you set varScan

If(
   !IsBlank(
      LookUp(
         Table1_1,
         Column1 = varScan
      ).Column1
   ),
   UpdateContext({varPlay: false});
   UpdateContext({varPlay: true})
)

As you can see, you need to reset the Variable for the Media Player to start.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

thanks for the tips...i've tried but it doesn't seem to play anything now

Bottlefury
Regular Visitor

sorry ignore me I was being an idiot. Your solution worked perfectly!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,901)