Subtract Two Dates

I want to subtract two dates not specific dates, the dates that are get from a CFormModel form or from the database table. the dates are get through a variables so how can we subtract this type of two dates. plz give me hlp

Dont open new thread please.