I got annoyed that every time I opened an old RB project I'd
downloaded, the declares were all made for Classic and I had to
Carbonize them and put in #if statements and so forth. So, I wrote
myself a little method, put it in a little module, and just added it to
whatever projects I opened.
I thought perhaps others might find it useful, so here you have it. To
use it, just put GetFragmentName(" before the library the Declare uses,
and ") after it.
Function GetFragmentName(ClassicLib as String) As String
dim sysV as integer
if system.gestalt("sysv", sysV) and sysV >= &h1000
return "CarbonLib"
else
return ClassicLib
end if
End Function
Enjoy : )
Ryan Govostes
---
A searchable archive of this list is available at:
<http://support.realsoftware.com/listarchives/search.php>
Unsubscribe:
<mailto:realbasic-nug-off at lists dot realsoftware dot com>
Subscribe to the digest:
<mailto:realbasic-nug-digest at lists dot realsoftware dot com>
.
|