Reading image size?
Dear CE,I have tried to give a outline.You can modify it according to
need.
This code will prompt for a folder (Containing pictures).Select a
folder only.Then it will show you the Dimension of the pic.
Sub sd()
Dim sh As New Shell, fol As Shell32.Folder3
Dim FolPath As String, i As Long, PicNum As Long
With Application.FileDialog(msoFileDialogFolderPicker)
.AllowMultiSelect = True
.ButtonName = "Choose Folder"
.InitialView = msoFileDialogViewList
If .Show Then
Set fol = sh.Namespace(.SelectedItems(1))
PicNum = fol.Items.Count
For i = 1 To PicNum
MsgBox fol.GetDetailsOf(fol.Items.Item(i), 26)
Next i
End If
End With
End Sub
|