Writing Plugins For Windows Live Writer – Adding An Icon

Ok, so now that we have the basis for our Live Writer plugin, we need to start adding things to it to make it look and feel better. The best way is to add an image to the plugin that will appear in the Insert section of Writer.
This is actually very easy, but there are things that you need to remember other wise you will get runtime errors when Live Writer starts up. So first of all, we need to create our little icon, which is what the end user will see in the options and on the right in the Insert field. The thing you have to remember when making this, is its size: it has to be exactly 20×18 pixels. For this demo, I’m going to be using this image: .
The image that I am using I have called icon.gif, and to put it into our project, we can just drag and drop into Visual Studio Express:
This next part is very important otherwise you will be getting an error saying that the image can’t be found and you will be wondering why as you can see it in your project. Right click on the image in the solution explorer, select properties; in the properties, you have a section called Build Action, and you want to set it to Embedded Resource:
So going back to the code from the previous article, we need to add in an extra attribute to the plugin, with the resulting code looking like this:
[WriterPlugin("8638eda4-6533-4d19-9da7-ff92ff5a7590","My First Plugin",
Description="This is my first plugin",
HasEditableOptions=false,
Name="My First Plugin",
PublisherUrl="http://scottisafool.spaces.live.com",
ImagePath="icon.gif")] // This line is where we put the image in the code
The part that we are looking at here is the ImagePath="icon.gif" part. This filename has to correspond to what you have put into the project; now, if that file is in a folder, for example "images", then the ImagePath would be "images.icon.gif". Notice we use a full stop instead of a slash. Once you have put that in, you’re ready to rock and roll; so hit F6 in Visual Studio and let it compile.
Now when we load Live Writer up, we have our link as before, but now it has the image we have assigned to it:
As before, the source code is available here.
SL
Advertisements
  1. #1 by Unknown on January 21, 2008 - 3:35 pm

    wow gold wow gold wow power leveling wow power leveling wow powerleveling wow powerleveling wow power leveling wow gold wow gold World of Warcraft Gold rolex replica wow power leveling wow power leveling wow power leveling wow power leveling wow power leveling wow power leveling wow power leveling power leveling power leveling power leveling rolex rolex power leveling power leveling power leveling wow powerleveling wow powerleveling wow powerleveling wow powerleveling wow powerleveling wow powerleveling powerleveling powerleveling powerleveling wow gold powerleveling powerleveling powerleveling World of Warcraft Gold World of Warcraft Gold World of Warcraft Gold World of Warcraft Gold World of Warcraft Gold rolex replica Warcraft Gold Warcraft Gold Gold wow Gold wow Gold wow Gold wow Warcraft Gold Warcraft Gold 货架 机票 灭蟑螂 租房 租房 北京租房 北京租房 搬家公司 北京搬家 北京搬家公司 上海机票 上海机票 上海打折机票 上海打折机票 上海特价机票 上海特价机票 搬家公司 搬家公司 北京搬家公司 北京搬家公司 中高年 転職 アルバイト 求人情報 ブライダル 転職 競馬 FX ダイエット お見合い 競馬 予想 新築マンション 新築マンション コンタクトレンズ 婚約指輪 合宿免許 人材派遣 東京都 墓地 派遣会社 人材派遣 パチンコ 攻略 おなら cbvcbmngjhgkhjkh

  2. #2 by Unknown on April 8, 2008 - 3:56 am

    welcome to visit RF online blog Mmo blog Mmo guide blog Internet game guideTales of pirates forum ,it will give your some help.EVE online isk cheap EVE isk Guild wars gold Guild wars money GW gold Rs Money Wow gold Wow World of warcraft Gold Wow eu gold Wow us gold Maplestory mesos WOW GOLD worlf of warcrraft  World of warcraft gold Runescape RS gold RF online RF online cp RF online dalant  RF online disena  RF online money RF online gold Lotro gold Buy lotro gold  WOW gold  Cheap wow gold on sale. and you can sell your gold to us.

  3. #3 by on April 15, 2008 - 9:03 am

    wow gold!All US Server 29.99$/1000G on sell! wow gold,WOW Power Leveling-We supply the cheapest WOW PowerLeveling Service Online,with cheapest price and fastest of World Of Warcraft Gold and World Of Warcraft Power Leveling when purchaseing Honor Points/Professions Skills/Rep/World Of Warcraft PowerLeveling.
    Alcohol Tester purchasing center is a professional enterprise Breathalyser,Breathalyzer specializes in breath Gas Alarm consulting,Gas Detector through internet.Co Detector,Co Alarm always have been designed to alarm.
    数据恢复公司是北京市最大的仓储式弹簧销售企业,经销各种不锈钢弹簧。济南市龙威液压机械有限公司是专业生产液压升降机,是国内领先的升降机及升降平台的生产厂家。

  4. #4 by Unknown on May 6, 2008 - 12:50 pm

    キャッシング 比較
    銀行系キャッシング
    融資シミュレータ
    消費者金融 審査
    キャッシング比較
    信販系キャッシング
    ローン
    即日融資
    消費者金融
    レディースローン
    融資
    学生ローン
    即日融資
    おまとめローン
    キャッシング ローン
    低金利キャッシング
    キャッシング 申込
    一本化
    即日 キャッシング
    大口 融資
    低金利 キャッシング
    高額 融資
    低金利 ローン
    大口 ローン
    おまとめローン
    消費者 金融 審査 甘い
    カード キャッシング
    主婦 キャッシング
    ネット キャッシング

  5. #5 by Unknown on July 14, 2008 - 12:10 am

    主婦 キャッシング 銀行系 キャッシング キャッシング 即日融資 女性専用 キャッシング 一本化 ローン 一本化 借金 一本化 まとめ 一本化 銀行 おまとめローン カードローン 審査 ローン 借り換え 銀行系 カードローン レディースローン カードローン 低金利 即日融資 大口融資 高額融資 消費者金融 即日融資

  6. #6 by on August 7, 2008 - 6:51 am

    それは人材紹介ランキング使おう。人財派遣も同じく人材派遣ランキングを使おうね。
    トルコリラ比較もね
    fx比較の投資は外為比較によって大きく左右される投資家ならまだしもfx初心者は一番存。トルコリラもよいしね

  7. #7 by Unknown on September 30, 2008 - 4:12 pm

    Hi,Do you need advertising displays, advertisement screens, LCD digital signage and LCD signages? Please go Here:www.amberdigital.com.hk(Amberdigital).we have explored and developed the international market with professionalism. We have built a widespread marketing network, and set up a capable management team dedicated to provide beyond-expectation services to our customers.
    amberdigital Contact Us
    website:www.amberdigital.com.hk
    alibaba:amberdigital.en.alibaba.com[cbcfchiiaefdah]

  8. #8 by Unknown on October 26, 2008 - 7:12 am

    Hi,Do you need digital signages, advertising displays, digital sign, advertisement displays and advertising players? Please go Here:www.amberdigital.com.hk(Amberdigital).we have explored and developed the international market with professionalism. We have built a widespread marketing network, and set up a capable management team dedicated to provide beyond-expectation services to our customers.
    amberdigital Contact Us
    website:www.amberdigital.com.hk
    alibaba:amberdigital.en.alibaba.com[dbbdeiejjeacgjj]

  9. #9 by Unknown on October 31, 2008 - 9:03 am

    laptop battery for Sony PCGA-BP1 PCGA-BP7 PCGA-BP71A laptop battery
    Original SONY pcga-bp2e vgp-bp2ea pcg-gr100 Battery laptop battery
    Battery for SONY PCG-C1 PCGA-BP51 N505 C1 C2 N505 500 laptop battery
    Battery for SONY PCG-C1 PCGA-BP51 N505 C1 C2 N505 500 laptop battery
    Battery For Sony PCGA-BP2S PCGA-BP2SA VAIO PCG-SR17 NEW black laptop battery

    grey Battery For Sony PCGA-BP2S PCGA-BP2SA VAIO PCG-SR17 NEW laptop battery
    Purple NEW Battery for Sony PCGA-R505 PCGA-Z505 (PCGA-BP2R) laptop battery
    Silver NEW Battery for Sony PCGA-R505 PCGA-Z505 (PCGA-BP2R) laptop battery
    Rechargeable Battery for Sony PCGA-BP4V PCGA-BP2V laptop battery
    battery fits SONY PCGA-BP505 PCG-X505 P PCG-X505 SP laptop battery

  10. #10 by Unknown on November 7, 2008 - 3:44 am

    Battery For ASUS A32-A8 A8JC A8JM A8C A8F Z99 A32-A8 A8 laptop battery
    Battery For ASUS A31-S5 A32-S5 S52N S5000 S5200N S5N black laptop battery

    Battery For ASUS A31-S5 A32-S5 S52N S5000 S5200N S5N white laptop battery
    Battery For ASUS L3 L3D L3000 L3400 L3500 L3800 A42-M2 laptop battery
    Battery fit ASUS A42-A4 A4000 A4D A4K A4G A4S A4L A4Ga laptop battery
    battery for ASUS W3A W3Z W3000 W3000A A42-W3 white laptop battery
    battery for ASUS W3A W3Z W3000 W3000A A42-W3 Silver laptop battery
    Laptop Battery fit ASUS U5A U5F 90-NE62B2000 A32-U5 NEW laptop battery

    BATTERY FOR Asus Eee PC 701C A22-700 4400mAh WHITE laptop battery
    BATTERY FOR Asus Eee PC 701C A22-700 6600mAh WHITE laptop battery
    A32-F3 Battery ASUS F3 F3J F3Q F3JA F3JM F3JF Hi-Capaci laptop battery
    Battery fit ASUS 90-NDT1B1000Z 90-NDT1B2000Z A32-M9 NEW laptop battery
    Battery For ASUS M3 M3N M3NP M3000 M3000N M3000NP 4S2P black laptop battery
    Battery For ASUS M3 M3N M3NP M3000 M3000N M3000NP 4S2P Silver laptop battery

    NEW ASUS M6 M6N M67N M68N BATTERY 90-N951B1000 A42-M6 Black laptop battery
    NEW ASUS M6 M6N M67N M68N BATTERY 90-N951B1000 A42-M6 Silver laptop battery
    Battery For ASUS A42-W1 W1 W1G W1N W1000 W1000G black laptop battery
    Battery For ASUS A42-W1 W1000Gc W1000N W1000Na W1000V silver laptop battery
    A42-L4 Asus 4 L4E L4H L4L L4R L41 L42 L44 L45 laptop battery
    Battery For ASUS A42-L5 L5C L5D L5G L5000 L5500 A42l5 laptop battery

    New Battery fit Asus A42-V6 VX1 V6 V6V V6000 V6000V laptop battery
    New Battery For CLEVO 2200 2700T M220S BAT-2296 BAT2794 laptop battery
    Battery for NC4200 NC4400 TC4200 383510-001 laptop battery
    New Battery For Compaq Presario 700 1400 Evo N105 N115 laptop battery

  11. #11 by Unknown on November 19, 2008 - 12:38 pm

    探偵 調査

    素行調査

    身辺調査

    妻浮気

    悩み相談

    探偵紹介

    探偵事務所

    行動調査

    追跡調査

    結婚式

    電話占い

    大人のおもちゃ

    オナホール

    TENGA

    バイブ

    コスプレ

    大人のおもちゃ

    アダルトグッズ

    アダルトグッズ

    FX

    ローター

    おとなのおもちゃ

    エアコン取付

    ガーデンファニチャー

    システムキッチン

    洗面化粧台

    洗面台

    エッセンシャルオイル

    医学翻訳

    大人のおもちゃ

    アダルトショップ 

    エネマグラ

    オナホール 

    仮性包茎

    アナル

    電マ

  12. #12 by Unknown on November 19, 2008 - 12:38 pm

    ダッチワイフ

    まつげエクステ

    アダルトグッズ

    英会話 学習

    競馬予想

    フラワーアレンジ

    ブリザーブドフラワー

    バラ

    供花

    誕生花

    誕生日プレゼント 花

    北欧家具

    アロマオイル

    ブライダルエステ 東京

    大人のおもちゃ通販

    結婚式

    結婚式準備

    結婚式の髪型

    ウェディングドレス

    av 通販

    アダルト
    ダウンロード

    熟女
    アダルト

    巨乳
    アダルト

    素人
    アダルト

    ニューハーフ
    アダルト

    FX ランキング

    FX 比較

    キャッシング 申込

    債務整理

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: