+ Reply to Thread
Results 1 to 3 of 3

Date formatting in VBA WinXP / Win 7 errors

  1. #1
    Registered User
    Join Date
    04-22-2013
    Location
    Worthing, England
    MS-Off Ver
    Excel 2007
    Posts
    13

    Date formatting in VBA WinXP / Win 7 errors

    Hi all,
    i build a tracker using userforms in Windows 7 and it works fine but for some reason on windows XP machines its throwing up a compile error for this piece of code in the Userform_initilize
    Please Login or Register  to view this content.
    it specifically doesnt like the word "Date"

    and in another piece of similar code it doesnt like the word "format"
    Please Login or Register  to view this content.
    The specific error is "cant find project of library and it highlights the
    Please Login or Register  to view this content.
    or
    Please Login or Register  to view this content.
    I dont understand why its fine on Win 7 but not on XP,
    any suggestions?

    both are using Excel 2007

    taking out the format string and just using it as a value and it works fine on XP and win 7

    many thanks
    Last edited by danmarson; 05-10-2013 at 05:47 AM.

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Date formatting in VBA WinXP / Win 7 errors

    you have a missing reference. on the xp machine in the vbe click tools-references and look for a selected item marked 'MISSING:'

    you can resolve the problem by fixing the reference issue or bandaid it using VBA.Date and VBA.Format rather than just Date and Format
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Registered User
    Join Date
    04-22-2013
    Location
    Worthing, England
    MS-Off Ver
    Excel 2007
    Posts
    13

    Re: Date formatting in VBA WinXP / Win 7 errors

    perfect thank u that fixed it!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1