Do you work with ASP.NET? Take 2 hours to learn AJAX!

We have just released a FREE 2-hour clinic to learn about the rich functionality that ASP.NET AJAX Extensions provides for building highly responsive and enhanced web applications. In addition to learning about the different server and client components of ASP.NET AJAX, you will also learn how to build new ASP.NET AJAX applications and how to upgrade existing ASP.NET applications to take advantage of ASP.NET AJAX.


This clinic is appropriate for experienced .NET Web Developers and Software Architects who are looking to incorporate ASP.NET AJAX within their existing and future solutions.


Enjoy!

MOSS – Configuring In-Coming Emails ‘Error in Application’

This has been one of the toughest assignments for a while due to the lack of error
details. No eventlog and no AD or MOSS Logs.

Basically setting up In-coming Emails works like this:
1) the MOSS Server in the farm will poll a SMTP ‘drop’ directory (usually c:\inetpub\mailroot\drop).
So mail has to find its way to that drop directory.

2) The Sharepoint Directory Management Service will (if told to) go and automatically
create ‘entities’ (contacts) and assign them email addresses in the OU specified below.
That’s the theory!!

The DM causes a couple of issues – you’ve got to run the site under an acct. that
has access to the OU (you may need to assign assign the appropriate permissions to
the OU in AD for this user)

The DM creates these Contacts by supplying a Schema full of info and this inturn creates
the Contact. Problem – what if your AD schema doesnt match what DM expects…..“Error
in Application!”

(This took me the longest – as I had this running in 5 mins on a client site and then
on a different site….no go)

The schema ‘additions needed’ for the DM to work ‘seemlessly’ are added when you install Exchange2003/2007
the initial parts of the install are ForestPrep and DomainPrepI
ran these on their own without installing Exchange and the DM worked a treat!!!


(I’m sure you’d be able to add the appropriate schema extensions 1 by 1 without the
need for Exchange and then be able to run any mail server – but which ones?)

3) Within Central Operations setup the incoming emails to be something like this:

My server is called MOSS and it’s part of the LITWAREINC
Domain

3) Now under site settings you can easily enable Incoming emails

 

 

 

Feb 28th BTSUG – Indepth Examination of BAM and BAM APIs

Examining BAM and BAM APIs 

Wednesday, 28th February 2007
6:00 PM Food and Drinks, 6:30 PM Kick Off
1 Epping Road, Microsoft
North Ryde, Sydney

Hi all, we’re back at Microsoft North Ryde this month with a great presentation on
BAM – Business Activity Monitoring. What information are you getting out of your
running Business Processes? Averages, durations and things like Mins and Maximums?
You should be and it’s all relatively easy and quick.
I’ve provided a calendar appointment for your calendars so join me.

Presenter:


Mick Badran, BizTalk MVP who specialises in Microsoft Technologies
as a Solutions Architect/Developer. With over 15 years consulting experience and 11
years as a Microsoft Certified Trainer provides in depth real world knowledge.

Session Details

Using BAM is something that can be vital to the business and even BizTalk operators
to identify within the context of a business process – “How is the BizTalk process
going?”, “How long does it on average take for an Order to be fulfilled?” etc.

How hard or easy is it to extract this from your current system?

We will cover exposing your business data from your running business processes.
This session will cover the setting up of BAM but more importantly focuses on BAM
Relationships and Continuations tying together various separate units of work that
relate to the overall business process. The session will also cover BAM APIs and the
new BAM interceptors within Windows Workflow Foundation.

Non BizTalk can also take advantage of BAM through the BAM APIs, giving a comprehensive
view of all the subprocesses within a busness process.
Mick will cover the following aspects:

  1. BAM and BAM fundamentals

  2. BAM enabling your BizTalk processes

  3. Event streams and Interceptors – is this BAM or Star wars?

  4. Using the BAM APIs both internally within BizTalk and from
    external applications/services.

  5. Automating BAM deployments.

As always love to hear from you and what’s been getting you excited at work.

Who Should Attend?


