Mobile Zone is brought to you in partnership with:

Senthil Kumar is a Software Engineer who has around 3 years of experience in IT industry. He is currently working as a Software Engineer in Bangalore and works mainly on the Windows or Client Development technologies and has good working experience in C#/.NET, Delphi, Winforms and SQL Server. He is also a Microsoft Technology Certified Professional in ASP.NET. He Blogs at http://www.ginktage.com and http://www.windowsphonerocks.com. He enjoys learning as much as he can about all things related to technologies to get a well-rounded exposure of technologies that surround him. Senthil completed his Master of Computer Applications from Christ College (Autonomous), Bangalore in the year 2009 and is a MCA Rank Holder. He has passion for Microsoft technologies especially Windows Phone development. You can connect with him on Twitter at (http://twitter.com/isenthil) , on Facebook at (http://www.facebook.com/kumarbsenthil) and his blog (www.ginktage.com). Senthil is a DZone MVB and is not an employee of DZone and has posted 129 posts at DZone. You can read more from them at their website. View Full User Profile

Adding ApplicationBar in Windows Phone 7 using Expression Blend

01.10.2011
| 4013 views |
  • submit to reddit

In one of my previous posts , I talked about Adding the Application Bar in Visual Studio . In this blogpost , I will explain about adding the ApplicationBar in Expression Blend .

Expression Blend provides more Designer support while Adding the Application Bar when compared to Visual Studio .

Here are the steps to add the Application Bar in the Expression Blend .

  • Go to Microsoft Expression Blend for Windows Phone
  • Click on the new Project and select the template windows phone application in the Expression Blend and provide the project name and click on Ok

  • You might see that there is no precommented xaml code like the one that was generated while creating the project in Visual Studio 2010 .
  • Select the Phone ApplicationPage in the Objects and TimeLine

  • Check the Common Properties group from the Properties Tab . You can find it in the right side of the Window .

  • You should be able to find the ApplicationBar property as well as the New Button to create the ApplicationBar ( Missing in VS2010 ) . Click the new Button to add the ApplicationBar .
  • Now , the Common propeties groub will be expanded to show more properties for the ApplicationBar like Adding the Icon Buttons and MenuItems etc .

  • Click on the Button (…) on the Buttons Property to open the popup window to enter the Icon Buttons
  • Click on the Add another item Combo and select ApplicationBarIconButton and provide the IconUri and Text for the Icon Buttons . Note the Default icons that are available are displayed in the dropdown of the IconUri . You can find more of the icons from the SDK installation path : “C:\Program Files\Microsoft SDKs\Windows Phone\v7.0\Icons”
  • Similarly , You can add the MenuItem from the … Button next to the MenuItems(Collection) in the Common Properties . A popup window will show up when clicked on the Button  , enter the menu name etc … and Click Ok .

  • Now , run the project , you should be able to See the added ApplicationBar with the Menu item and the Icon Button .



Thats it , the xaml code is generated automatically as we added menu items in the designer .

Easy wasn’t it ??

References

References
Published at DZone with permission of Senthil Kumar, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)