Almost ADSL
Posted on 2 Jul 2002 at 17:04
Dave Jewell awaits his ADSL installation with both fear and excitement, and shows how to access the Shell32 COM objects from C#
After several weeks of upheaval, my family and I are now established in our new home in North Wales. As a consequence, I'm now within striking distance of an ADSL-enabled telephone exchange. Judging from the tales of woe I've heard on Cix, getting sorted out with ADSL, a cable modem or broadband can be even more traumatic than the house move, so I figured I might as well get the two over with in one sitting.
I'll keep you posted on how things go (or don't go) with my ADSL experience. I'm looking forward to being able to download the latest Windows 2000 Service Pack before being interrupted by the heat-death of the universe. But on the downside, the flood of publicity about Internet hacking suggests that equipping myself with a broadband connection just provides a faster means of access to unwelcome intruders.
Certainly, anyone using an always-on connection needs to kit themselves out with a decent firewall. And if you take the option of a static IP address and run a low-volume Web site via your ADSL connection, there are even more perils in store, such as the dreaded DoS (Denial-of-Service) attack. For a harrowing description of what can happen, check out Steve Gibson's account at http://grc.com/dos/grcdos.htm. I knew these things existed, but I wasn't aware how hackers combine the forces of several hundred PCs, each running a hidden bot, to bring a Web site to its knees. Scary stuff.
At any rate, I hope that my forthcoming ADSL connection will be faster than the sales of Borland's new Kylix. Borland had the opportunity to generate phenomenal sales with Kylix because it's the first decent RAD development tool for the Linux platform, but instead it tried to charge silly prices. Sales were, in fact, so desperate that the company has slashed the price of the Desktop Developer Edition from £620 to a more reasonable £139. This offer finishes at the end of August, so it may be almost over by the time you read this. However, I'll be surprised if Borland doesn't announce permanent reductions when it finishes. For more details, see www.qbss.com
Not unnaturally, this move has enraged those who've already paid £620 and, if this has happened to you, Borland will give you a free upgrade to the Server Developer Edition. It remains to be seen what effect these moves will have on Kylix sales and I'd like to know just how much interest there is in Linux development among readers. Please let me know whether or not you have any plans that involve Linux.
Using Shell objects from .Net with C#
While waiting for Visual Studio .NET Beta 2 to arrive, I've been playing around with the COM interoperability features built into .Net. Even if you've never done any COM programming before, there's nothing to be afraid of, as I'm about to show you. For this tutorial, I chose to make use of the various COM objects built into shell32.dll, not just because you're bound to have this file on your PC, but also as there's a lot of useful stuff in it.
I began by creating a brand-new C# project, and then went to the Add Reference item on the Build menu, which allows you to choose either .Net or COM items and add them to your project. You need to choose the COM tab and find 'Microsoft Shell Controls and Automation' from the list that appears. Once you've chosen this DLL and added it to your project, you're ready to have some fun. I placed a simple push-button on my form and added the following code to the button's Click event handler:
Shell32.Shell sh = new Shell32.Shell();
advertisement
- What's that eggy smell in the server room?
- How to change the default template in Word 2007
- Book review: Rework by Jason Fried and David Heinemeier Hansson
- Panorama parents deserve their file-sharing fine
- Google and BT offer free website service to British businesses
- Lords' last chance to protect broadband customers
- Extreme handwriting recognition on the Dell Latitude XT2
- 12 surprising things that Wolfram Alpha knows
- Nokia N900: phone or pocket computer?
- The sinister side of Spotify
- Government puts biologist in charge of broadband
- ISPs forced to advertise average speeds in US
- US pumps billions into broadband plan
- Lords snub last chance to help broadband customers
- Core Tory voters "the last to get super-fast broadband"
- BT brings ADSL2+ to 150 more towns
- Website-blocking law was "copied" from BPI
- Small businesses "need a minimum of 8 meg broadband"
- Tories: next Google should be British
- Virgin to deliver rural broadband via telegraph poles
advertisement







Printed from www.pcpro.co.uk