Re: VB to read a file to work out what it really is by botters
botters
Thu Oct 12 08:07:40 CDT 2006
Ah sorry may not have explained well enough.
The Bitmap filename is image.jpg. if I change it to image.bmp then it
will work fine in photoshop but I need the Script to read the File and
work out that even though it ends with a jpg extension it is in fact
not one.
Any ideas?
Thanks
On Oct 12, 1:45 pm, "hempguy" <h...@guy.com> wrote:
> If LCase(Right([filename], 3)) <> "jpg" Then
> its not a jpg
> End If
>
> <bott...@gmail.com> wrote in messagenews:1160653378.187303.150660@h48g2000cwc.googlegroups.com...
>
>
>
> > Hi guys,
>
> > I am downloading a lot of jpg files from the web for a project the only
> > problem is sometimes they are bitmap files with the wrong file
> > extension. Windows appears to be cool with this however the script
> > loads them into photoshop which just makes the whole thing fall over.
>
> > Is there a way using windows scripting to check that a jpg is actually
> > that and if not to spit the file out and not process it.
>
> > Many thanks in advance.- Hide quoted text -- Show quoted text -