Hi
I have two servers, one in UK and the other in US.
They are set to run in the timezones in each country via the config file.
I read in dates from an xml file (UK format) and I'm comparing the month and year to the current month and year from the DB.
For eg;
if (periodRow.PublicationDate.Month == DateTime.Parse(n.Attributes["PublicationDate"].Value).Month & periodRow.PublicationDate.Year == DateTime.Parse(n.Attributes["PublicationDate"].Value).Year)
{
//Month current Month to return PublicationID
PubID = int.Parse(n.Attributes["id"].Value);
}
This code works on the UK, but not on the US Server, does anyone know of a conversion function or something so it would work in both.
Thanks
Tim.
I have two servers, one in UK and the other in US.
They are set to run in the timezones in each country via the config file.
I read in dates from an xml file (UK format) and I'm comparing the month and year to the current month and year from the DB.
For eg;
if (periodRow.PublicationDate.Month == DateTime.Parse(n.Attributes["PublicationDate"].Value).Month & periodRow.PublicationDate.Year == DateTime.Parse(n.Attributes["PublicationDate"].Value).Year)
{
//Month current Month to return PublicationID
PubID = int.Parse(n.Attributes["id"].Value);
}
This code works on the UK, but not on the US Server, does anyone know of a conversion function or something so it would work in both.
Thanks
Tim.