Purpose: Open directory to obtain all files and subdirectories in it.
open-dir <path> dir-id <dir id> \
[ status <status> ]
Copied!
Prepare ("open") directory <path> for reading, i.e. to obtain all the files and subdirectories under <path>, which is either an absolute path to the directory or a path relative to the current working directory (which by default is the application home directory, see directories).
The result is <dir id> in "dir-id" clause (a directory stream variable), which is used in read-dir to obtain the contents of <path> (i.e. all the files and subdirectories), as well as in close-dir.
The <status> (in "status" clause) can be RIM_OKAY if <path> is ready for reading, or RIM_ERR_OPEN if cannot open <path> (in which case you can use "errno" clause in get-req to find the specific reason why).