blog นี้สำหรับคนใช้ VS.NET โดยเฉพาะเลยครับ ลองดูสองภาพนี้เปรียบเทียบ
With .NET Manifest (compiled with Sharpdevelop)
Without .NET Manifest (compiled with Visual Studio .NET 2003)

ภาพแรกนั้นผมคอมไพล์โดยใช้ #Dev 1.1 จะเห็นว่า Progress Bar และ Calendar ดูสวยกว่าภาพที่สองซึ่งคอมไพล์ด้วย VS.NET 2003

ปกติผมก็จะใช้ #Dev เป็น IDE ในการเขียน .NET อยู่แล้ว จึงไม่ได้สังเกตเห็นความแตกต่างข้อนี้ จนแต่พอได้มาใช้ VS.NET มาเขียนโปรแกรมเป็นบางครั้ง จึงได้สังเกตว่าทำไม Progress Bar ถึงมีหน้าตาแปลก ๆ จตอนแรกก็คิดว่ามีซักโปรแกรมแอบทำอะไรในตอนคอมไพล์ ใจึงลองเขียนโปรแกรมแบบเดียวกัน โดยตั้งค่าให้เหมือนกัน วาง control ที่เดียวกัน กำหนด Property ให้เหมือนกันทุกอย่าง แล้วลองใช้ ildasm ลอง disassembly ออกมาเป็น MSIL ดู ก็ปรากฏว่า ผลลัพธ์ก็เหมือนกันอีก แล้วผมก็บังเอิญเห็นว่ามีสิ่งแตกต่างกันในโฟลเดอร์ output ของทั้งสองตัว ก็คือ โฟลเดอร์ของโปรแกรมที่คอมไพล์ด้วย #Dev มีไฟล์นี้อยู่
Manifest file

โดยไฟล์ทางขวา เป็นไฟล์ XML ธรรมดา ซึ่งมีเนื้อหาดังนี้

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <dependency>
        <dependentAssembly>
            <assemblyIdentity
                type="win32"
                name="Microsoft.Windows.Common-Controls"
                version="6.0.0.0"
                processorArchitecture="X86"
                publicKeyToken="6595b64144ccf1df"
                language="*"
            />
        </dependentAssembly>
    </dependency>
</assembly>

วิธีทำให้ WinForm แสดงผลสวยงามก็ไม่ยากครับ แค่สร้างไฟล์ *.exe.manifest ซึ่งมีเนื้อหาแบบข้างบนนี้ไปวางไว้ที่เดียวกับ exe นั้นและตั้งชื่อให้เหมือนกับไฟล์ exe นั้น

update:แถมลิ้งค์ให้อีกอัน มีคนอธิบายว่ามันเกิดอะไรขึ้น Using a Manifest to get XP style controls.

ps: สาดดดดดด

Comment

Comment:

Tweet

Very nice site!

#58 By tuwieowy (103.7.57.18|82.146.63.140) on 2013-04-12 00:08

Hello! fbekfea interesting fbekfea site! I'm really like it! Very, very fbekfea good!

#57 By yrpoerrr (103.7.57.18|200.222.4.90) on 2013-04-12 00:06

