Date format sign conversion issue

Hello,

i am using the following expression to convert date format -

DateTime.ParseExact(vSearchDate.ToString(),“dd.MM.yyyy”,System.Globalization.CultureInfo.InvariantCulture.ToString(“dd-MM-yyyy”)). But i am getting error that Strict On disallows on implicit conversion from string to integer. Whta could be the issue?

Thanks

@mannu.1996.08
have a look here:
System.Globalization.CultureInfo.InvariantCulture.ToString(“dd-MM-yyyy”))

requires to get changed to
System.Globalization.CultureInfo.InvariantCulture ) .ToString(“dd-MM-yyyy”) )

does mean close after InvariantCulture and remove last )

with following import:
grafik

statement can also be shortened from
System.Globalization.CultureInfo.InvariantCulture
to just CultureInfo.InvariantCulture