im new to vb and i want to sum my days and months and seems not working..i convert months back to days.suppose my code below works fine but i got no sum values at the end.please help
Public Function test(length As Integer ) As String
dim month As integer=0
dim day As Integer=0
dim sum as integer
if length>31 Andalso length<367 then
length=(month * 30.4375)
month=(length)
end if
if length<31 Then
day =cstr(length)
end if
sum= year+month+day
return(sum)
End Function
thanks


Reply With Quote
