Quantcast
Channel: Autodesk AutoCAD forums
Viewing all articles
Browse latest Browse all 14319

VBA Run time errorr on 64 bit OS

$
0
0

Hi

let me please preface this with that i'm a novice at VBA programming and

the person who has written the following code is no longer in the office.

 

we are transfering our CAD systems over from 32 bit to 64 bit OS.

we have a VBA code that works fine on autocad 2012 - 32 bit but when

we try this code on a autocad 2012 64 bit system we get the following

error  "Run-time error '424' Object required"

 

Here is the code

 

Private Sub BlocksListBox_Click()

Dim sInfo As Object
Dim strComments As String

    InsertedBlock = ((BBDrvLtr) & (WPBlocksSupportPath) & SelectedDiscipline & "\" & SelectedSubArea & "\" & BlocksListBox.Value)
Select Case Me.BlocksListBox.text
    Case Is = BlocksListBox.text
             DwgThumbnail.DwgFileName = (InsertedBlock)
    End Select
End Sub

 

 

 

The routine is basicaly a block browser and it has a thumbnail viewer.

i can get the routine to work by commenting out the following line, but

i'd really like to get this working in ouor 64 bit enviroment.

 

'             DwgThumbnail.DwgFileName = (InsertedBlock)

 

 

i've also thought that this might have something to do with the

dwgthumbnail.ocx file but i have updated to a 2013 64 bit version of
this file and it still gives me the same error (couldnt find a 2012

version).

 

As i said, i'm a novice, so please any information on how to get this

working would be an advantage to me.

 

Thank you in advance

 


Viewing all articles
Browse latest Browse all 14319

Trending Articles