Microsoft Windows 2008 Server Licensing For Dummies

I was honored to be asked late last year to write Windows Server Licensing 2008 for DummiesWin2k8LicensingFDSmall as a joint project with Wiley and Microsoft.  This is a custom book – an eighty-six page minibook specifically for Microsoft to give to customers working on licensing Windows Server 2008.  I finished it in March, and finally got a few copies.  If you want a copy, you have to ask you local Microsoftie!

Anyway. the book came out very well.  The people in the licensing office are so very knowledgeable and easy to work with; the project was a complete joy for me.  What’s more, I think it really is a win for the average IT manager – the book is readable, easy to understand and accurate.  Licensing is foreign to many people, but with a few basic points in mind, you really can keep legal and save yourself some money!

I think the custom book concept is a real win for Microsoft too – they get a great, well known format for not much more cost than it takes to develop and print all of those whitepapers that no one ever reads.  People actually real dummies books, you know what I mean? 

Anyway, they gave them out at TechEd, and I think there will be more at PDC when the time comes.  Drop by the Windows Server book and snag a copy in November.

Liveblogging setting up data storage for Sharp

After uploading the basic services to Azure early this morning, I felt the need to finish, and actually set up some kind of data storage for the system.  After all, the services are only useful if the data is actually accessible, and eventually I plan to resubmit this as my certified app for POINT's ISV certification.  So I squandered one of my two storage service keys to Sharp's database in the cloud.

At first blush, this seems straightforward.  I logged into the Azure dashboard at https://lx.azure.microsoft.com and provisioned a new storage services account.  This required only a unique name and a description.  In exchange, Azure provided me with three endpoints:

  • the blob services;
  • the queing services; and,
  • the table services.

OK, right now I need tables.  I am essentially going to move the simple 4 table schema for Sharp into the cloud for this first version - we'll look at sophisticated use of property bags and whatnot at a later date.  I have my primary access key; time to move to Visual Studio.

 

Seeking name for new Rye/Wheat blend

I decided that I wanted a simple Rye/Wheat blend for the end of summer, so I constructed this fairly simple recipe.  I think I might have underhopped it, especially considering the Rye character which at first take seems to demans a little more upfront bitterness.  We will have to see though - I put it down in primary on Sunday.

I'm also looking for a name for it - apparently they were all of of Creativity at the homebrew shop.  Thoughts?

Wheat/Rye

Wheat/Rye
American Wheat or Rye Beer

 

Type: Extract

Date: 6/17/2009

Batch Size: 5.00 gal

Brewer: Bill sempf
Boil Size: 3.25 gal Asst Brewer: Gabrielle sempf
Boil Time: 60 min Equipment: Brew Pot (4 Gallon)
Taste Rating(out of 50): 35.0 Brewhouse Efficiency: -
Taste Notes:
 

Ingredients

