Exemple #1
0
 public static object Substring(object x, object y, object z)
 {
     if (ObjectValue.IsString(x) && ObjectValue.IsAnyInt(y, z))
     {
         return(StringValue.Substring((string)x, IntValue.ToInt(y), IntValue.ToInt(z)));
     }
     return(null);
 }
Exemple #2
0
 public static object AddYears(object x, object y)
 {
     if (!ObjectValue.IsAnyInt(y))
     {
         return(null);
     }
     if (ObjectValue.IsDateTime(x))
     {
         return(DateTimeMath.AddYears((DateTime)x, IntValue.ToInt(y)));
     }
     return(null);
 }