View Single Post
 
Old 04-28-2020, 06:33 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,161
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

We can't see which line is failing so we can't tell you where the issue is but the error is saying the object doesn't exist.

To find your lost item, put your report into a MsgBox instead of using a text file that you need to go and read using more macros.

Add a command button to your form and then press F7 to create the macro for it. Paste the following code into that macro
Code:
  Dim ctlLoop As control, sMsg As String
  sMsg = "Name, Top, Left" & vbCr
  For Each ctlLoop In Me.Controls
    sMsg = sMsg & ctlLoop.Name & ", " & ctlLoop.Top & ", " & ctlLoop.Left & vbCr
  Next ctlLoop
  MsgBox sMsg
Then display the form and click that button. It will display a list of the controls on the userform and their top and left position values. This should include your missing item and what its coordinates are.
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote