Add entire folder script to Module
Question

Hi,

I have specific javascript file that need to be loaded in my page. However, beside the script itself, it need some resources that should be placed in same path (like reference folder). Basically, i want to upload entire folder to my module.

I've try it to upload entire folder and file to other hosting, and use the url, it works. Is it possible to upload it to my module?

Thanks in advance

Solution

Finally i found a way, by type manually on target directory

The runtime path will follow the typed target directory. This way you create another folder or subfolder.
If there's any solution to import multiple files directly without one by one will be very helpful.

Hello Hendra,

If I understand right the issue, I think the best place is on "Resources" and set "Deploy to Target Directory".

Hope it helps,

Nuno R


Hi Nuno,

But i only able to add single file only that way. I need to include entire folder so my script can run.

All these folders need to be included. Is there any way to include all those files including the folders?

Hello Hendra,

You can drag and drop multiple files, but is not possible (yet, I created an idea: https://www.outsystems.com/ideas/11714/create-folders-on-resources-by-drag-and-drop/) to do the same with folders, you need to create them, them move the files to the root and them to the folder.

Hope it helps,

Nuno R

Hi 

You can refer below link to import the resources.

https://success.outsystems.com/Documentation/11/Developing_an_Application/Use_Data/Use_Resources

Thanks
Pankaj

Hi,

Outsystems only provide a way to include single file only, not entire folder. I need to add some folders so my script can run. All these folder and files need to be included


Hi Hendra Panggabean,

You can also create the folder inside the resources. You have to add files one by one manually.

Thanks
Pankaj

Hello Pankaj Jain,

It´ s not necessary one by one, you can drag and drop multiple files to the root and them move to the folder.

Maybe in the future OutSystems will allow to create folders also by drag and drop, I put the idea (https://www.outsystems.com/ideas/11714/create-folders-on-resources-by-drag-and-drop/).

Best Regards,

Nuno R

Hi Nuno,

Yes, it seems good idea. But looks like the folder i created is not detected by the system. The runtime path is not using my folder

It should be /MyModule/Script/tiff.js
And also adding sub folder inside folder is not allowed :(

Hello Hendra Panggabean,

You are right is not possible to add folders on folders, I will add that to my "idea".

I had a JS file to my personal area and I can access it:

https://personal-gxzlvs5j.outsystemscloud.com/JavascriptLibrary/test.js

Hope it helps,

Nuno R

Solution

Finally i found a way, by type manually on target directory

The runtime path will follow the typed target directory. This way you create another folder or subfolder.
If there's any solution to import multiple files directly without one by one will be very helpful.

Update:

Found old but useful tools to import multiple files
https://github.com/achinita/ImportResources

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.