Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Regular Contributor
Posts: 63
Registered: ‎06-08-2012
My Device: BlackBerry
My Carrier: BlackBerry

How to hidden a folder on webworks (develop for PlayBook)

I just create a folder and I want to hidden it.

 

Is it possible?

 

Thanks ^^

Retired
Posts: 1,382
Registered: ‎07-02-2009
My Device: BlackBerry Bold 9900
My Carrier: Bell

Re: How to hidden a folder on webworks (develop for PlayBook)

I don't believe this is possible.  The blackberry.io.dir.createDirectory() method only allows you to specify the path.

 

Digging into the code here:

C:\Program Files\Research In Motion\BlackBerry WebWorks SDK for TabletOS 2.2.0.5\bbwp\ext\blackberry.io.dir\src\Air\Directory\src\blackberry\io\dir

 

I see its simply calling into the createMethod from the flash.filesystem.File object, which is documented here:

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/filesystem/File.html#create...

 

 

Follow me on Twitter: @n_adam_stanley
-------------------------------------------------------------------------------------------------------------------------
Your app doesn't work? Use BlackBerry remote web inspector to find out why.
Developer
Developer
Posts: 607
Registered: ‎04-29-2011
My Device: PlayBook 16GB, BB10 LE Z10 (red)
My Carrier: none

Re: How to hidden a folder on webworks (develop for PlayBook)

The questions is, why hiding a folder and for whom? If you want to hide the folder to not beeing accessable try to add the folder in the applications app-directory. I think with the PlayBook APIs you can not access the folders of another app, isn't it or may I be wrong in this?


"Like" if you liked the post.
"Accept as Solution" if the post solves your question.
Developer
Posts: 142
Registered: ‎07-27-2011
My Device: Red Z10, 32GB PlayBook, Numerous Android/WP8/FirefoxOS/Other devices
My Carrier: T-Mobile

Re: How to hidden a folder on webworks (develop for PlayBook)

[ Edited ]

 A reason I can think of off the top of my head to create a hidden folder would be to prevent images within it to show up in the files application. 
I think Sacha did it in one of his betas of http://appworld.blackberry.com/webstore/content/109703/?lang=en, but that was in Qt.

Can you not just put a . in the folder name when you create it?

-----------------------------------------------------------------------------------------



Regular Contributor
Posts: 63
Registered: ‎06-08-2012
My Device: BlackBerry
My Carrier: BlackBerry

Re: How to hidden a folder on webworks (develop for PlayBook)

Hi,

Thanks your response.

 

I want to create a hide folder which save image

Because I want to avoid the case which everyone use my playbook and delete my image.

 

See your respone so we have other way to protect our folder!!

Regular Contributor
Posts: 81
Registered: ‎03-09-2012
My Device: PlayBook & Bold 9780
My Carrier: n/a

Re: How to hidden a folder on webworks (develop for PlayBook)

Put your stuff in the location returned by blackberry.io.dir.appDirs. That's the folder only accessible by your app.

See https://developer.blackberry.com/html5/apis/blackberry.io.dir.html

That should protect it from people sniffing around.

Also put a basic password on your PlayBook to prevent that.