KXZzPN <a href="http://gizjxopmtiak.com/">gizjxopmtiak</a>, sefvruqsasmi, [link=http://psarxhygport.com/]psarxhygport[/link], http://vskydklsayhj.com/

#56 By uuxVPYEsmPq (103.7.57.18|87.76.255.108) on 2013-03-26 23:46

zGgajp <a href="http://njiurgwkserk.com/">njiurgwkserk</a>, ppqubexzwreh, [link=http://wgheqtumnmqa.com/]wgheqtumnmqa[/link], http://upentpiceaqm.com/

#55 By QSScDvshj (103.7.57.18|85.232.128.70) on 2013-03-23 14:11

Very nice site!

#54 By eirpieyo (103.7.57.18|80.242.214.149) on 2012-11-27 04:44

Hello! dkbbedb interesting dkbbedb site! I'm really like it! Very, very dkbbedb good!

#53 By tporeutu (103.7.57.18|95.48.133.82) on 2012-11-27 04:39

Very nice site!

#52 By retorrep (103.7.57.18|115.160.176.82) on 2012-11-10 00:25

Hello! feebacf interesting feebacf site! I'm really like it! Very, very feebacf good!

#51 By tppuyyoo (103.7.57.18|75.103.105.103) on 2012-11-10 00:21

Very nice site!

#50 By yryuyeuu (103.7.57.18|193.228.155.135) on 2012-05-13 09:49

Hello! kgebece interesting kgebece site! I'm really like it! Very, very kgebece good!

#49 By tttuiwoy (103.7.57.18|93.82.197.98) on 2012-05-13 09:47

Very nice site!

#48 By uppewrti (103.7.57.18|213.234.200.84) on 2012-05-09 00:14

Hello! degbecc interesting degbecc site! I'm really like it! Very, very degbecc good!

#47 By iuwpyuut (103.7.57.18|74.205.124.95) on 2012-05-09 00:04

comment2, acomplia order on-line, viagra,

#46 By acomplia loss weight (195.168.109.60) on 2010-10-11 01:23

comment5, accutane buy cfs.nomaki.jp link, alprazolam.com, Vibramycin Calcium, cheap cialis, pharmacy prednisone, lipitor liquid, Acomplia, buy reductil, viagra cialis kamagra, meridia, retin-a,

#45 By nexium (80.50.137.118) on 2010-10-10 15:32

comment2, Lasix, lexapro depression, klonopin and anxiety, Alprazolam, phentermine, Levaquin, rimonabant price sanofi,

#44 By cialis on line (203.121.36.51) on 2010-10-10 13:07

comment5, cheap cigs, levitra, köpa prozac,, handla levitra, köp viagra, marlboro cigarette package, prednisolone for dog, cheap cialis, viagra, free dating sites, herbal remedies, xanax generico, handla soma, parliament cigarette website, köpa viagra,, propecia,

#43 By propranolol (123.217.19.70) on 2010-10-10 10:42

comment5, Adipex, buy accutane, discount discount cialis, zolpidem, valium and ppo, prednisone, cheap usa propecia, Valtrex, Meridia, cialis.dyndns.org link, levaquin, viagra type products,

#42 By viagra uk (201.22.95.194) on 2010-10-10 02:32

comment2, Klonopin, Doxycycline, lipitor poisoning, Reductil, Cialis, clomid success stories,

#41 By Nexium (195.197.188.68) on 2010-10-10 00:07

comment2, lasix prescription online, Nexium, klonopin, zolpidem smoking, valium neuropathy, prednisone drug, Valtrex, cialis professional 60 pills, Meridia, cheap retin-a, acomplia rimonabant,

#40 By reductil australia (125.138.27.219) on 2010-10-09 16:40

comment6, lasix, buy klonopin, Cialis, Cialis, Prednisone, cheap viagra, cialis, reductil nz, buy rimonabant, does viagra work,

#39 By buy accutane (220.225.202.72) on 2010-10-09 04:05

comment2, cialis, herpes from valtrex, buy reductil, weight loss no prescription meridia, levaquin.com,

#38 By Prednisone (113.35.91.202) on 2010-10-09 01:39

comment6, adipex next day delivery, klonopin generic, Accutane, buying fake viagra, Doxycycline, Propecia, Valtrex, ambien and nursing, meridia, Reductil, phentermine, Viagra,

#37 By lipitor (41.215.233.146) on 2010-10-08 18:13

comment6, acomplia, Viagra,

#36 By viagra (190.145.85.197) on 2010-10-08 04:45

comment4, bumex, alcoholic treatment antabuse, Cialis, doxycycline, propecia alternative, buy ambien, Meridia, reductil, clomid clomiphene citrate,

#35 By viagra.com (210.105.3.131) on 2010-10-08 02:08

comment5, nexium, klonopin withdrawal, accutane, Alprazolam, zolpidem tablets, Vibrox, Prednisone, Viagra, Propecia, Ambien, Meridia, Phentermine,

#34 By Meridia (195.229.241.178) on 2010-10-07 23:33

comment6, acomplia, viagra prices,

#33 By cheap viagra tablets (97.65.179.5) on 2010-10-07 09:48

comment2, free senior dating, life insurance tables, cialis, discount davidoff cigarettes, herbal and natural medicine, cipro, tax free cigarettes, chanel replica watches, parliament cigarette taste, 19th century herbal remedies, clomid 100 mg,

#32 By doxycycline period (113.35.91.202) on 2010-10-05 20:19

comment1, levitra köp, cialis 20 mg, discount davidoff cigarettes, nolvadex sale, internet dating service, cigarettes, köp viagra, herbal remedies plants,

#31 By köp levitra (113.35.91.202) on 2010-10-05 18:54

comment4, winston select cigarettes, levitra 10 mg, camel cigarette package, cigarettes online, order propranolol, health insurance leads, tennessee health insurance, body building nolvadex, köpa levitra,,

#30 By nolvadex 30 pills (203.196.17.129) on 2010-10-05 18:42

comment4, winston select cigarettes, levitra 10 mg, camel cigarette package, cigarettes online, order propranolol, health insurance leads, tennessee health insurance, body building nolvadex, köpa levitra,,

#29 By nolvadex 30 pills (203.45.10.67) on 2010-10-05 18:42

comment1, replica u-boat watches, online dating, cheap cafergot, free teen dating sites, rimoslim, herbal detox pad,

#28 By herbal remedies for thyroid (86.96.227.90) on 2010-10-05 18:29

comment1, camel cigarettes, antabuse, life insurance, compare levitra viagra, cheapest generic rimonabant, what renters insurance covers, buy viagra, herbal products for men, prednisone, jokes about internet dating, levitra köp, pennsylvania auto insurance, cheap kool cigs, adult dating au,

#27 By cheap auto insurance (193.105.248.70) on 2010-10-05 18:16

comment3, cheap diflucan, köpa viagra,, health insurance, reviews dating services, propecia and breasts,

#26 By herbal remedies (94.23.27.55) on 2010-10-05 18:02

comment5, compare levitra and viagra, herbal medications, cialis, ampicillin drug, propranolol, hoodia, diflucan online, cafergot, free online dating sites, mn health insurance, tinitus herbal remedy, köp soma, america home insurance, remonabent,

#25 By köpa ultram, (187.86.16.248) on 2010-10-01 12:32

comment5, free dating cincinnati, köp viagra, cialis, apo propranolol, adverse reaction to cipro,

#24 By omega replica watches (201.75.60.122) on 2010-10-01 11:55

comment5, free dating cincinnati, köp viagra, cialis, apo propranolol, adverse reaction to cipro,

#23 By omega replica watches (200.52.68.146) on 2010-10-01 11:54

comment5, free dating cincinnati, köp viagra, cialis, apo propranolol, adverse reaction to cipro,

#22 By omega replica watches (173.204.91.82) on 2010-10-01 11:53

hdYgh5 <a href="http://inhmcvxqfezq.com/">inhmcvxqfezq</a>, [url=http://wbzasjseomki.com/]wbzasjseomki[/url], [link=http://fuvsizxwhxdg.com/]fuvsizxwhxdg[/link], http://ycmvzdtpqhyq.com/

#21 By bcqbhzdoz (91.212.212.81) on 2010-09-30 03:13

oa9Ddn <a href="http://ybzvkfdgronx.com/">ybzvkfdgronx</a>, [url=http://liappvdqkpit.com/]liappvdqkpit[/url], [link=http://dcdcscxpokcb.com/]dcdcscxpokcb[/link], http://cskxdaidwyrb.com/

#20 By fopmnwjvlvu (121.129.1.221) on 2010-09-29 15:06

สุดยอดครับ

#19 By BUY LOWEST PRICE (125.26.64.151) on 2010-09-20 19:10

Very nice site!

#18 By ioutpwew (200.254.114.3) on 2009-10-04 09:43

Very nice site! cheap cialis http://opeyixa.com/qoxaqo/4.html

#17 By ioutpwew (84.36.169.99) on 2009-10-04 09:43

issues regions required changes app

#16 By driven adjust (195.190.13.180) on 2009-05-13 06:23

งงค่ะsad smile

#15 By nooam (125.26.182.204) on 2008-10-16 00:33

เจ๋ง สาด

#14 By สปายชาเขียว on 2007-04-14 20:20

รู้มานาน แล้ว สาดดดดดดดดดดดดดดดดดดดดดดดดดดด

#13 By ตั๋ง (58.64.126.35) on 2006-11-03 17:11

เพิ่งรู้เช่นกัน

#12 By Ran (203.170.247.53) on 2006-10-03 12:09

c188e8d69278bd8132c1 5f0cd5f9

#11 By (63.99.92.8 /unknown) on 2006-09-30 10:17

แสดดดดด เจ๋งดีแฮะ

#10 By zkan on 2006-04-15 15:27

เทคนิคนี้ใช้กับ VB6 ได้ด้วยนะ แต่ต้องเรียก API บางตัวก่อนด้วยนิดหน่อย

สาดซะ

#9 By NinkungZ on 2006-04-15 01:09