# GetFirstFolder

## Description

Returns the name of the first folder found in the current folder, which is set using SetFolder. You can call GetNextFolder to continue down the list of folders in the current folder. Returns an empty string if there are no folders in the current folder. Does not include . or .. Note that there is a known limitation on Android that any folders within the "assets" folder cannot be found using this command. You may be able to work around this by using MakeFolder to create the same folder structure in the write folder which AGK can then use to find files in the assets folder with GetFirstFile.
By default this command will combine the folder lists from the read and write folders into a single list (mode=2) this can be changed to only return folders in the read folder (mode=0) or only return folders from the write folder (mode=1)

## Definition

string GetFirstFolder()

char* agk::GetFirstFolder()

string GetFirstFolder( mode )

char* agk::GetFirstFolder( int mode )

## Parameters

- mode - 0 to only return folders from the read folder, 1 to only return folders from the write folder, 2 for both (default)