troubleshooting Question

Problem With Access 2016 CreateObject for Excel

Avatar of Bob Collison
Bob CollisonFlag for Canada asked on
VBA* Access
9 Comments1 Solution18 ViewsLast Modified:
Hi Experts,

I have the following code that used to work perfectly.

No I get Error 429.

'Step 110-Prepare MS Excel Application Common Variables.
Dim DebugErrorNumber110 As Integer
DebugErrorNumber110 = 0
Dim EmptyMSExcelFileFlag_110 As Boolean
EmptyMSExcelFileFlag_110 = False
Dim MSExcelApplication_110 As Object
On Error Resume Next
Set MSExcelApplication_110 = GetObject(, "Excel.Application")
DebugErrorNumber110 = Err.Number
If Err.Number <> 0 Then
   Set MSExcelApplication_110 = CreateObject("Excel.Application")
   EmptyMSExcelFileFlag_110 = True
   GoTo STEP_120   'Step 120-Define MS Excel Workbook / Worksheet Import Variables.
   GoTo STEP_120   'Step 120-Define MS Excel Workbook / Worksheet Import Variables.
End If

Could you please let me know if there is something obviously wrong with this code?

Bob C.
Join our community to see this answer!
Unlock 1 Answer and 9 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros