I retrieve a date and time from my web api and set it as so :
tmp = DateTime.ParseExact(dateAndTimeFromApi, "dd/MM/yyyy HH:mm:ss", null);
I need to convert this DateTime to a UTC DateTime. When I add .ToUniversalTime() it does not convert from local to UTC. My current timezone is UTC + 2. So I want to get from 11am to 9am after the conversion.
How can I do this if I want to keep the "dd/MM/yyyy HH:mm:ss" format ?