If you’re looking to get additional business related information out of your Biztalk
processes then this session is for you.
This session is technically focused for Biztalk developers and Application Architects.
Please be sure that you RSVP so we know how many to expect. Reply with a yea
or ney to mickb.NOSPAMFORME@NOSPAMbreezetraining.com.au

Looking forward to seeing you there at Microsoft Premises – North Ryde

Mick and Mark 

Ph: 0404 842 833 (Mick’s mobile)
SydBiz.Org

Moving from MCMS to MOSS 2007 Web Content Management (WCM)

I thought I’d share some terminology changes for those of you that are MCMS descendants.

MCMS Term -> Now we Say….
Channels -> Windows Sharepoint Sites
Postings  -> Pages
Templates -> Page Layouts or Master Pages
Placeholder -> Field Control
Template Definition -> Content Type
Template Gallery -> Master Page and Page Layout Gallery
Resources Gallery -> Images, document, site collection images, or Site Collection
document Library
Resources -> Images or Reusable Documents

Stay tuned for more….

Gravatar is back!

With

version 1.9 of DasBlog, which I run here, comes the ability to support Gravatar’s

out of the box. What are “Gravatar’s” you ask? Simple, a Gravatar is a small image

(80×80 pixels) hosted by Gravatar.com which

a site can request of you given your email address. This allows blogs, for instance,

to show an avatar of your choosing next to your comment without having to personally

handle you uploading the file, trimming the image, storing the image, screening the

image for “appropriateness”, and so on.

Gravatar’s have been around for a while, but for over a year they have not allowed

new people to sign up for the service because they had reached the capacity of there

existing infrastructure. Well they’ve completely redesigned for scalability and are

back with style. You will see now that my recent responses to comments include my

ugly mug as an avatar next to my comments, and if you’d like your face immortalized

then all you have to do is go to this site and request an account of your own. Once

you do, you’ll instantly have you’re chosen Gravatar available here, no more work

required provided you left an email address with your comment.

The Gravatar team has a blog here so you can

keep track of what they are doing.

Break the Habit : Nested If Statements

It is time to break some bad habits, and today we take some code written by a man

I like (but who will remain nameless and linkless) that is in desperate need of refactoring.

But this problem is not a problem exclusive to this very bright developer, it is a

bad habit that we as an industry have picked up somewhere along the line and I’m here

to say “Stop The Insanity!”.

Consider the following code:


               1:

              if (_privateDataObject.Methodology

!= null)

               2: { 

               3:

              if (_privateDataObject.Methodology

== "00") 

               4: { 

               5:

              if (_privateDataObject.Amount

!= null)

               6: { 

               7:

              if (IsNumeric(_privateDataObject.Amount)) 

               8: { 

               9:

              if (Convert.ToDecimal(_privateDataObject.Amount

)==0 ) 

               10: { 

               11: bReturnValue = true; 

               12: } 

               13:

              else

            

               14: { 

               15:

            

               16: bReturnValue = false; 

               17: } 

               18: } 

               19:

              else

            

               20: { 

               21:

            

               22: bReturnValue = false; 

               23: } 

               24: } 

               25:

              else

            

               26: { 

               27:

            

               28: bReturnValue = false; 

               29: } 

               30: } 

               31:

              else

            

               32: { 

               33:

            

               34: bReturnValue = false; 

               35: } 

               36: } 

               37: 

               38:

              return bReturnValue;

.csharpcode-wrapper, .csharpcode-wrapper pre {

background-color: #f4f4f4;

border: solid 1px gray;

cursor: text;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

margin: 20px 0px 10px 0px;

max-height: 200px;

overflow: auto;

padding: 4px 4px 4px 4px;

width: 97.5%;

}

.csharpcode-wrapper pre {

border-style: none;

margin: 0px 0px 0px 0px;

overflow: visible;

padding: 0px 0px 0px 0px;

}

.csharpcode, .csharpcode pre, .csharpcode .alt {

background-color: #f4f4f4;

border-style: none;

color: black;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

overflow: visible;

padding: 0px 0px 0px 0px;

width: 100%;

}

.csharpcode pre {

margin: 0em;

}

.csharpcode .alt {

background-color: white;

}

