Page 2 of 2 FirstFirst 12
Results 16 to 21 of 21
  1. #16
    daolix is offline Novice
    Windows 10 Access 2007
    Join Date
    Feb 2019
    Posts
    5
    Hi Colin,

    with "GDIP" I meant GDIPlus (gdi+) https://docs.microsoft.com/en-us/win...plus-gdi-start
    The following small subroutine reads out all properties that are available in the file and can be read out with WIA. But be careful, if binary data like thumbnails are present, it may get wild in the "direct area".



    Code:
    Sub WIA_TEST(ByVal sFile As String)
        Dim sn As String * 24
        Dim p As WIA.Property
        Dim v
        With New WIA.ImageFile
            .LoadFile sFile
            For Each p In .Properties
                sn = p.Name
                Debug.Print p.PropertyID, sn, p.Type, "ist Vector: "; p.IsVector,
                If p.IsVector Then
                    For Each v In p.Value
                        Debug.Print Format(v); ", ";
                    Next
                    Debug.Print
                Else
                    Debug.Print p.Value
                End If
            Next
        End With
    End Sub

  2. #17
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,016
    Wow!
    That was incredibly fast and does indeed provide a lot of information, not all of which I understand.
    For example, what do the numbers in ExifMakerNote , ChrominanceTable, LuminanceTable, 41988, 41989 etc mean.

    I'll attach a text file for the sample photo shown in my last post

    With regard to GPS data, Altitude and ImageDirection are shown as decimal numbers.
    However Latitude & Longitude are (I believe) shown as degrees, minutes, seconds.
    Is there a simple code tweak that will change that to decimals or do I need to just convert it?
    Also the Longitude should, in this case, be a negative value: -2.827569 but is shown as a positive number 2, 49, 39.25,
    I expect, apart from the - sign that is equivalent though I haven't yet checked
    Any way of handling that - sign issue automatically for both latitude & longitude?

    E£DIT:
    Also can you explain this line in your code

    Code:
    Dim sn As String * 24
    Attached Files Attached Files
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

  3. #18
    daolix is offline Novice
    Windows 10 Access 2007
    Join Date
    Feb 2019
    Posts
    5
    Here is a link with short explanations to the properties.
    Yes, I think you have to calculate the decimal numbers from the values degrees, minutes and seconds. For the sign you have to consider the properties "GpsLatitudeRef" and "GpsLongitudeRef", but I'm not sure.
    The properties that don't have a name are probably extensions of some programs, e.g. 40093, 40095 ... are fields that you can append with the Windows file manager.

    Dim sn As String * 24
    is only a string of fixed length so that following text is not indented differently because the property names have a different length.

  4. #19
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,016
    Thanks. Will read link later.

    Oops.
    Latitude W is of course negative so W together with e.g. 2+49/60+39.25/3600 is equivalent to -2.82756944444444
    Similarly longitude S would be negative

    So it definitely works though in this case, due to the minor additional computation, its not quite as convenient for me as my current code.
    However, if I want ALL the EXIF data including camera info + GPS info at the same time, this would definitely be a better approach.

    Coming back to your code....
    Code:
     "ist Vector: "; p.IsVector,
    What is the significance of whether it is a vector?
    Also am I correct in assuming you are German/Austrian?

    Thanks again
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

  5. #20
    DittoBird's Avatar
    DittoBird is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Apr 2015
    Location
    Newfoundland & Labrador, Canada
    Posts
    56
    Quote Originally Posted by isladogs View Post
    Thanks. Will read link later.

    Thanks again

    Colin, and daolix, I came back to mark the thread solved... I'll leave it open a while for you folks to talk about this. GPS is not important to me as all of our sites already have coordinates established, but I'm interested in seeing daolix's input.

  6. #21
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,016
    @daolix doesn't popup that often, but always provides completely new and valuable input whenever he/she does so.
    I always check out any code suggestions that @daolix provides! Certainly NOT a novice as his post count wrongly suggests
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

Page 2 of 2 FirstFirst 12
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 09-18-2020, 09:06 PM
  2. Replies: 5
    Last Post: 07-10-2020, 12:41 PM
  3. Replies: 6
    Last Post: 03-22-2018, 12:02 PM
  4. Replies: 1
    Last Post: 12-26-2016, 08:57 AM
  5. Replies: 3
    Last Post: 07-13-2015, 12:07 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums