C#(CSharp)71 How to crop an image using C#? static Bitmap LoadImage() { return (Bitmap)Bitmap.FromFile( @"e:\Tests\d_bigImage.bmp" ); // here is large image 9222x9222 pixels and 95.96 dpi resolutions } static void TestBigImagePartDrawing() { using( var absentRectangleImage = LoadImage() ) { using( var currentTile = new Bitmap( 256, 256 ) ) { currentTile.SetResolution(absentRectangleImage.HorizontalResolution, absentRectangleImage.Vertical.. 2018. 5. 9. Get utc time to time zone standard time public static DateTime GetKoreaStdTime() { DateTime localTime = DateTime.Now; try { //DateTime serverTime = DateTime.Now; // gives you current Time in server timeZone //ateTime utcTime = serverTime.ToUniversalTime(); // convert it to Utc using timezone setting of server computer DateTime utcTime = DateTime.UtcNow; TimeZoneInfo tzi = TimeZoneInfo.FindSystemTimeZoneById("Korea Standard Time"); loc.. 2018. 4. 9. Windows/C# Timezone List Afghanistan Standard Time Alaskan Standard Time Alaskan Standard Time\Dynamic DST Arab Standard Time Arabian Standard Time Arabic Standard Time Arabic Standard Time\Dynamic DST Argentina Standard Time Argentina Standard Time\Dynamic DST Atlantic Standard Time Atlantic Standard Time\Dynamic DST AUS Central Standard Time AUS Eastern Standard Time AUS Eastern Standard Time\Dynamic DST Azerbaijan St.. 2018. 4. 9. C# if/then directives for debug vs release #if DEBUG Console.WriteLine( "Mode=Debug" );#else Console.WriteLine("Mode=Release"); #endif 2018. 4. 7. 이전 1 2 3 4 5 6 ··· 18 다음