.csharpcode .asp {

background-color: #ffff00;

}

.csharpcode .attr {

color: #ff0000;

}

.csharpcode .html {

color: #800000;

}

.csharpcode .kwrd {

color: #0000ff;

}

.csharpcode .lnum {

color: #606060;

}

.csharpcode .op {

color: #0000c0;

}

.csharpcode .preproc {

color: #cc6633;

}

.csharpcode .rem {

color: #008000;

}

.csharpcode .str {

color: #006080;

}

This decision weighs in at over 38 lines. Let’s look at what the warning signs in

this method should have been that it needed to be coded differently.

The first and most important is that this follows a very basic pattern we see in code,

we are seeking for single complex condition and want to return a “true” if we find

it, and “false” in all other cases. This pattern is so basic it is taught in every

Intro to Programming course ever. The pattern has a common name “Boolean AND” and

is a part of every language (that I know of) on the planet. Refactored to accomidate

for this pattern we end up with :


               1:

              if (_privateDataObject.Methodology

!= null &&

               2: _privateDataObject.Methodology == "00" && 

               3: _privateDataObject.Amount != null &&

               4: IsNumeric(_privateDataObject.Amount) && 

               5: Convert.ToDecimal(_privateDataObject.Amount ) ==

0) 

               6: {

               7: bReturnValue = true; 

               8: } 

               9:

              else

            

               10: { 

               11: bReturnValue = false; 

               12: } 

               13: 

               14:

              return bReturnValue;

.csharpcode-wrapper, .csharpcode-wrapper pre {

background-color: #f4f4f4;

border: solid 1px gray;

cursor: text;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

margin: 20px 0px 10px 0px;

max-height: 200px;

overflow: auto;

padding: 4px 4px 4px 4px;

width: 97.5%;

}

.csharpcode-wrapper pre {

border-style: none;

margin: 0px 0px 0px 0px;

overflow: visible;

padding: 0px 0px 0px 0px;

}

.csharpcode, .csharpcode pre, .csharpcode .alt {

background-color: #f4f4f4;

border-style: none;

color: black;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

overflow: visible;

padding: 0px 0px 0px 0px;

width: 100%;

}

.csharpcode pre {

margin: 0em;

}

.csharpcode .alt {

background-color: white;

}

.csharpcode .asp {

background-color: #ffff00;

}

.csharpcode .attr {

color: #ff0000;

}

.csharpcode .html {

color: #800000;

}

.csharpcode .kwrd {

color: #0000ff;

}

.csharpcode .lnum {

color: #606060;

}

.csharpcode .op {

color: #0000c0;

}

.csharpcode .preproc {

color: #cc6633;

}

.csharpcode .rem {

color: #008000;

}

.csharpcode .str {

color: #006080;

}

From 38 lines down to 14, not bad. And this version is not even as short (in line

count) as it could be in favor of readability (spreading the expression across multiple

lines) and to include braces (which are optional with only 1 command).

Now that we’ve tamed the wild nested if, let’s look at another problem. Why set a

value, only to immediately return that value once you’ve decided on the result? Just

return the value immediately. This small win nets us the following code:


               1:

              if (_privateDataObject.Methodology

!= null &&

               2: _privateDataObject.Methodology == "00" && 

               3: _privateDataObject.Amount != null &&

               4: IsNumeric(_privateDataObject.Amount) && 

               5: Convert.ToDecimal(_privateDataObject.Amount ) ==

0) 

               6: {

               7:

              return

              true; 

               8: } 

               9:

              else

            

               10: { 

               11:

              return

              false; 

               12: } 

.csharpcode-wrapper, .csharpcode-wrapper pre {

background-color: #f4f4f4;

border: solid 1px gray;

cursor: text;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

margin: 20px 0px 10px 0px;

max-height: 200px;

overflow: auto;

padding: 4px 4px 4px 4px;

width: 97.5%;

}

.csharpcode-wrapper pre {

border-style: none;

margin: 0px 0px 0px 0px;

overflow: visible;

padding: 0px 0px 0px 0px;

}

