Toolbox

Easy Wiki Hosting, Scott Hanselman's blog, and Snagging Screens

Scott Mitchell

Contents

Hosting a Wiki
Blogs of Note
Capture, Edit, and Share Screenshots
The Bookshelf

Hosting a Wiki

A wiki is a Web application whose content is collaboratively added, updated, and organized by its users. As is the case with blogs and other content management systems, a wiki's content is editable through a Web page interface. What separates wikis from blogs and traditional content management systems is that wikis are inherently amorphous. The site's users create the content, define the relationships, and establish the links between the site's Web pages. Perhaps the most well-known wiki is Wikipedia.org.

Wikis are especially useful for creating knowledge management portals. Within a company, a team of developers may maintain a wiki that includes information about ongoing development projects and their status, coding conventions, and tutorials for new hires on how to set up a baseline development environment.

A customer-facing support site could include a wiki allowing trusted support staff to proactively create and manage answers to commonly asked questions. And many community-oriented sites include wikis to allow members to update the site or contribute to the knowledge base. For instance, the open-source code projects hosted at CodePlex.com are managed as a wiki.

There are a variety of commercial and open-source wiki platforms available. One open-source wiki created with ASP.NET and C# is ScrewTurn Wiki version 2.0. By default, ScrewTurn Wiki's pages, modification history, and user accounts are saved on the Web server's file system, meaning the wiki does not require a database. Consequently, deploying ScrewTurn Wiki to a Web server is as simple as copy and paste.

But the wiki's storage system is built atop the provider model, so you can plug in an alternative provider to persist system information elsewhere. You'll find SQL Server® and MySQL storage providers at the ScrewTurn Wiki Web site.

When it is first installed, ScrewTurn Wiki allows anyone to create an account and any authenticated user to create, edit, or delete content. These access levels can be restricted through the wiki's administration pages.

Visitors may be barred from registering, or may require the approval of an administrator before being able to log in. And administrators can limit what user actions are allowable; for instance, the site can be configured to allow users to create and edit pages but not delete them. Of course, like other wikis, ScrewTurn Wiki maintains a complete history of every page modification with tools to compare different versions. And administrators can roll back a page to a previous version.

ScrewTurn Wiki enables content to be created and displayed in multiple languages, with support for English, French, Spanish, and German, among others.

Price: Free, open source.

screwturn.eu

fpo.mitchell.toolbox.screwturn.gif

Open-Source ScrewTurn Wiki (Click the image for a larger view)

Blogs of Note

Reading other developers' source code is a great way to hone your own programming skills, as it introduces you to different techniques for accomplishing common tasks. This sentiment is shared by Microsoft Senior Program Manager and prolific blogger Scott Hanselman, who reads source code like ordinary people read the newspaper. He shares some of the most interesting code he's read—along with commentary—in a series of blog entries titled "The Weekly Source Code."

In addition to "The Weekly Source Code," every developer should take the time to peruse Scott's Ultimate Developer and Power Users Tool List (hanselman.com/tools)—an expansive list of tools and utilities Scott uses on a day-to-day basis. There are hundreds of recommendations categorized by topic—from working with XML to Visual Studio® productivity enhancers to managing your e-mail inbox and getting the most out of your Web browser. The Ultimate Developer and Power Users Tool List was inaugurated in 2003 and has been updated annually since.

In addition to his frequent blog posts, Scott hosts "Hanselminutes," a weekly audio podcast. There Scott reviews developer tools, dispenses programming advice, and shares war stories. Sometimes he interviews prominent Microsoft staff and members of the Microsoft® .NET Framework dev community. The podcasts are great for your commute to and from work, as each episode is approximately 30 minutes long.

Blog: hanselman.com/blog

Podcast: hanselminutes.com

Capture, Edit, and Share Screenshots

During a typical work day, I take upwards of a dozen screenshots. While most of them are for a blog entry, article, or book I'm working on, I also send screenshots to coworkers or customers.

Often it's easier to send a screenshot of a flawed UI than try to explain the problem in an e-mail. With Windows®, the Print Screen key copies the current screen, while Alt+Print Screen copies the current window. You can then paste the screenshot into an e-mail message, an image editing program, or a Microsoft Office Word document.

