Re: Directory Exists??

new topic     » goto parent     » topic index » view thread      » older message » newer message

The following is probably the simpleist and fastest method with native Euphoria
functions:

function directoryExists(sequence path)
sequence currentdir
integer status,void
	currentdir=current_dir()
	status=chdir(path)
	if status then
		void=chdir(currentdir)
	end if
	return status
end function


Tested with Windows but should also work on Linux.

A faster method is possible using the windows api function FindFirstFile() but
it is more complex.

Larry Miller

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu