Help to create file path

How to create different download path like what’sApp like different file path like images, videos and documents and how to download in it or how to create file path.

Please elaborate more, I can’t understand your question.

you can easily do it using this extension

You need to make something like that:
set path variable to ( here you can use this daily challenge: it iwill generate random names.If you don’t want any letter, remove it from the letters list :

or you can use the math random number block ( numbers only))
So now you set the path var to a rundom path.( you can join this path with .png , .txt ,etc…So you define it’s type.
Now you will make a while loop to check that the generated file name doesn’t exist.Something like
While exists ( path var )
generate random path again as i’ve said earlier.
And then if u use the download component set savefileas property to the path variable.
Hope it helps :slightly_smiling_face:

What I do is to store number in TinyDB which increment by 1 for every download.
You can use 3 tags for image video and documents

1 Like

Or, you can do this
Set a variable to 0.
while test (Exists directory = join a + .png)
do { set a = a + 1}
// a will be a non exist file name.

@Mohamed_Tamer @Ansh_Anand @WatermelonIce
Are you sure that you are talking about the original topic?

With this extension you can download files to any directory of the external storage (except for the removable / micro SD card):

Example for downloading to a new folder (/myAudioFiles) of the ASD (app-specific dir):

The ExtendedDownloader.FolderName (directory) is automatically created.


Btw, this works without permissions.

1 Like

Oops :sweat_smile:

I know a method that you can first create an txt file with the specific directory using the file component. Then delete the txt file. You now have a directory that don’t have anything but only folders :slight_smile:

Yes, I know this and this only relevant for AI2, because in Kodular you can create a dir with the File component.

Btw, what has this to do with the original topic?

1 Like

The OP asked how to create folders…

Yes and …


I have created an app in that I have take the user upload pdf and the receiver have to download the pdf so as you share block first I have to create a file directory then When the download complete i have save like this :- /internalstorage/My app name/media/documents and then the pdf will save correct

So where is the problem?
And what is this path: /internalstorage/My app name/media/documents ?

1 Like

This topic has gone too long I already provided your solution at my previous post check it

This is the solution for what you want


Ok thanks.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.