August 2007 Blog Posts
This is a part of the WPF image viewer tutorial: Introduction, Part 1, Part2 and Part 3.
I promised something nice and we got all the way to the 4th post with a program that displays a list of filenames, it's time to start seeing some images.
The WPF list box control isn't the old Windows list box, while the old list box could only display a list of strings the WPF list box can display any list, if we tried to display buttons we would have got a list of completely functional buttons you can press – but we used a list...
This is a part of the WPF image viewer tutorial: Introduction, Part 1, Part2.
In this part we'll connect the C# code with the XAML UI, just open Window1.xaml, find the Grid element and add the following line between <Grid> and </Grid>
<ListBox ItemsSource="{Binding AllImages}"/>
This will create a list box and bind it's ItemsSource property to the AllImages property we wrote in the last part, it you'll run this you will get a window with a list box covering the entire window and the list box showing the names of all the image files.
The reason we set the DataContext in the...
Andy Brice, Creator the table planning software PerfectTablePlan, did a little experiment and posted an obviously fake software program to a lot download sites, and not only got listed on a lot of them – he also got many 5-star awards from some of those sites, read his post here.
I've suspected this for some time, when you're looking for software those days often all you find are those spammy, low quality and ad filed download sites, they get their high search engine position by sending all those 5-star awards and getting a link from sites posting them.
I haven't submitted yaTImer,...
This is a part of the WPF image viewer tutorial: Introduction, Part 1.
This part of the tutorial has very little to do with Wpf, we just have to define and fill the data structure used to hold the image information.
First let's define a class to hold an image and it's file name, I've defined this class as a nested class of Window1 because it doesn't matter where we put it.
public class MyImage
{
private ImageSource _image;
private string _name;
public MyImage(ImageSource image, string name)
{
_image = image;
_name = name;
}
public override string ToString()
{
return _name;
}
public ImageSource Image
{
get { return _image; }
}
public string Name
{
get { return _name;...
Finally yaTimer get a reporting feature that's as good as the rest of the software (In case you're new here, yaTimer is my time tracking software).
This is still a work in progress and many things will change until the final release, but here are is a picture of two of the new reports from the latest development version.
I'll write about printing and documents in WPF after I finish my current WPF tutorial series
This is part of the WPF image viewer tutorial series, you can read the introduction here.
Create the project
We'll start writing code soon, but first a short overview of what visual studio does for us.
After you installed all the required software you can start Visual Studio
Select File -> New -> Project From the main menu.
In the project types tree (on the left) select "Visual C#" and on the templates list (on the right) select "Windows Application (WPF)".
Enter "ImageViewerTutorial" into the name box at the bottom and click Ok
Visual Studio should now create a skeleton WPF application for you.
Visual Studio created 2...
I just love WPF, it's the best UI system I've ever worked with.
When I want to introduce my friend to WPF I just build a small image viewer with them, it takes me less than 30 minutes and it really shows the power of WPF features like templates and data binding.
I've decided to expand my little demo and post it to my blog, this will take several posts – each one showing another nice feature.
Before we begin there are a few things we need in order to write WPF code:
Windows XP SP2 or Windows Vista –...
Andy Brice wrote a post on his blog titled If you aren’t embarrassed by v1.0 you didn’t release it early enough.
I really like the idea of releasing early, yaTimer, my time tracking software, was released just two weeks after I started working on it (two weeks of nights and weekends, I don't believe in quitting your "day job" so soon).
Version 1.0 was missing important features, the setup program user experience was very poor and you couldn't even buy it (I didn't even setup my payment processor before releasing it).
The current version (1.2) it much better and I plan to stop being...
Finally, the last post in the auto-update series. Previous posts: part 1, 2, 3, 4, 5, 6 and 7
For 8 posts I've been writing about the technical details of building a good automatic update component from scratch, what I haven't wrote is that it's probably silly to write your own instead of using something that already works.
ClickOnce
ClickOnce is built into .net (version 2.0 and later) and is extremely easy to use, all you have to install your software using ClickOnce. You prepare the ClickOnce package – just a few files on a web server (all your program files and...
I've already started working on the next version of yaTimer, and for the first time I'm going to reveal my plan for the future of yaTimer but everything written here is just my plan, plans can change, I'm not promising anything.
As a lesson from version 1.2 I've split my plan into smaller versions, this will allow me to release more frequent updates and get the improvements to my customers faster.
I'm not publishing the target release dates for future versions but all the versions listed here are supposed to be released in less than a year, this combined with my 1 year...
This is part 7 of a series, previous posts: part 1, 2, 3, 4, 5 and 6
In the previous part I promised to talk about how to update a program while it's running, if you were hoping for some cool file system locking trick you are going to be disappointed.
The method I used for yaTimer, the time tracking application I've developed, is very simple. All the program files are not stored directly in the program folder but in a sub-folder this sub-folder is different for each version, so what you get is:
Program Files
yaTimer
1.1.0 all the files for version 1.1.0
And...
When working on yaTImer's new report engine I got myself into a bit of a problem, I'm blogging about it because I couldn't find an answer on the web and I can't believe I'm the only one with this problem, so I hope someone will find my solution helpful (or maybe suggest a better one).
My reports engine generates a FixedDocument that I can print or show to the user, because the report can contain a lot of information generating the document can potentially take some time, so I went for the easy solution and dropped a BackgroundWorker into the code.
So...
|