Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 472

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112

Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/jerdew5/orbworks.com/forum/includes/bbcode.php on line 112
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3368: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3370: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3371: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3372: Cannot modify header information - headers already sent by (output started at /includes/bbcode.php:472)
OrbWorks Community Forum • View topic - VFS or a simple filebox?

VFS or a simple filebox?

Discuss OrbForms Designer and PocketC Architect

Postby RWB on Sun Nov 26, 2006 8:45 pm

Hi friends.Is there an easy way, to list the internal files, in a listbox?

ex: I have a button and a listbox.
When I push the button the internal files shall show up in the listbox.

I saw the vfs sample and it's great but, it's to advanced for my app.

Also.I just want the list to show my files.
Should I save my files like ,myfile.myf , to get , *.myf, files in the listbox?
:?::?:

RWB
RWB
RWB
 
Posts: 28
Joined: Fri Feb 10, 2006 12:43 pm
Location: Sweden

Postby FrankG on Tue Nov 28, 2006 8:04 pm

Yes - the internal files are much easier to list than VFS ones. Take a look at the sample code for DatabaseMgr objects in the help info. You can loop and get files using the dbenum method. dbenum returns the filename so you'd have to test it against a mask if you want to limit the list by name.

HTH,
Frank
FrankG
 
Posts: 210
Joined: Thu Jan 23, 2003 7:58 pm

Postby RWB on Wed Nov 29, 2006 3:29 pm

Thanks Frank,for the response but,
I struggle with this :(.
denum!,I read about this and tried some code but the lack of exampel in the manual is so frustrated.I can't get it to work!

Can You show me some code,please?

Best regards :(

RWB
RWB
RWB
 
Posts: 28
Joined: Fri Feb 10, 2006 12:43 pm
Location: Sweden

Postby sangahm on Wed Nov 29, 2006 3:41 pm

Did you see this in the helpfiles?

From: Contents > Library Reference > VFS > Directory object > enumerate


void listFiles(Volume vol) {
string name;
int attribs;
Directory dir;
bool first = true;

if (vol.openDir("/", dir) == 0) { // open the root directory
while (dir.enumerate(first, &name, &attribs)) {
first = false;
if ((attribs & vfsAttrDirectory) == 0) { // don't list directories
alert(name);
}
}
dir.close();
}
}
sangahm
 
Posts: 118
Joined: Mon Jul 04, 2005 3:43 pm
Location: USA

Postby FrankG on Wed Nov 29, 2006 3:53 pm

...and actually there are some code samples dealing with dbenum in this forum. Do a search on dbenum and see which code helps.

Frank
FrankG
 
Posts: 210
Joined: Thu Jan 23, 2003 7:58 pm

Postby RWB on Thu Nov 30, 2006 8:33 pm

Hi friends and thanks for the replies.

Yes I saw the code in the helpfiles and I paste it in to my main.oc but,
How do I call the function with my listbox?
I tried listFiles();//didn't work!

mylistbox.setitemslist(listFiles(Volume vol));//didn't work either!

I have a long way to go yet!

Please help :(

RWB
RWB
RWB
 
Posts: 28
Joined: Fri Feb 10, 2006 12:43 pm
Location: Sweden

Postby RWB on Wed Dec 27, 2006 3:18 pm

I solved my filebox issue like this.
A ulist with "last files used" instead.
so I can choose a file.
and it works great. :D

RWB
RWB
RWB
 
Posts: 28
Joined: Fri Feb 10, 2006 12:43 pm
Location: Sweden


Return to OrbForms Designer and PocketC Architect

Who is online

Users browsing this forum: No registered users and 1 guest