I recently decided I needed to upgrade from the Print Screen key to a more robust screen capture technique and decided to check out TechSmith's SnagIt version 8.2, which was first reviewed here in July 2003. A lot has changed since 2003. SnagIt has an updated user interface, many more image editing tools, and the ability to save to a number of new file formats.

SnagIt can take screenshots of a user-defined region, of a specified window, or of the entire screen. And when capturing a scrolling window, SnagIt can be configured to automatically scroll through the document, thereby capturing its entire contents in one image. This is especially helpful when capturing lengthy Web pages.

After capturing the window or selected region, SnagIt loads the screenshot into a powerful editing and sharing tool. With a few clicks of the mouse you can add text, draw shapes, cut and move regions, highlight areas, define border colors and widths, and add callouts. The dimensions of the screen capture can be further tweaked by trimming, resizing, or rotating the captured image.

More advanced tasks, such as adding watermarks, spotlighting or magnifying important regions, and adding hotlinks, are possible as well. Best of all, SnagIt is straightforward and easy to use—you don't need to be a digital imaging expert.

Once the screenshot has been edited, sharing it is as easy as clicking a button. There are one-click options for saving the capture as an image, copying it to the clipboard, printing it, sending it via e-mail, sending it via FTP, sending it via Instant Messenger, and loading it into a Microsoft Office Excel®, Word, or PowerPoint® file.

In addition, they can all be saved to a variety of file formats. Along with standard image formats such as BMP, JPG, and PNG, SnagIt can alternatively save your screen captures as PDF documents, Web archive files (.MHT), or Adobe Flash files, which are also new capabilities in this version.

Price: $39.95 per single-user license.

techsmith.com/screen-capture.asp

mitchell.toolbox.snagit.gif

SnagIt Has an Updated User Interface(Click the image for a larger view)

The Bookshelf

Querying data is one of the most common tasks a programmer faces. Yet interfacing with different data types requires learning unique syntax and semantics; and querying external data sources, such as XML files and databases, typically involves serializing query constructs to a string.

Because the compiler cannot parse a string literal like it can parse code, features like IntelliSense® and compile-time type checking are unavailable. To remedy this, Microsoft created LINQ, which offers developers a unified data querying syntax. LINQ extends the C# and Visual Basic® programming languages to include a rich, SQL-like syntax that can be used to query collections of objects, XML documents, databases, and more.

LINQ is made possible thanks to a number of new language enhancements and several new namespaces and classes in the .NET Framework. Because of the breadth and depth of the topic, to really learn LINQ you'll need more than a few online articles. One LINQ book, which explains the various facets through rich examples that build on previous chapters, is LINQ in Action by Fabrice Marguerie, Steve Eichert, and Jim Wooley.

LINQ in Action presents one of the best introductions to LINQ I've read, walking readers through its purpose and design goals and the language enhancements added to C# and Visual Basic that make LINQ possible. The book then looks at LINQ to Objects, LINQ to SQL, and LINQ to XML, which are libraries that enable LINQ queries against objects, relational data, and XML data. The book's last two chapters examine how to extend LINQ to query alternate data sources (such as Web services) and how to best utilize LINQ at different layers in your application's architecture.

What I liked best about LINQ in Action is how the authors start each new section with straightforward, easy-to-follow examples that highlight the most important features. Next, they pull back the curtains and show how the LINQ queries and features are actually implemented.

With the groundwork in place, the authors move on to more advanced features and scenarios. For example, the chapters covering LINQ to SQL start with setting up the object mapping and using the DataContext class to read and update data. Then they look at how LINQ's query syntax is translated into T-SQL. It concludes with advanced LINQ to SQL features, such as concurrency control, using stored procedures and user-defined functions, and so on.

Price: $44.99.

manning.com

mitchell.toolbox.linqinaction.gif

Send your questions and comments for Scott to toolsmm@microsoft.com.

Scott Mitchell, author of numerous books and founder of 4GuysFromRolla.com, is an MVP who has been working with Microsoft Web technologies since 1998. Scott is an independent consultant, trainer, and writer. Reach him at Mitchell@4guysfromrolla.com or via his blog at ScottOnWriting.NET.