Jump to content

Internal Error message.. driving me up the wall


Hudson

Recommended Posts

I'm getting this:

 

INTERNAL ERROR: !scandr.cpp@2227: eLockViolation

 

I am just doing simple math to some variables when the program crashes autocad... I'm confused as this section of code has worked before in other programs...

 

I'm thinking there is something else going on to cause it.

 

Any ideas?

Link to comment
Share on other sites

Steve, good point.

 

(setq a (dcl_TextBox_GetLine TSS_M1_TextBox27 0))              ; get the degrees
 (setq a (atof a))
 (princ "/nValue of A: ")
 (princ a)
 (setq b (dcl_TextBox_GetLine TSS_M1_TextBox28 0))              ; get the minutes
 (setq b (atof b))
 (setq b (/ b 60))                            ; convert to minutes
 (setq c (dcl_TextBox_GetLine TSS_M1_TextBox29 0))              ; get the seconds
 (setq c (atof c))
 (setq c (/ c 3600))                            ; convert to seconds
 (setq TurnedAng (+ a b))
 (setq TurnedAng (+ TurnedAng c))                     ; LaserAng is now in DD format
 (princ "\nTurned Angle in DD: ")
 (princ TurnedAng)
 (setq TurnedAng (dtor TurnedAng))                      ; LaserAng is now in Radians
 (princ "\nTurned Angle in Radians: ")
 (princ TurnedAng)
 (setq Test (- (* 2 pi) TurnedAng))                     ; Autocad works counterclockwise with angles
 (princ "\nTurned Angle Remainder: ")
 (princ Test)
   
    
 (setq TurnedAng (+ Test BSAngle))                             ; LaserAng From East X Axis CounterClockwise
 (princ "\nNew Value of Turned Ang")
 (princ TurnedAng)
 (setq b (atof (dcl_TextBox_GetLine TSS_M1_TextBox30 0)))                ; Get the distance to the center of the front target
 (setq a (polar SetupPt TurnedAng b))                            ; calculate the end coord of the laser line
  

 (entmake        
     (list
         (cons 0 "LINE")
         ;(cons 8 LaserStnName)     ; Layer
         ;(cons 6 KIND_LTYPE)          ; Line Type
         (cons 62 6)                 ; Set Colour
         (cons 10 SetupPt)        ; Beginning Coord
         (cons 11 a)            ; End Coord
     ) ; End list
  ) ; End entmake

 

That's the section of code that's making autocad barf. When I start getting errors, I break the code down and print variables to the screen a lot ;)

 

Autocad has crashed before it gets to the entmake command.

Link to comment
Share on other sites

It was entmake causing the crash.. vla-addline works fine with a bit of a delay (is that normal?)

I can only speak on the one time experience I noted above and at that time I also noted a alight delay with vla-addcircle. Anyone else?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...