Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Shareware protection system for macros
#15
Thanks for your advices. It was useful for me.

Other quesions as below,

1. From the same macro:
Function SM_About
Code:
Copy      Help
if(days_left>0) e11.format("UNREGISTERED. %i days left." days_left-1)

I want to show the time consisted of year, month, day, hour, minute...,how to modify the code?

2. I test code as below
Macro Macro3
Code:
Copy      Help
DATE DAY1.getclock
wait 5
DATE DAY2.getclock
DATE day_diff=DAY1-DAY2
out day_diff

why the result is
am 12:00:05?

3. from QM help:
Macro Macro3
Code:
Copy      Help
DATE d="4/1/2003"
;add 2 days
d=d+2
out d
;subtract 1 hour
SYSTEMTIME st
st.wHour=1
out d.sub(st)
;get difference in hours
out d.diff("4.1.2003" st 1)
out "%i/%i/%i %i:%i:%i" st.wMonth st.wDay st.wYear st.wHour st.wMinute st.wSecond

the results:
2003/4/3
2003/4/2 下午 11:00:00
Error (RT) in Macro3: 0x80020005, 類型不相符。. ?

and fail in

Macro Macro3
Code:
Copy      Help
out d.diff("4.1.2003" st 1)

why?and how to modify?


Messages In This Thread

Forum Jump:


Users browsing this thread: 4 Guest(s)