---
name: "FtpAccess"
section: "3"
platform: "linux"
package: "ftplib-dev"
version: "3.1-1-9"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/FtpAccess"
---

# FtpAccess(3)

Open a file or directory on the remote system.

## NAME

FtpAccess - Open a file or directory on the remote system.

## SYNOPSIS

**#include \<ftplib.h\>**\

**int FtpAccess(const char \****path***, int** *typ***, int** *mode***,**

**netbuf \****nControl***, netbuf \*\****nData***);**

## PARAMETERS

- **path**

  Specifies the name of the remote file or directory to open.

- **typ**

  Specifies the type of transfer to be performed. FTPLIB\_DIR performs a terse directory. FTPLIB\_DIR\_VERBOSE performs a verbose directory. FTPLIB\_FILE\_READ opens a remote file for reading. FTPLIB\_FILE\_WRITE creates a remote file and readies it for writing.

- **mode**

  Specifies the transfer mode as FTPLIB\_ASCII or FTPLIB\_IMAGE.

- **nControl**

  A handle returned by FtpConnect().

- **nData**

  Specifies the address to store a pointer to the created data handle.

## DESCRIPTION

FtpAccess() opens a remote file or directory and returns a handle for the calling program to use to transfer data.

## RETURN VALUE

Returns 1 if successful or 0 on error.
