SoundRecorder - Error 802 illegal character with android10

Hi my son is learning MIT app at the moment and he got this error messages everytime he clicked record, stoprecording and playrecording.
Can anyone help him please?

There is a bug in the current release that causes this due a space in the My Documents part of the default save path for the sound recorder.

You can work around this by setting the save path yourself, just save to the ASD.

You can get the ASD path like this:

1 Like

Thank you for your fast response. I did try to do that earlier but I could not find the procedures button “call file1 makeFullPath scope”.
Both of us are very beginner using MIT.
Please guide us.

Thank you

You will need a File component and a Clock for these blocks:

in companion mode this will set the sound recording path an filename to:

/storage/emulated/0/Android/data/edu.mit.appinventor.aicompanion3/files/sound_1632484835037.3gp
2 Likes

Yes, the full path does not work for the SoundRecorder. It must be an absolute path.
(And actually it should be a relative path):

https://community.appinventor.mit.edu/t/solved-web-component-not-saving-files-to-asd-in-companion/16851/8?u=anke

1 Like

The issue of spaces in the file name should be fixed on ai2-test.appinventor.mit.edu

2 Likes

Thank you for your suggestion, but still didn’t work.
I tried the test page and when I clicked the record and playrecording button, I still got error message 802 but for different thing.
Here is the error…

The directory you've given doesn't exist. Maybe you mistyped a character somewhere?

Yes, the folder / subfolder must first be created:

1 Like

grafik

If the property is empty the default path (btw, what is an appropriate location?) is set to a folder that does not exist (and is not created by the component).

I think this part should be removed:
grafik

You can set SavedRecordings to the ASD or to one of the
Shared folders:

/storage/emulated/0/Download/
/storage/emulated/0/Documents/
/storage/emulated/0/Music/

1 Like

Hmm. The directory should end up being created automatically. I'll have to look into that.

Hi. I too got the same error while making an audio recorder project. Whether this problem can be fixed by us?

This is my code!!

Yes, as I said, set the path manually (and this path must be an absolute path).

Sorry, I am unable to understand your suggestion. I don't know where to change the path. Can you please elaborate it!!

This is an example to save the recordings in the ASD:
soundRec.aia (2.9 KB)

Note: You must grant storage permission. This is of course a bug.

3 Likes

Thank you for your help!!!
Is there any other way to make a simple program for voice recorder?

What do you mean by that?

The program you have suggested looks large, whether we can make simple program for voice recorder without adding the path manually?

This is the least cumbersome method of doing it...

Is this simple enough?

2 Likes