Went to Reading. Won a Dell Mini netbook laptop courtesy of Intel. Drove there and back in a Mercedes. Awesome.
Daz! Come back!
June 23, 2009This is an open letter and public shout out to my mate Daz, aka The Dazzler, aka The D-Man, aka D-Dawg,* to return to his former blogging ways.
Daz, I know the lure of Twitter has been too much to turn down, what with it’s simple interface and enforced textual limit that seems so friendly in comparison to the behemoth of the blog… but you had so much good in you that was left unsaid. Sometimes good things need more than 140 chars.
So, come back, ye olde chappe, and speak henceforth those software development words of wisdom!
* Daz may, in fact, not actually be also known as these nicknames.
How to support wildcard email addresses in Exchange 2007
June 10, 2009If you need Exchange to accept wildcard email addresses, e.g.
fred*@domain.com
*fred*@domain.com
so that, for instance, mail sent to “hello_fred_how_are_you@domain.com” is routed to an appropriate mailbox (such as fred@domain.com), then you’ll need to write (as in program) your own Transport Agent.
1. Create your own SMTP receive agent. You’ll need Visual Studio 2005 or above and some programming ability.
2. Hook your agent up to the RcptCommandEventHandler and write the necessary code to examine the event’s RecipientAddress, and, if it meets your wildcard needs, replace the RecipientAddress with the destination mailbox.
E.g.
// If the recipient address contains “fred” then replace
// whatever it is with Fred’s real mailbox address.// Pseudocode:
if (event.RecipientAddress.LocalPart.ToLower().Contains(”fred”))
{
event.RecipientAddress = new RoutingAddress(”fred@domain.com”);
}
(Make sure you understand the implications for spam!)
3. Install your Transport Agent (a DLL) on the Exchange server using the Install-TransportAgent and Enable-TransportAgent cmdlets.
If you get any errors like:
Invalid agent configuration in file
when running the Transport Agent cmdlets, check the permissions on the agents.config file.
C:\Program Files\
Microsoft\Exchange Server\TransportRoles\Shared\agents.config
Temporarily give Full Control to the Everyone object on that file and see if that fixes the problem. If so, remove Everyone and find out who needs access to it!
4. Finally, and very importantly, make sure the priority of your new Transport Agent is lower than the Recipient Filter Agent.
Run the get-transportagent cmdlet to see all the agents and their priorities. Use the set-transportagent cmdlet to change your agent’s priority, and put it lower than the Recipient Filter Agent.
Otherwise the Recipient Filter Agent will execute before your new agent and it will reject the wildcard email addresses since they’re not valid. Your agent, if placed before the Recipient Filter, intercepts these invalid email addresses and changes them to the correct, valid addresses.
Classic programming question
June 8, 2009Hello All -
I need to do this: I need the exchange server to embed an image into each outbound email message, the image size is small (less than 50K).
I need to use a transport agent i have succesfully started up visual studio 2008 and copied the necessary dll files over, the refernces have also been loaded.
however at this point i think i would “Program” which i do not know how to do, is there a programmers manual that would explain in the necessary detail as to how to accomplish tihs?
Please advise…
(Emphasis mine; from here.)
Refactoring code into fewer lines does not necessarily reduce its complexity
May 20, 2009Developers are almost universally aware that they should try and write code that is simple to read and maintain. Complicated code can be a stumbling block for another developer (or even yourself at a later date) when he/she needs to fix bugs or modify functionality.
So refactoring existing code in an effort to reduce its complexity is definitely a good thing.
But refactoring code into fewer lines does not necessarily mean that its complexity has been reduced. In fact, the opposite can occur.
Take this example posted by an Intel blogger. While I fully agree that lambdas are awesome, and I eagerly await them in C++0x, I don’t agree with his assertion that the lambda version of his example is simpler. Regarding his first non-lamda version, he concludes, “The code is indeed complex. It contains too many lines and three methods.”
Certainly the first example has more lines than the lambda equivalent. But on its own I wouldn’t call the first example complex at all. It has a function event handler for the control, a function for the thread, and a function for the UI callback.
The lambda version just puts the thread function and callback function into anonymous functions inside the control’s event handler.
Syntax-wise, I’d argue the lambda version is more complex than the first.
The Last Days of Copyright
May 19, 2009Via Slashdot: Sony Pictures Entertainment CEO Michael Lynton was recently quoted as saying, “I’m a guy who doesn’t see anything good having come from the Internet. Period.”
This quote was from a discussion about the future of filmmaking and obviously the internet, piracy and copyright.
I can understand Mr Lynton’s pain, being the CEO of a movie company that loses money due to piracy. But for better or worse (depending on your point of view), things have changed. In fact, I posit that there’s no going back.
Users have had a taste of the good life, and it’s sweet. They won’t accept an 88 mph Delorean-inspired drive Back to the Past.
Sure, BitTorrent traffic could be disabled. Communities and web sites can be sued and taken offline. But the posse will just move on to a new system, like they’ve done previously.
Instead of complaining, Sony et al should be coming up with solutions to embrace the new media distribution world that consumers have moved into.
Here’s a distribution model which I came up with a few years ago and will happily publish for free:
Bob visits the Fox web site and can browse every TV show & movie that Fox has ever produced. Bob pays $1 to download a high-quality episode of the Simpsons with no adverts and no DRM, and can copy and watch it on whatever devices (TV, computer, iPod) that Bob likes.
Alternatively, Bob can watch the whole episode for free (via a stream), but with local adverts included. Similar for movies.
Admittedly, songs are a bit tricker, but iTunes does well with its current system. It’s mainly TV and movies that need to play catchup.
Will Bob pay the $1 and then share the high-quality episode on BitTorrent? Maybe. But piracy won’t be anywhere as prevalent as it is right now. The majority of users will happily visit Fox and legally watch the episode for free (with ads).
Why? Because consumers simply want to watch their favourite shows/movies. Their goal isn’t piracy; it’s to watch their shows. They hate waiting to see their favourite shows, especially when they know it’s already aired somewhere. They don’t want to wait 6-12 months for a U.S. show to appear on their local TV stations.
And they don’t want to miss an episode because they forgot to set the VCR/DVD/HDD recorder.
With this model, the consumer definitely wins. The creator/content owner wins too, since they’ll get revenue either by ads or by direct payment. Who loses with this new model? The middle-man TV networks. If consumers can buy (via ads or directly) their shows from the creators, then Bob doesn’t need BBC1 or Channel 7 or whoever. Likewise with cinemas.
But that just presents a new challenge and opportunity for the TV networks and cinemas. They’ll certainly have to work hard to entice consumers to watch their TV networks or visit theirs cinema rather than going direct to the content creator web sites. But so what? Competition is good. Cinemas didn’t die after video/DVD stores came out.
People will pay for quality, which is why even today with massive screens and surround sound systems, people still enjoy (some) cinemas.
So to Sony et al, I say: Come on! We’re here waiting, ready to pay (or watch ads) whenever you’re ready.
Casillero del Diablo 2007 Cabernet Sauvignon
May 18, 2009
I’m delighted to report that the Hendo Wine Rating (HWR) has gone global! To date only Aussie wines have had the honour of a HWR, not because of any xenovinophobia (TM) on my part, but simply due to the abundance of great wine in Australia.
With my relocation, however, I now have countless European wines on my doorstep.
But I’m going to skip Europe and head first to South America.
Casillero del Diablo is a cab sav from Chile which we enjoyed recently with friends. It originates from the Central Valley appelation and apparently contains hints of mocha and dark chocolate, though I’m not sure how to distinguish between them.
By now, though, I can distinguish between rubbish and good wine, and fortunately this falls into the latter category.
HWR: 4/5
Conversations with Dell
March 10, 2009Me:
I want to connect my laptop to my LCD monitor via the DisplayPort, but I can’t find any cables/adapters. Nothing came with the laptop and I can’t find any DisplayPort accessories on the Dell web site.
Dell:
First of all, I apologize for the difficulties you have experienced, and I can certainly understand your frustration. Please be assured that I am concerned with the problems you are having with your computer and wish to resolve them within the shortest period of time.
VGA cable is not available so what I can suggest is you can get or purchase VGA cable from any computer stores. Any VGA cable will due.
Me:
I’m sorry I don’t understand what you mean.
I don’t want to use the analog VGA connector. How can I connect with the DisplayPort connector? Why does the laptop have a DisplayPort output if Dell doesn’t supply any cables or adapters (even to buy) to use it with?
Dell:
First of all, I apologize for the difficulties you have experienced, and I can certainly understand your frustration. Please be assured that I am concerned with the problems you are having with your computer and wish to resolve them within the shortest period of time.
Your system is working fine. The only question is that why a VGA cable was not provided where the notebook has a VGA port. Your system is working properly. The reason why it does not come with a VGA cable it is because the notebook has its LCD built-in, no need for an external monitor. The reason why it has a VGA port, it is for enhancement where you can connect a projector or external monitor which is only optional.
Me:
Thanks for your reply but I don’t think you understand my question.
My laptop has the following display outputs:
* VGA
* HDMI
* DisplayPort
I’m not asking about the VGA port or a VGA cable. I understand how to connect a monitor using VGA or HDMI. What I’m asking about is DisplayPort.
http://en.wikipedia.org/wiki/Displayport
I want to connect my laptop to an LCD monitor via the DisplayPort output. Or, to put the question another way: Why does the laptop have a DisplayPort output if there is no cable to use it with?
Dell:
First of all, I apologize for the difficulties you have experienced, and I can certainly understand your frustration. Please be assured that I am concerned with the problems you are having with your computer and wish to resolve them within the shortest period of time.
I understand what your query is. What I am trying to explain is that Dell systems especially notebooks does not come with third party cable if it is an optional peripheral. Not all Del users uses the display port, so it is an option for the customer to get or purchase a display port cable upon system purchase.
In your case, you can purchase a display port cable from any computer store.
Me:
Thanks for your reply. I understand that it’s an optional peripheral, but I cannot find anyone in Australia who sells a DisplayPort cable. That includes the Dell Australia web site. Do you know of any computer stores that sell them?
Dell:
First of all, I apologize for the difficulties you have experienced, and I can certainly understand your frustration. Please be assured that I am concerned with the problems you are having with your computer and wish to resolve them within the shortest period of time.
Display port cable is not yet mass produced because there are limited monitors using it. Display port came with Dell systems is an advantage on your part. As of the moment monitor manufacturers are still working to have a display port. Display port cable will be available soon. I apologize I cannot provide information where you can purchase a display port cable.
Posted by neilhendo
Posted by neilhendo
Posted by neilhendo