okoc_folder_browser

 

Description

Open dialog to select multiple folders and return their paths.

Syntax

int okoc_folder_browser(LPCSTR lpcszInitDir, StringArray* saFolders)

Parameters

lpcszInitDir
[input] a pointer to string that holds the initial directory.
saFolders
[output] a string array that holds all the selected folders' paths.

Return

Return the number of folders selected.

Examples

EX1

#include <okocUtils.h>

void       folder_browser_ex1()
{
        vector<string> vsFolders;
        int nRet = okoc_folder_browser("K:\\OriginPro91", &vsFolders);
        printf("%d folders selected!\n", nRet);
        for ( int ii = 0; ii < nRet; ii++ )
                printf("Folder%d: %s\n", ii + 1, vsFolders[ii]);
        return;
}

Remark

See Also

header to Include

origin.h, okocUtils.h

Reference