Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to verify if file exist an place the path on my curs
Message
From
06/06/2013 21:50:38
Neil Mc Donald
Cencom Systems P/L
The Sun, Australia
 
 
To
06/06/2013 18:31:45
Luis Santos
Biglevel-Soluções Informáticas, Lda
Portugal
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Desktop
Miscellaneous
Thread ID:
01575803
Message ID:
01575810
Views:
40
Hi,
EMPTY() & REPLACE are a database functions and won't work. Check out the low level file functions in help, like FOPEN() etc, you need to get a file handle first.

>Hello comunity
>
>I have write this code above, that is based on a cursor, also on my local computer on disk C: i create a folder "Imagens" where i put in my image "Vinhos.jpg", also i don´t understand why the field ImgMarca.u_imgMarca keep the following path : \\127.0.0.1\Imagens\vinhos.jpg.
>
>
>select ImgMarca && My cursor name
>scan
>ImagePath = ('\\127.0.0.1\imagens\')
>ImageName = alltrim(ImgMarca.campo)+'.jpg'
>
>
>if NOT empty(sys(2000,"ImagePath+ImageName"))
>   replace ImgMarca.u_imgMarca with alltrim(ImagePath+ImageName) 
>else
>   replace ImgMarca.u_imgMarca with ''
>endif
>endscan
>
>
>Someone could give me an Help, because i need to solve this problem quickly.
>
>Many thanks
>Luis Santos
Regards N Mc Donald
Previous
Reply
Map
View

Click here to load this message in the networking platform