在我vb.Net項目我用下面的代碼設置爲MyApplicationVB.NET所有MyApplication相當於在C#
Private Sub MyApplication_Startup(ByVal sender As Object, ByVal e As Microsoft.VisualBasic.ApplicationServices.StartupEventArgs) Handles Me.Startup
Dim newculture As System.Globalization.CultureInfo = System.Threading.Thread.CurrentThread.CurrentCulture.Clone()
newculture.DateTimeFormat.ShortDatePattern = "dd/MM/yyyy"
newculture.DateTimeFormat.DateSeparator = "/"
System.Threading.Thread.CurrentThread.CurrentCulture = newculture
End Sub
我如何在C#中做到這一點的日期格式?
什麼樣的應用程序是你的DLL或EXE。類型。 – JSJ 2013-04-05 10:37:58
應用程序類型是exe – 2013-04-05 10:38:40
打開program.cs文件並添加下面的代碼。轉化爲靜態主要方法。 – JSJ 2013-04-05 10:39:37