.csharpcode, .csharpcode pre, .csharpcode .alt {

background-color: #f4f4f4;

border-style: none;

color: black;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

overflow: visible;

padding: 0px 0px 0px 0px;

width: 100%;

}

.csharpcode pre {

margin: 0em;

}

.csharpcode .alt {

background-color: white;

}

.csharpcode .asp {

background-color: #ffff00;

}

.csharpcode .attr {

color: #ff0000;

}

.csharpcode .html {

color: #800000;

}

.csharpcode .kwrd {

color: #0000ff;

}

.csharpcode .lnum {

color: #606060;

}

.csharpcode .op {

color: #0000c0;

}

.csharpcode .preproc {

color: #cc6633;

}

.csharpcode .rem {

color: #008000;

}

.csharpcode .str {

color: #006080;

}

From 14 to 12, not bad, and even less un-needed code. The final refactoring is based

on the fact that this code is searching for a boolean value using boolean expressions.

That means that to reach true “ruthless” refactoring we should end up with the following:


               1:

              return _privateDataObject.Methodology

!= null &&

               2: _privateDataObject.Methodology == "00" && 

               3: _privateDataObject.Amount != null &&

               4: IsNumeric(_privateDataObject.Amount) && 

               5: Convert.ToDecimal(_privateDataObject.Amount ) ==

0;

.csharpcode-wrapper, .csharpcode-wrapper pre {

background-color: #f4f4f4;

border: solid 1px gray;

cursor: text;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

margin: 20px 0px 10px 0px;

max-height: 200px;

overflow: auto;

padding: 4px 4px 4px 4px;

width: 97.5%;

}

.csharpcode-wrapper pre {

border-style: none;

margin: 0px 0px 0px 0px;

overflow: visible;

padding: 0px 0px 0px 0px;

}

.csharpcode, .csharpcode pre, .csharpcode .alt {

background-color: #f4f4f4;

border-style: none;

color: black;

font-family: consolas, ‘Courier New’, courier, monospace;

font-size: 8pt;

line-height: 12pt;

overflow: visible;

padding: 0px 0px 0px 0px;

width: 100%;

}

.csharpcode pre {

margin: 0em;

}

.csharpcode .alt {

background-color: white;

}

.csharpcode .asp {

background-color: #ffff00;

}

.csharpcode .attr {

color: #ff0000;

}

.csharpcode .html {

color: #800000;

}

.csharpcode .kwrd {

color: #0000ff;

}

.csharpcode .lnum {

color: #606060;

}

.csharpcode .op {

color: #0000c0;

}

.csharpcode .preproc {

color: #cc6633;

}

.csharpcode .rem {

color: #008000;

}

.csharpcode .str {

color: #006080;

}

Final result, 5 lines of code, same functionality. Important note to the Visual Basic

developers out there, && is the equivalent of “AndAlso” in VB, not simply

“And”, hence why this code does not blow up with a NullReferenceException.

I implore every developer reading this to get into the habit of considering how to

refactor code as soon as you’ve got it working, and I mean on a method by method basis.

Even if you’re not using a “TDD” methodology, this is a very good habit to get into

because every time we change code we’ve introduced the chance to improve either the

readability or performance of the code as well. It is natural to reach “working” code

and want to move on, but spending 10 minutes to examine how you got it working will

pay off in the long run, I assure you.

BizTalk 2006 R2 Bootcamps are here!



Hi all I could start telling you about how great this bootcamp is and how you’re going
to get some much out of it, but I wont.
I could fluff on about different technologies you’ll learn and integrate with such
as WinWF and WCF as well as CBR within BizTalk 2006 R2. Not stuff from text books
but real world experience – we know what works and doesnt.

I could talk about the ‘bigger’ question – “What makes a good/great design?”, “Is
that a ‘good’ solution?”…or does it just limp by?
I dont even want to talk about how when you come out you’ll know why and where you’ll
be using WinWF and what BizTalk does for you. You’ll also be very excited about the
huge range of different messaging options available to you implementing WCF Services….but
hang on! Doesnt BizTalk 2006 R2 expose WCF Services? Why should we host our WCF Service
in BizTalk versus hand coding? When to hand code?