Amount Item Type % or IBU
7.00 lb Wheat Dry Extract (8.0 SRM) Dry Extract 87.50 %
1.00 lb Rye, Flaked (2.0 SRM) Grain 12.50 %
1.00 oz Mt. Hood [5.30 %] (60 min) Hops 12.1 IBU
1.00 oz Saaz [2.50 %] (15 min) (Aroma Hop-Steep) Hops -
0.75 oz Orange Peel, Bitter (Boil 5.0 min) Misc  
1 Pkgs American Hefeweizen Ale (White Labs #WLP320) Yeast-Wheat  

 

Beer Profile

Est Original Gravity: 1.062 SG

Measured Original Gravity: 1.580 SG
Est Final Gravity: 1.016 SG Measured Final Gravity: 1.160 SG
Estimated Alcohol by Vol: 5.99 % Actual Alcohol by Vol: 62.65 %
Bitterness: 12.1 IBU Calories: 7,560 cal/pint
Est Color: 8.0 SRM Color:
Color

 

Introducing: C# 2010 All In One Desk Reference For Dummies!

I’m pleased and proud to announce that I’ll be migrating the fantastic C# 2008 for Dummies book by Steve Davis and Chuck Sphar to an All In One format for the release of C# 4.0 and VS 2010.  All of the goodness in the 2008 Dummies book, plus the bonus chapters on the site will be in the all-in-one.  Alongside, there will be tons of new information on Windows and Web programming, new features and fun stuff.  There will be nine (!) books in one cover for this all in one, including:

  • Book 1: Basics of C# Programming
  • Book 2: Object Oriented C#
  • Book 3: Designing for C#
  • Book 4: A tour of Visual Studio
  • Book 5: Windows Programming (Winforms and WPF)
  • Book 6: Web Programming
  • Book 7: Service Oriented Development (ASMX and WCF)
  • Book 8: Neat Stuff (Robotics, Graphics, AI and Compilers!)
  • Book 9: C# 4.0 New Features

 

The book will be available everywhere right around the release of Visual Studio 2010 in late fall or early winter. 

Shameless self promotion

I have set up a number of conglomeration sites in the last week, which I thought I would share with the interested.  One relates to books, one to articles, and one to speaking.

The first is FiledBy, at http://www.filedby.com/author/bill_sempf/.  It is a managed site with books of mine that are still in print.  Neat concept, and I look forward to using it.

The second is SpeakerSite.  Set up by my friend Artie Isaac, it is a conglomeration of a lot of speakers on different topics.  My site is http://www.speakersite.com/profile/BillSempf and I have posted a video to my recent cloud computing presentation.  After my C#4.0 presentation Tuesday, I'll post a video to that too.

The third is Ulitzer.  This one is pretty cool.  Back in 2000 -2001 timeframe, I wrote a number of articles for Sys-Con media.  After I started my contract with MSDN I kinda dropped off their map, but I didn't lose touch with the people involved.  Now, it turns out they are a big power in publishing for cloud computing, along with their other assets.  Anyway, they have these customizable author sites, and mine is http://williamasempf.ulitzer.com/.  I'll be adding articles and linking up this blog to it shortly.

Anyway, I usually just write about technology, and this is not specifically VB technology, but it is cool use of the media so I thought I would share.

Economics of Cloud computing presentation for the ACM

I presented a paper last month for the ACM and IEEE that will be published in the Cloud Computing Journal next month.  Thought I would post a few links here for those who are interested in cloud - I did cover Azure.  I'll do a blog post for Azure and VB when I manage to upload SHARP to the cloud, like I plan to.

The slides are on the IEEE site: http://www.ieeecolumbus.org/node/97

The presentation video is at my SpeakerSite: http://www.speakersite.com/profile/BillSempf

The article will be on my Ulitzer site: http://williamasempf.ulitzer.com/

I hope you find the information as interesting as I did!

My Visual Studio 2010 presentation for ICC

Just finished up a presentation on Visual Studio 2010 for ICC's MS Dev special interest group.  A good time was had by all.  I used the card deck that is in the Training Kit, and added a few salient slides.  We had a lot of conversation about Linq, WPF and the lifecycle integration.

My slide deck can be downloaded here, and I also wanted to post a few links that I mentioned in the talk.


I hope to get some comments back - feel free to email me, especially if they are bad.  (heh)  Thanks to all for attending!

Live blogging a XAML project with CodePlex - handling failure

I bet you all think that I mean failing at writing  the game, didn't ya?  Hmm?  Ha!  Not so fast my friend, I mean handling the last requirement in the project - failing the press the correct letter before the letterbox hits the bottom of the screen.

So what I want to do is check on timer click of the letter has hit the bottom, and if it has then fire off a new message (Oh no instead of Wow) and get a net letter at the top,  Should be good enough for a three year old, I figure.  As I get better in XAML I can make more features, right?

To start off I will modify the ShowWow so that it accepts a TextBlock and renders its transform no matter what it is.  I changed the name of the function to ShowMessage and used the VB refactoring feature to change all references.  Then I altered the signature to accept a textblock as a parameter, and used that object in the code instead of WowTextblock.  Finally, I changed the calling function so that it passes un WowTextblock.  Sounds like a lot, but it just took a second.  ShowMessage now looks like this:

Public Sub ShowMessage(ByVal blockToTransform As TextBlock)
    'Make an animation for the scale
    Dim blockAnimation As New DoubleAnimation(0, 100, New Duration(New TimeSpan(0, 0, 3)))
    'Make another for the opacity
    Dim blockOpacity As New DoubleAnimation(1.0, 0.0, New Duration(New TimeSpan(0, 0, 3)))
    'Go grab the ScaleTransformation from the XAML and se tthe properties
    Dim blockTransform As ScaleTransform = DirectCast(blockToTransform.RenderTransform, ScaleTransform)
    blockTransform.CenterX = 11
    blockTransform.CenterY = 7
    blockTransform.ScaleX = 1
    blockTransform.ScaleY = 1
    'Then run all of the animations
    blockTransform.BeginAnimation(ScaleTransform.ScaleXProperty, blockAnimation)
    blockTransform.BeginAnimation(ScaleTransform.ScaleYProperty, blockAnimation)
    blockToTransform.BeginAnimation(TextBlock.OpacityProperty, blockOpacity)
End Sub


Alright, now I need to add a XAML element that has the Oh No! text in it.  I think I'll make it red.  I just copied the Wow! textblock and edited it.

<TextBlock x:Name="ohNoTextblock" Opacity="0" Foreground="Red" HorizontalAlignment="Center" VerticalAlignment="Center" Text="Oh no!" Visibility="visible">
    <TextBlock.RenderTransform>
        <ScaleTransform></ScaleTransform>
    </TextBlock.RenderTransform>
</TextBlock>


So now clockCheck looks like this:

Private Sub ClockCheck() Handles gameClock.Tick
    letterBoxTop = letterBoxTop + 10
    letterBox.Margin = New Thickness(letterBoxLeft, letterBoxTop, 0, 0)
    'Check to see if it is at the bottom
    Dim bottom As Double = gameBoard.Height
    If letterBoxTop + letterBox.Height > bottom Then
        'It has hit the bottom.  
        gameClock.Stop()
        scoreCount = scoreCount - 1
        'Fire the Oh No message
        ohNoTextblock.Opacity = 100
        ShowMessage(ohNoTextblock)
        'Restart the letter
        SetupLetterBox()
        gameClock.Start()
    End If
End Sub


And there we are!  Kid tested, mother approved too.  I'll post a video of Adam playing it this weekend, when I do my post about further enhancements.  Also, I will check in the changes to CodePlex right now before I forget.

To create a release in CodePlex, I just had to go to the releases tab and Add a New Release.  That gives me a really nice little mini-wiki for the release, and an upload facility for the binary.  I made a few notes and loaded it up!  CodePlex is a really nice, simple facility for opensource work - better than SourceForge for simple projects.  I like it a lot.

I hope this little series has been helpful to everyone - it sure has for me.  I think that XAML is likely the future of Microsoft UI programming, so it behooves us all to get our feet wet as soon as we can, to make the curve less steep when our projects make the move.  Please leave any thoughts in the comments.

Live blogging a XAML project with CodePlex - Now with WPF

OK, we have th game basics, we have enforced the game rules, now we need to make it playable.  In order to do this (according to the original requirements) we need to

  1. Add a little pizzaz to the notifications
  2. Handle it when the player looses a letter

So I found that in order to proceed with this project, I needed to define a few terms.

  • XAML - it's basically HTML.
  • WPF - It's ASP.NET, or Cold Fusion, or JSP.  Control that render XAML, like the ASP.NET controls render HTML.

So where does this leave us?  A whole, totally new library to learn, after having already learned HTML since 1992 when it had twelve tags.  Oh, and you windows programmers?  You too.  This replaces EVERYTHING - Windows "ActiveX" and web.  It's global!  Yay.  Replaces Flash even - WPF and XAML run Silverlight.  Rah.  I can't even hide my excitement.

So why am I upset?  Well, I like HTML.  It does what I need.  But I understand that it doesn't fill 100% of what people want, and XAML with WPF probably will.  Problem is when you make a tool that meets everyone's needs, it becomes unusable.  As that say the docs are 'tl;dr;: 'too long; didn't read'.  There are hundreds of options - in HTML there are a few dozen.  Some say that constrains creativity, I think it enhances it.  To each their own.

Polymorphic animation.

Anyway, it's a technology that the biggest software company in the world has embarrassed so I should learn it right?  Right.  There are at least two ways to put text in the viewable area - the letterBox, which we are using for the Game Piece, and the textblock.  The TextBlock is what is needed for the Wow! animation.

One of the nice things about XAML is that it is polymorphic.  Polymorphic is the property of being able to be context sensitive.  If you have a fruit class, and there is a Fruit.Peel method, a polymorphic Peel method will know that you take the skin from a banana, take the seeds out of a pomegranate and don't bother with a grape unless you are making pie.  (No really.  My stepmom just made a grape pie last month.  It was yummy.)

I am pontificating and this is supposed to be a liveblog of a project.  Let it be said that you can apply an animation to an object, and they are truly polymorphic.  Therefore, we have a textblock, and we want to apply two animations to it.  The animations will automagically treat the textblock properly, thus showing us their polymorphic nature.

Enough of that

I want a flying 'Wow'.  To do this, I need to animate two properties: the scale of the block, and the opacity of the text.

There are two ways to implement an animation in WPF.  You can use a storyboard in XAML, which is more of a Microsoft Expression thing to do, or you can apply the methods in code, which is what I want to do.  This is a VB blog, after all.

To animate the scale, I have to add an empty ScaleTransform object to the TextBlock.

<TextBlock x:Name="wowTextblock" Opacity="0" Foreground="Green" HorizontalAlignment="Center" VerticalAlignment="Center" Text="Wow!" Visibility="visible">
    <TextBlock.RenderTransform>
        <ScaleTransform></ScaleTransform>
    </TextBlock.RenderTransform>
</TextBlock>


This isn't necessary with the Opacity animation because the Opacity is already a property of the TextBlock.  I know that Width and Height are too, but scaling them isn't.  I suppose I can get behind that.  Anyway.

To animate the block, I am going to make two DoubleAnimation objects, and then BeginAnimation them one after another.  The Opacity I can directly apply, but the Scale I have to go get from the XAML and then set a few properties for.  I packed the whole thing into a subroutine I called ShowWow.  I will replace the old MessageBox.Show with a call to the new ShowWow method.  Here is the code:

    Public Sub ShowWow()
        'Make an animation for the scale
        Dim wowAnimation As New DoubleAnimation(0, 100, New Duration(New TimeSpan(0, 0, 3)))
        'Make another for the opacity
        Dim wowOpacity As New DoubleAnimation(1.0, 0.0, New Duration(New TimeSpan(0, 0, 3)))
        'Go grab the ScaleTransformation from the XAML and se tthe properties
        Dim wowTransform As ScaleTransform = DirectCast(wowTextblock.RenderTransform, ScaleTransform)
        wowTransform.CenterX = 11
        wowTransform.CenterY = 7
        wowTransform.ScaleX = 1
        wowTransform.ScaleY = 1
        'Then run all of the animations
        wowTransform.BeginAnimation(ScaleTransform.ScaleXProperty, wowAnimation)
        wowTransform.BeginAnimation(ScaleTransform.ScaleYProperty, wowAnimation)
        wowTextblock.BeginAnimation(TextBlock.OpacityProperty, wowOpacity)
    End Sub

Of course, you can download the whole thing from the codeplex site for the project.  Next time, we'll handle missed letters, and then call it a project.  Have fun!  I hope this is being some help to those working in WPF.

Live blogging a XAML project with CodePlex, Part Duex

And we are back at the Letters Are Falling project, which has it's own Codeplex URL now ... heh.  If you remember from the last post, we need to

  1. Randomize the letter.
  2. Randomize the start position right to left.
  3. Make it more fun when you win.
  4. Handle it when you lose.

I am going to start with the first two.  For now, I am going to keep this pretty declaritive, and try and use the WPF objects 'correctly' later once I get the bugs worked out of the logic.

Let's add two functions: one for the left randomization and one for the letter randomization.  The left randomization needs to set the left margin anywhere from zero to the width of the window minus the width of the letterBox.  The letter randomization needs to pick from a selection of letters, which we will later make configurable.

Now, certain other things have to happen to make this a game.  It has to restart when you get the right letter, keep score, things I forgot in the original requirements.  In order to do this, I have to set up the game to reset the letterbox, and not have all of the code in the form load event.  To do this, I have built a new function to set up the letterbox, which calls the two new randomization functions.  Then I can change my keypress event to make some gametime decisions, including a Quit function.

The VB file now looks like this:

   1:  Class gameBoard
   2:      Public WithEvents gameClock As New DispatcherTimer
   3:      Private letterBoxTop As Double = 0
   4:      Private letterBoxLeft As Double = 0
   5:      Private scoreCount As Integer = 0
   6:      Private Sub gameBoard_Loaded(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles MyBase.Loaded
   7:          SetupLetterBox()
   8:          gameClock.Interval = New TimeSpan(0, 0, 1)
   9:          gameClock.Start()
  10:      End Sub
  11:      Private Sub SetupLetterBox()
  12:          letterBoxLeft = GetLeftMargin()
  13:          letterBoxTop = 0 - letterBox.Height
  14:          letterBox.Margin = New Thickness(letterBoxLeft, letterBoxTop, 0, 0)
  15:          Dim currentLetter As String = GetLetter()
  16:          letterBox.Content = currentLetter
  17:      End Sub
  18:      Private Sub LetterPress(ByVal sender As System.Object, ByVal e As System.Windows.Input.KeyEventArgs) Handles MyBase.KeyDown
  19:          If e.Key.ToString.ToUpper = letterBox.Content.ToString.ToUpper Then
  20:              gameClock.Stop()
  21:              scoreCount = scoreCount + 1
  22:              MessageBox.Show(String.Format("You got it!!{0}Your score is {1}!!", vbCrLf, scoreCount))
  23:              SetupLetterBox()
  24:              gameClock.Start()
  25:          ElseIf e.Key = Key.Escape Then
  26:              MessageBox.Show(String.Format("Goodbye!{0}Your score is {1}.", vbCrLf, scoreCount))
  27:              MyBase.Close()
  28:          End If
  29:      End Sub
  30:      Private Sub ClockCheck() Handles gameClock.Tick
  31:          letterBoxTop = letterBoxTop + 10
  32:          letterBox.Margin = New Thickness(letterBoxLeft, letterBoxTop, 0, 0)
  33:      End Sub
  34:      Private Function GetLeftMargin() As Integer
  35:          Dim result As Integer = 0
  36:          result = (New Random().Next) Mod CInt(gameBoard.Width - letterBox.Width)
  37:          Return result
  38:      End Function
  39:      Private Function GetLetter() As String
  40:          Dim result As String
  41:          Dim lettersList As String() = {"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z"}
  42:          Dim listIndex As Integer = (New Random().Next) Mod lettersList.Length
  43:          result = lettersList(listIndex).ToString
  44:          Return result
  45:      End Function
  46:  End Class

In the next edition of Live Blogging a XAML project, we will get into a little more of the XAML itself, including getting rid of the messagebox, and adding a little pizzaz!  Until next time...

Bill Sempf

Husband. Father. Pentester. Secure software composer. Brewer. Lockpicker. Ninja. Insurrectionist. Lumberjack. All words that have been used to describe me recently. I help people write more secure software.

PageList

profile for Bill Sempf on Stack Exchange, a network of free, community-driven Q&A sites

MonthList