OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: Kerry on January 23, 2009, 09:00:26 PM

Title: Breaking Changes ..
Post by: Kerry on January 23, 2009, 09:00:26 PM
Does anyone have a listing of Breaking Changes between

Stable Version: 4.1.2.2 (or 4.1.1.1)
and
Under Development: 5.0.1.5 ?? or 5.0.1.6 (beta 6 in development)

... and the way to resolve the changes between these releases ?

Regards
Kerry



Title: Re: Breaking Changes ..
Post by: BazzaCAD on January 23, 2009, 09:18:38 PM
That's funny, I just started putting together a "OpenDCL Migration Guide" to address those issues.
I think the major one you'll run into is the check boxes & option buttons no longer returning a Boolean.
I used to always use:
(if (dcl_Control_GetValue MyProj_Form1_CheckBox1)
  (DoStuff)
)


Now you need to update it to:
(if (= 1 (dcl_Control_GetValue MyProj_Form1_CheckBox1))
  (DoStuff)
)

OR
(if (> 0 (dcl_Control_GetValue MyProj_Form1_CheckBox1))
  (DoStuff)
)


I think there are a few other small ones, I'll let you know when I remember them. :)
Title: Re: Breaking Changes ..
Post by: Kerry on January 24, 2009, 04:55:28 AM
Quote from: BazzaCAD on January 23, 2009, 09:18:38 PM
That's funny, I just started putting together a "OpenDCL Migration Guide" to address those issues.
I think the major one you'll run into is the check boxes & option buttons no longer returning a Boolean.
< ... >
I think there are a few other small ones, I'll let you know when I remember them. :)


That's one I know intimately :)

I have a heap of old code to update soon , and would like to have some sort of hit list .. and I imagine it will be handy for others as well, cause there seems to be a lot of users still on 4.1.xx from some of the comments I've read.

Regards
kerry



Title: Re: Breaking Changes ..
Post by: BazzaCAD on January 26, 2009, 11:50:37 AM
Hi Owen,
Are you sure the Deprecated functions are still working?
https://sourceforge.net/forum/message.php?msg_id=5304404 (https://sourceforge.net/forum/message.php?msg_id=5304404)
Some of my old code called (dcl_Grid_SelCurCell) then I updated it to (dcl_Grid_SetCurCell) and all was good.
But when I look at the list of Deprecated functions it says (dcl_Grid_SetCurCell), I'm guessing that's just a type-o.
The type-o isn't really a big deal, but the Deprecated functions not working kind of is....
Title: Re: Breaking Changes ..
Post by: owenwengerd on January 26, 2009, 08:51:26 PM
Quote from: BazzaCAD on January 26, 2009, 11:50:37 AM
The type-o isn't really a big deal, but the Deprecated functions not working kind of is....

It was the same typo both in the reference and int he code. I've fixed it for Beta 7.  BTW, I noticed while fixing this that SelCurRow no longer exists (you have to use SetCurCell instead, passing -1 for the column).