You’ll also get a solid understanding of the BizTalk environment and we’ll chat about
pipelines, when a promoted property is not a promoted property. How Biztalk processes
messages and performance, also let’s have a crack at developing custom functoids,
pipeline components and even adapters.

We’re Business Process and Integration experts let’s kick some tyres together.
Through these bootcamps, we’re going to share that knowledge with you …..the big
question is: Are you ready for it?

Overview:

This 4-day workshop provides developers with the tools to upgrade their 2002/4 skills
and perform advanced orchestrations and training partner management.

You will learn to use BAS and SSO, practice developing, managing and customizing adapters
and creating custom pipeline components, all within BizTalk rules.

This workshop also explores the new features of BizTalk 2006 R2 including developing
& consuming WCF Services (Windows Communication foundation) for BizTalk.

Target Audience:

Developers and IT professionals with previous experience working with BizTalk 2002/2004
.Net development. (Level 300/400)



Prerequisites:


Before attending this workshop, students should have some experience with previous
versions of BizTalk and .Net development skills.

Skills Gained:

This four day workshop will focus on:

1. Upgrading your skills from 2002/2004 to BizTalk Server 2006 R2. Connected Systems
Roadmap to BizTalk 2006 R2.
2. Perform advanced orchestrations.

3. Gain an understanding of Workflow with in-depth hands-on scenario labs. Assess
the difference between Windows Workflow and BizTalk orchestration engine.
4. Take advantage of Trading Partner Management using BAS.
5. Utilise SSO – store sensitive configuration data securely.
6. Develop and manage adapters (e.g. WCF adapters)
7. Create custom pipeline components.
8. Create custom adapters. (e.g. Split messages)
9. Create and work with Rules for the BizTalk Rules Engine.

Key Topics:

Module 1: Create and perform advanced orchestrations
This module covers:-
Creating Correlated Orchestrations (e.g singletons, serial/parallel convoys)
Creating and utilising Message Context Based Promoted Properties
Creating Messages based on advanced classes/types.
Creating Direct Bound Orchestrations and exploring the relationship with the MessageBox
Database.
Creating Generic Content Based Routed Orchestrations
Utilising Dynamic Ports and Role Link Shapes – the easy way.

Module 2: Creating Rules, Trading Partners and SSO
This module shows you how to create rules based on:
Schemas, static classes and databases.
Rules Engine comprehensively explained, including the difference to Windows Workflow
Rules Engine.
Calling Rules from Orchestrations and Custom Applications
Registry keys that control Rule/Rules Engine Performance
Explore the relationship with Trading Partner Management and BizTalk Server 2006 R2.
Including:
Setting up and creating Partners.
Creating custom Partner Parameters used in Processes
Utilising Partners Inbox/Outbox from within BizTalk 2006
Further Trading Partner integration – RoleLinks explained.
Taking advantage of SSO within solutions.
SSO under the covers.
Using SSO and the SSO APIs to store/retrieve secure configuration information.

Module 3: Exploring and Creating Adapters – Advanced
This module will take you through exploring and creating adapters out of the box as
well as how to create your own. A lap around WCF (Windows Communication Foundation)
and customising WCF adapters.

Working with the provided Adapters (e.g. MSMQ, Sharepoint, SQL & SOAP Port)
Working with some community Adapters
Integrating with SQL Server 2005 Service Broker

Module 4: Creating custom pipeline components
This module will examine pipelines and take you through creating your own custom pipeline
components.

Module 5: Windows Workflow Foundation
This module will introduce Windows Workflow and take you through the architectural
concepts right through to building a workflow. Includes extending workflows with custom
activities, why custom activities are important, when to write and how to build. In-depth
hands-on scenario labs in this module.

Module 6: Investigating BAM and BAM APIs
This module examines Business Acitivity Monitor (BAM). We look at BAM enabling your
BizTalk Solutions including Related Activities. We cover setting up BAM Observation
Models and working with the BAM APIs to “BAM Enable” your non-BizTalk Applications
(e.g. WebServices)

