John has not published any posts yet.

I like to be in chage of my own code. If I want the $h of the last day of the month

I code the first day of the following month resolve into hDate=($zdh("01 MMM yyyy",2)-1

Now you can use it with $zd(hDate,2,,4)

Property cAge As %String(TRUNCATE = 1) [ Calculated, SqlComputeCode = {set {cAge}=0 if {dDateOfBirth}>0 set {cAge}=$ZD($H,8)-$zd({dDateOfBirth},8)\10000 }, SqlComputed ];

This code turns my date of birth (+$h style ) into age

I use to find the age of animals in my competitions. as they return year on year. but the Date of birth is constant.

There appears to a confusion and understanding between a ClassMethod and a Method

your code ret=zenPag.getSessionValue()

looks like a Method as it is dependant on the object zenPage existing.

A ClassMethods can be called from anywhere thus must be identified in full

##class(ClassName).ClassMethod(Params if any)

getSessionValue must be a method with the zenPage Class structure.

You do not disclose the Class object that hosts the method1 of the onloadHandler so these may be ClassMethods

But Not the zenPage.getSessionValue() this defines a Method.

John has no followers yet.
John has not followed anybody yet.
Global Masters badges:
John has no Global Masters badges yet.