Showing posts with label Orcas. Show all posts
Showing posts with label Orcas. Show all posts

Saturday, 10 November 2007

Visual Studio 2008 November Release

It was announced at Tech Ed Barcelona this week that Visual Studio 2008 (Codename Orcas) will deffinatly be released by the end of the month!!

For more informaton click here.

Tuesday, 28 August 2007

WPF Calculator






In my last post I went through creating my first application in WPF and straight away I started thinking about creating a much more visually attractive application, so I decided to create another basic application, this time a simple calculator.

Using Orcas Beta 2 I was able to create a WPF form with 2 text boxes for user input, a combo box, button and a label for the result of the calculations.

I first started out with the combo box displaying text to signify different calculations (e.g. +, -, /,*) however as I was making the rest of the application found myself getting more confident and decided to add images to the combo box so that a user can select an image representing there choice. Implementing this was much easier that I first thought it would be and using only a couple of lines of code in the XAML file and altering some of the code behind file I was able to use the image combo box to select the type of calculation. The XAML for this is:


<ComboBox Margin="40,107.457,0,79.968" Width="120" Name="comboBox1" HorizontalAlignment="Left">

<Image Name="add" Source ="images\add.jpg" />
<Image Name="minus" Source ="images\minus.jpg" />
<Image Name="multiply" Source ="images\multiply.jpg" />
<Image Name="divide" Source ="images\divide.jpg" />

</ComboBox>




And in the code for this to find which of these images your user selected simply find the index of the items in the combo box.






All the images that I have used in the combo box were created in Expressin Design and Exported as jpg files. With creating the images myself I was able to directly match the hex color value for the rest of the application to this creating a unified feel to the program.



Overall I dont think it was a bad effort at all for an hours work, an experienced programmer would be able to create some amazing things with WPF can't wait till it hits the mainstream and all released products look this good.


WPF "Hello, World"

So I managed to complete the WPF introduction course which I last posted about and after doing this I thought I would like to create a simple application using XAML and WPF to feel a little more at home with the whole subject, so I decided to download me a copy of Orcas Beta 2 Express and create a Hello World App.

Hello World applications are normally the first application (if you can even call them that) that most people will make when they start looking at a new programming language or programming concept. So heres how I went about creating my first WPF application.

I used Orcas, which is really nice I love the split layout that is used to display the design in the top half of the screen and the XAML code in the bottom section, this reminds me of using Expression Web and how the design and code is split on a single screen making it easy to tweak little bits of the program without constantly switching to a code view. However to see the code behind file for the application (much like the code behind files in ASP.NET) you have to open a new tab to get to this.

So getting started I just dragged and dropped a button and text box onto the form, this like i said before generates the XAML in the bottom half of the screen, so you can see how buttons are made in XAML. The XAML is really easy to understand and if like myself you have had some previous experience with XML you will find it pretty straigh forward.


Once I have my form layout how I want it, I then have to get the XAML button to respond to an event, this can either be done just like in a C# windows application by double clicking on the button or it can be done in the XAML code itself. To add an on click event you simply add a "click" attribute to the button tag.


So we now have:

click = "button1_click"

added to the attribue list for the button tag.

The click attribute says that when the button is clicked go and find the event handler called button1_Click in the code behind file.


For this event handler in the code it is extremly simple to display the desired text in the text box done just how you would if you were using any other language.


private void button1_Click(object sender, RoutedEventArgs e)
{
textBox1.Text = "Hello, World";
}




This then just simply displays the text "Hello, World" in the text box we created in design view. Now we can run the code and see the amazing aplication in all its glory.


I am hoping to get a little time to play about with WPF before I have to start uni so hopefully will start to make some better appliations than this.

Tuesday, 7 August 2007

Visual Studio 2006 'Orcas' Event

There is an upcoming event from Microsoft to demonstrate the new features of Visual Studio 2008, formerly codename 'Orcas'.

The event will be split into 2 sessions the first covering LINQ (Language Integrated Query) which I am personally looking forward to as LINQ looks extremly promising and looks as though it will be easy to pick up due to the syntax being much like that of SQL. I can see LINQ being a major part of new development, especially if all documents etc. have an XML back end.

The second session of the day covers the remaining features of Visual Studio 2008.

The event will take place both in Reading and London with the same content on each day, links to the event are below:

Reading - 04 September 2007

London - 05 September 2007

If I can find a cheap ticket I will be attending, hope to see you all there!

Sunday, 15 July 2007

"Orcas" Microsft Visual Studio 2008

As most people are now aware Microsoft are going to be releasing a new version of Visual Studio which has been codenamed Orcas. This is due for release in 2008, however you can get your hands on an Express Beta edition of VB, C++, C# and Web Developer at the following link:

http://msdn.microsoft.com/vstudio/express/future/downloads/default.aspx