Module 7: Optimising Performance & Deployment
We look at examining your performance and creating the optimum environment.
Determining the maximum throughput of your BizTalk Solution
Configuring your BizTalk environment for maximum performance
Troubleshooting – where to start, examining & resolving issues.
Creating deployment scripts to fully deploy your BizTalk Solutions

What is better than 1 offline newspaper to read on the Plane? 4 Offline Newspapers ;)

What is better than 1 offline newspaper to read on the Plane? 4 Offline Newspapers ;)

Tim broke the news this morning, the Daily Mail in the UK, forbes.com and the Seattle Post-Intelligencer have joined the New York Times in releasing WPF based news reading applications.



From my inital checks it looks like Forbes is the only reader that has opted not to ask you to register to use it. This is interested as I discussed in my presentation at foo camp. The web has set a precedence that you will be provided information without providing an identity and hence most newspaper websites don’t require you to log in. By providing a reader with a richer user experience the papers are able to request an identity (people are used to providing this for client applications like itunes, IM and email). The advantage here is that the papers are able to deliver more targeted advertising to their readers. Forbes appears to have gone against this trend and provide the data to the reader (no identity required).


From my initial investigations it still appears like the Times Reader is the most feature rich (with advanced search, note taking, emailing and saving or articles).


That said there is a great new accessibility feature in the Daily Mail called “Speak this article”… this goes further than the news in pictures feature of the times reader.



The Seattle Post-Intelligencer also released a sidebar gadget (above) to launch the articles but compare that to the TVNZ and nzherald ones… IMO it needs a bit of work!


This posting is provided “AS IS” with no warranties, and confers no rights.

What do these sites have in common?

Q. What do these sites have in common?


http://construction.dealsonwheels.co.nz


http://surfcamsbop.co.nz


http://www.tki.org.nz


http://everybody.co.nz


http://clubbizarre.co.nz


http://www.winkalotts.co.nz


http://www.muckmouth.com


A. They all won best of category awards at the hitwise award ceremony last night in Auckland.


First of all as a proviso there were a large number of great New Zealand websites showcased at the awards ceremony last night and it is great to see the industry coming together to celebrate success. Well done to Hitwise for organising this!


I want to drill down a little bit into the format of the awards and talk about how sites with house hold names like  trademe, tvnz, nzherald and xtra were placed next to niche sites in thin categories with no differentiation.


“The data samples featured are from the Hitwise Online Competitive Intelligence Service, which bases its daily insights on the online usage and search behavior of more than 460 thousand Internet users in New Zealand.”


Loosely translated… Hitwise gets their data from buying Internet logs from ISP’s. 


With Xtra and Trade Me getting in excess of 3 million unique user visits per month you must place hitwise as polling ~ 1/6 (maybe slightly more) of the total NZ internet users. As far as I’m aware some of the larger ISP’s (like Xtra) won’t sell their data to Hitwise which leads to an interesting trend. Call it the “hits from the niches of the long tail of internet users in New Zealand” ;).


All this said I personally had never heard or visted any of the sites I listed above… I was interested to check some of these out on Alexa to see where they ranked.


If you check Alexa for trademe.co.nz it places it as the 608th most popular site on the Internet (not bad!)… myspace.com for example comes in at number 6.


If you do the same check for muckmouth it places it as the 6,621,229th most popular site (wow!).


Trademe won the Auction section, Muckmouth won the Skateboarding and In-line Skating section. Together these sites were treated as equals at the awards but in reality they couldn’t be further apart!


All in all it was a good evening and I had a chance to chat with a number of interestign people. It was interesting to hear Chris Bayley BDM from Google speak at the event but come on “This year our keyword is jobs… we are opening a local office go to google and type in “google jobs” I would have thought that those were easy positions to fill!”.


Also another thing I was interested was how Google was gathering their customer quotes in the NZ market. I have been involved in this process myself… and was amused by this one that google produced in partnership with seek.


“Our traffic volume really skyrocketed once we placed site-targeted ads on YouTube.”


I guess this must be what they are talking about :).


This posting is provided “AS IS” with no warranties, and confers no rights.