Charles,
Just poking around the demos with the latest: 0.7.0 2024-03-10
James
cO2m64 -m -64 D:\OxygenBasic\demos\System\SystemTime
ERROR: parameters mismatch for procedure mid_
params given : #string#long@00
OPTIONS:
mid_(gstr_,sys,gstr_) returns sys
mid_(cstr_,sys,gstr_) returns sys
WORD: -
COL: 23
LINE: 21
FILE: "d:\oxygenbasic\demos\system\systemtime.o2bas"
Error(s) occured.
Thanks James,
I have reworked this example:
type SYSTEMTIME
word wYear,
wMonth,
wDayOfWeek,
wDay,
wHour,
wMinute,
wSecond,
wMilliseconds
end type
extern lib "kernel32.dll"
! GetSystemTime (SYSTEMTIME*lpSystemTime)
! GetLocalTime (SYSTEMTIME*lpSystemTime)
end extern
function timestr (int locl=0) as string
=======================================
'
function f (word v) as string
-----------------------------
return mid( "0"+str(v) , -2)
end function
'
function m (word v) as string
------------------------------
return mid("00"+str(v), -3)
end function
'
SYSTEMTIME t
if locl
GetLocalTime t
else
GetSystemTime t
endif
return str(t.wYear) "." + f(t.wMonth) "." f(t.wDay) " " +
f(t.wHour) ":" f(t.wMinute) ":" f(t.wSecond) +
"." str(t.wMilliseconds)
end function
print "System DateTime: " timestr()
print "Local DateTime: " timestr(1)
Hi Charles,
there is a small problem with /demos/Sound/KeyBoardMidi.o2bas. This app runs fine with oxygen.dll 07P10 (version 0.7.0 2024-01-01T14:45:45 32bit), but with the oxygen.dll in progress (version 0.70 2024-03-19T 10:02:07 32bit) I get this error message:
ERROR : not found
WORD: r
PROC: createThemenu
COL: 1
LINE: 422
FILE: main source
This is a strange error message. If I comment out the createThemenu procedure the message happens in a different place. So I think there is something missing with oxygen.dll? Maybe I am using a version that is not up to date?
Thanks Roland,
This is a case-sensitivity issue affecting the iif macro in the program
Here is a quick fix:
macro iif int(r, a,b,c)
'if A then R=B else R=C
if a
r=b
else
r=c
endif
end macro
I will fix this compiler problem properly in the next update.
Hi Charles,
thank you for the updated Oxygenbasic.zip. I only checked on Github today because I did not expect this to happen so quickly. Currently, I am trying to revise an older project that uses some macros which involve uppercase and lowercase letters. I think it is quite good that I do not have to change this writing style.