I saved the notes I played in Label and I want to play them again. No record. Please help me using blocks.
MyPiano_template_MS.aia (2.1 MB)
perhaps see
That's right, but I want to create a function that replays the order saved in the Label after pressing the key.
Try techniques discussed in
or
i go try now
just block adding please not add record button
i think i push the piano button and label has piano value so replay button click and
play piano value 0.5ms
Runtime Error
RuntimeError. Irritants: (The operation < cannot accept the arguments: , [1], [(DNote.wav ENote.wav FNote.wav)] Bad arguments to <)
Note: You will not see another error reported for 5 seconds. this is my poroject sir
MyPiano_template_MS01_copy.aia (2.1 MB)
Are you using iOS per any chance?
As far as I can understand from your source, you use the following comparison:
related to two filenames
You create a filename with these blocks:
the filename is then added to a list:
But the comparison "<" is a blue block, thus intended to be used with numbers and not strings.
I suggest that you make a cross-reference table between filenames and a list of numbers, something like:
noteAfilename.wav -> 1
noteBfilename.wav -> 2 etc.
To this purpose you can use the Dictionary blocks.
Best wishes.
You are missing the Length of List block in your comparison notesCNT vs notesLIST .
If notesCNT < Length of List (notesLIST)then ...
You are using App Inventor for ios. How do I know? Your error message is RuntimeError. Irritants: (The operation < cannot accept the arguments: , [1], [(DNote.wav ENote.wav FNote.wav)] Bad arguments to <)
ios Project error messages contain the key word Irritants.
Does your Project run in the emulator or on an Android device?