+ Reply to Thread
Results 1 to 6 of 6

VBA Userform Runtime Error 35788

  1. #1
    Registered User
    Join Date
    11-13-2018
    Location
    Mackay, Queensland, Australia
    MS-Off Ver
    2016
    Posts
    5

    VBA Userform Runtime Error 35788

    Hi All,

    I know this error has bee discussed before, but none of the solutions I have tries seemed to help.

    I am running into the "Runtime Error 35788 An error occurred in a call to the Windows Date and Time Picker control." when I close my my UserForm. However, it only occurs if I have not used the spin control or the lookup text box to change the entry the form is pointing to. It also occurs on close if I use the "Write Entry" button and don't cycle to another entry.
    I have tried:
    Please Login or Register  to view this content.
    in the close code to try and hide the error, but it still shows.

    File in question is attached below, everything else works as intended. Form in question is on the "Data" worksheet, accessed by the big command button.

    Thanks in advance for any advice,

    Erik
    Attached Files Attached Files

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482

    Re: VBA Userform Runtime Error 35788

    It looks like you are calling "readField" macro when you are exiting the userform, but is that code not used to populate the userform controls?

  3. #3
    Registered User
    Join Date
    11-13-2018
    Location
    Mackay, Queensland, Australia
    MS-Off Ver
    2016
    Posts
    5

    Re: VBA Userform Runtime Error 35788

    How is it calling the readField sub on close?

  4. #4
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482

    Re: VBA Userform Runtime Error 35788

    You could go to the code that kicks in when you close the userform.
    -
    elind21.jpg

  5. #5
    Forum Expert torachan's Avatar
    Join Date
    12-27-2012
    Location
    market harborough, england
    MS-Off Ver
    Excel 2010
    Posts
    4,304

    Re: VBA Userform Runtime Error 35788

    Replace > Private Sub txtDwgNo_Exit(ByVal Cancel As MSForms.ReturnBoolean) <
    With > Private Sub txtDwgNo_AfterUpdate() <

  6. #6
    Registered User
    Join Date
    11-13-2018
    Location
    Mackay, Queensland, Australia
    MS-Off Ver
    2016
    Posts
    5

    Re: VBA Userform Runtime Error 35788

    Thanks torachan and davesexcel, that solved the problem. I didn't see the AfterUpdate() event in the list when I looked, must not have scrolled far enough.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Date Time Picker : Error 35788
    By cosmoKen in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-15-2019, 07:46 AM
  2. Runtime Error VBA Userform
    By houthoofdmichael in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 01-11-2017, 09:25 PM
  3. [SOLVED] Userform VBA, textbox in a frame - runtime error 438
    By poolierob in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-13-2015, 12:09 PM
  4. Me.Hide Userform runtime error in Office 365??!!
    By Excel_Runner in forum Office 365
    Replies: 1
    Last Post: 09-07-2014, 05:23 PM
  5. [SOLVED] Runtime error on UserForm
    By DJvdW in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-06-2013, 10:16 AM
  6. Getting runtime error when sub executed through userform change rather than directly
    By drew.j.harrison in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 03-28-2013, 12:32 AM
  7. RunTime error with UserForm!.Show
    By j_Southern in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-03-2011, 09:42 AM

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