DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Mon, 23 Jul 2007 13:16:03 -0700,    posted on: microsoft.public.dotnet.scripting        back       

Thread Index
  1    WhatSayItAintSo
          2    Shay Levi
                 3    WhatSayItAintSo


How to test that a file ext is the same as the file type   
I need to test for the circumstance where someone has renamed a TIF file with 
a JPG extension.  I have to process large number of image files that are 
supposed all be JPG files. If I right-click on a file that is really a TIF, 
windows can show in the properties that it is a TIF even though it has a JPG 
extention. (In the properties window on the Summary tab under the Image node 
for File Type the value is “Tagged Information File Format (TIFF)”

My questions are:
1-	What is the technical term for this property? 
2-	How can I test for the condition where this property does not equal the 
file extension in the file name?

I am running simple dos commands and a thumbnailer product via command line. 
But I am open to more exotic methods.

Thanks in advance…
Date:Mon, 23 Jul 2007 13:16:03 -0700   Author:  

Re: How to test that a file ext is the same as the file type   
Check out James O'Neill's blog 
http://blogs.technet.com/jamesone/archive/2007/07/13/exploring-photographic-exif-data-using-powershell-of-course.aspx

or Scott Hanselman's 
http://www.hanselman.com/blog/AccessingEXIFPhotoDataFromJPEGsWithPowerShell.aspx


HTH

Shay
http://www.scriptolog.blogspot.com




> I need to test for the circumstance where someone has renamed a TIF
> file with a JPG extension.  I have to process large number of image
> files that are supposed all be JPG files. If I right-click on a file
> that is really a TIF, windows can show in the properties that it is a
> TIF even though it has a JPG extention. (In the properties window on
> the Summary tab under the Image node for File Type the value is
> Tagged Information File Format (TIFF)
> 
> My questions are:
> 1-	What is the technical term for this property?
> 2-	How can I test for the condition where this property does not equal
> the
> file extension in the file name?
> I am running simple dos commands and a thumbnailer product via command
> line. But I am open to more exotic methods.
> 
> Thanks in advance
> 
Date:Mon, 23 Jul 2007 20:46:40 +0000 (UTC)   Author:  

Re: How to test that a file ext is the same as the file type   
Thank you Shay,
EXIF is the term I was looking for and was guessing the powershell would be 
the method, but I lacked some key information which you have pointed me to.
again, thank you.

"Shay Levi" wrote:


> Check out James O'Neill's blog 
> http://blogs.technet.com/jamesone/archive/2007/07/13/exploring-photographic-exif-data-using-powershell-of-course.aspx
> 
> or Scott Hanselman's 
> http://www.hanselman.com/blog/AccessingEXIFPhotoDataFromJPEGsWithPowerShell.aspx
> 
> 
> HTH
> 
> Shay
> http://www.scriptolog.blogspot.com
> 
> 
> 
> > I need to test for the circumstance where someone has renamed a TIF
> > file with a JPG extension.  I have to process large number of image
> > files that are supposed all be JPG files. If I right-click on a file
> > that is really a TIF, windows can show in the properties that it is a
> > TIF even though it has a JPG extention. (In the properties window on
> > the Summary tab under the Image node for File Type the value is
> > “Tagged Information File Format (TIFF)”
> > 
> > My questions are:
> > 1-	What is the technical term for this property?
> > 2-	How can I test for the condition where this property does not equal
> > the
> > file extension in the file name?
> > I am running simple dos commands and a thumbnailer product via command
> > line. But I am open to more exotic methods.
> > 
> > Thanks in advance…
> > 
> 
> 
> 
Date:Mon, 23 Jul 2007 14:30:03 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us