2.1.10.62 _getcwd


Description

get the current working path

Syntax

char * _getcwd( char * buffer, int maxlen )

Parameters

buffer
[output] Storage location for path to be returned by the function
maxlen
[input] Maximum length of path in characters

Return

returns a pointer to buffer. A NULL return value indicates an error.

Examples

EX1

void    getcwd_ex1()
{
    char        szcurDirectory[MAXFULLPATH];
    if ( _getcwd(szcurDirectory, MAXFULLPATH) != NULL )
    {
        out_str(szcurDirectory);
    }
}

Remark

Get the current working directory.

See Also

Header to Include

origin.h

Reference