Neha,
Agentry Date/Time variables keep the number of seconds past the Agentry epoch (Jan 1, 2001?). You can take the DIFF between two DateTime properties to get the difference in seconds like you suggested. Not sure why you are having trouble with this. Make sure you always subtract the smaller from the larger.
I created a test screen with two DateTime fileds: Date1 and Date2. The third field is an Integer called Diff that has an update rule to calculate the difference between the two. It checks to see which date is larger before doing the DIFF.
Above image displays 86,400 seconds which is the number of seconds in 24 hours. This is the difference between Date1 subtracting Date2.
Above image displays 172,800 seconds which is the number of seconds in 48 hours. This is the difference between Date2 subtracting Date1.
Above image shows the update rule that does the math.
Jason Latko - Senior Product Developer at SAP