POV-Ray : Newsgroups : povray.general : Check if a file is available Server Time
1 Aug 2024 10:14:58 EDT (-0400)
  Check if a file is available (Message 1 to 3 of 3)  
From: Matthias Weißer
Subject: Check if a file is available
Date: 29 Dec 2005 05:30:20
Message: <43b3babc$1@news.povray.org>
Hi

is it possible to check the availability of a file in SDL and then do a 
decision dependiong on the file is available or not. I tried

#fopen f1 "filename" read
#ifdef f1
#warning "file is open"
#end

but that gives me a parse error when "filename" is not available.

-- 

mat### [at] matweide
http://www.matwei.de


Post a reply to this message

From: Chris B
Subject: Re: Check if a file is available
Date: 29 Dec 2005 06:20:14
Message: <43b3c66e$1@news.povray.org>

news:43b3babc$1@news.povray.org...
> Hi
>
> is it possible to check the availability of a file in SDL and then do a 
> decision dependiong on the file is available or not. I tried
>
> #fopen f1 "filename" read
> #ifdef f1
> #warning "file is open"
> #end
>
> but that gives me a parse error when "filename" is not available.
>
> -- 

> mat### [at] matweide
> http://www.matwei.de

I think you want 'file_exists(S)' covered in '3.2.1.3.4  Functions'.

Regards,
Chris B.


Post a reply to this message

From: Matthias Weißer
Subject: Re: Check if a file is available
Date: 29 Dec 2005 08:04:11
Message: <43b3decb$1@news.povray.org>
Chris B schrieb:

> I think you want 'file_exists(S)' covered in '3.2.1.3.4  Functions'.

I think so too :-) Thanks a lot.

-- 

mat### [at] matweide
http://www.matwei.de


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.