Backtalk

James Van Eaton
Microsoft Developer Network

If you're from the West coast, you've probably seen those used-car commercials starring the cowboy-wannabe owner, dancing around in a powder blue suit with an exotic animal. In the background, a guitar-playing fool would sing cute anapestic lyrics extolling the virtues of using his services. And if you were lucky enough, you might even have seen his show, Cal's Corral, which consisted of hours of country/western music entertainment interspersed with a generous amount of his own commercials. What a delightful treat those were!

Well, the MSDN advertising budget doesn't allow for television commercials, and even if it did, the only animals we could scare up would be the rooster and hen pair that roam the Microsoft campus—not exactly exotic. So instead, we'll leave it to current subscribers to tell you what you're missing out on if you don't subscribe to MSDN. At the next programming-related user group, special interest group, conference, or Internet newsgroup you find yourself in, ask a current MSDN subscriber what they think of the program. I am certain we will like what you hear!

But enough about us, let's talk about you. What do you think of us? Just kidding… As they say, "without further ado, let's start the show!"

Control Freak

The recent Tech·Ed special edition of the MSDN News featured the launch of the new MSDN Subscriber Downloads Web site, which is available to current Professional and Universal subscribers in Africa, Canada, Europe, the Middle East, and the United States. With this site, we were able to make the final release of Windows 98, Plus! 98, and Windows NT Server 4.0, Terminal Server Edition available for subscriber download before shipping on CD.

As exciting as that is, several people reported problems when trying to download software from the site, using the site's requisite ActiveX download control that allows interrupted downloads to resume where they left off. Please visit www.microsoft.com/msdn/downloads/subscriberfaq.htm if you are experiencing difficulty with the control, or having any problems at all with the site.

GUI Gaffes

Skye Gulke of Friese, Mississippi, wrote in to ask, "I am starting to write my first application (using Visual Basic) and I have some questions regarding where certain controls should be displayed. For instance, should the Open and Close buttons be placed in my custom dialog box?"

The design of your software's interface, more than anything else, affects how a user experiences your product. There are many books, articles, and Web sites on the subject of good (and bad!) UI design. I encourage you to start with a Microsoft publication titled The Windows Interface Guidelines for Software Design, an indispensable guide to designing software that runs with the Windows operating system. This book is available in the MSDN Library in the "Books" bin.

Getting back to the question at hand, where should you put the buttons? The Guide suggests you "stack the main command buttons in a secondary window in the upper-right corner or in a row along the bottom."

Sizing Up DHTML

DeeDee Solomon of Manchester, New Hampshire, writes: "If you're like me, you like to have your screen resolution at 1152 x 864 when you surf the Web so you don't have to do a whole lot of scrolling. But I come across more pages that have been 'hard coded' for an 800 x 600, or even worse 640 x 480 screen. Isn't there a way for Web masters to detect my resolution and adjust the page accordingly?"

Well, this isn't exactly MSDN program feedback, but since you took the time to write, I'll take some time to answer since this is a pet peeve of mine, too. Yes indeed, using DHTML's screen object, a Web page can learn your screen's current resolution. This little bit of code shows how:

<script language=javascript>
document.write("Your screen resolution is " + screen.width + " x " + screen.height)
</script>

Now that the information is known, the page could either reformat itself using DHTML, or it could call an Active Server Pages (ASP) file from the server, passing the screen resolution as a parameter in the URL. I'll leave its implementation as an exercise for the reader!

OK, that wraps up this edition of Backtalk. As always, if you have any questions, suggestions, praise, or other feedback about the MSDN program, or if you just want to see your name in print, send e-mail to us at msdn@microsoft.com. To find out about how to subscribe to MSDN, visit http://www.microsoft.com/msdn/.