Have big problem I don´t know how to compare date in C# like PHP. I want to convert this code in to C#:
$now = strtotime ("now");
$then = strtotime ("$date");
$difference = $now - $then ;
$num = ($difference/86400)/7;
$weeks = intval($num);
Which function should I use?
This link can´t find a matching function like strtotime
.
Please help me to convert the code to C#. Thanks in advance.