English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Erlang file make_dir method

Files in Erlang

This method is used to create a new directory.

Syntax

make_dir(directory)

Parameter

  • directory −This is the name of the directory to be created.

Return Value

The status of the directory creation operation. If successful, an {Ok} message will be displayed.

-module(helloworld). 
-export([start/0]). 
start() -> 
   io:fwrite("~p~n",[file:make_dir("newdir")]).

will create a directory named newdir directory.

Files in Erlang