CSharp

warning: Creating default object from empty value in /home/www/virtual/phaisarn.com/sun/htdocs/modules/taxonomy/taxonomy.pages.inc on line 33.

.NET Image Scanner

TWAIN

 

Creating and Using Bitmaps and Icons

Creating and Using Bitmaps and Icons
ที่มา: http://msdn.microsoft.com/en-us/library/ms228345(v=vs.90).aspx

Convert Image to Icon

แปลงไฟล์ภาพ ไปเป็น icon มี 2 ตัวอย่าง ดังนี้
 
    /// <summary>
    /// Converts an image into an icon.
    /// </summary>
    /// <param name="img">The image that shall become an icon</param>
    /// <param name="size">The width and height of the icon. Standard
    /// sizes are 16x16, 32x32, 48x48, 64x64.</param>

C# Visual Studio: Change the default icon of your .exe file.

To change the default icon of your .exe file click on : 

  1. ไปที่ Project
  2. คลิ๊กขวาที่ Project เลือก Properties
  3. เลือก Application
  4. ที่ Icon ทำการเลือก icon ที่ต้องการ

 เรียบร้อย
 
หรือจะใช้คำสั่ง ดังนี้
this.Icon = new System.Drawing.Icon("shuttle.ico");
  
ที่มา: normankosmal.comen.csharp-online.net

MDIList property missing?

การสร้างโปรเจ็กส์แบบ MDI 
สิ่งสำคัญอย่างนึงคือการแสดงรายชื่อหน้าต่างย่อยบนเมนู Window ให้เลือกใช้ได้ง่ายๆ โดยการเขียน MDI ด้วย VS2003 ก็ใช้ MainMenu แล้วกำหนดคุณสมบัติ MDIList
แต่ตั้งแต่ VS2005 ไม่มี MainMenu ให้เลือกใช้ (แต่ถ้า Upgrade มาจาก VS2003 ก็ยังใช้ได้) ต้องเลือกใช้ MenuStrip แทน
แต่ MenuStrip ดันไม่มี MDIList property ให้ใช้
ทางแก้ก็ง่ายๆครับ

Syndicate content