[haiku-development] Re: Using the Flatten() function

2009/7/29 Stephan Assmus <superstippi@xxxxxx>:
> Hi,
>
> On 2009-07-29 at 15:36:08 [+0200], Yashasvi A.C. <yashasviac@xxxxxxxxx>
> wrote:
>> I have written something like:
>> ****
>> file = BFile("..\", "..\MessageStore\", B_READ_WRITE);
>> ****
>>
>> I am passing the parent directory as the directory parameter, the
>> MessageFolder as the path and the open mode status.

I think the "parent" part is when you want to use a BDirectory. You
don't need that if your whole path is a string. So just use
BFile("../MessageStore", B_READ_WRITE). Also note our path separators
are /, not \, and if you want to use an \ in a string you have to
write \\ because \ is an escaping character, as in \n (newline) and \t
(tabulation).

Other related posts: