The January 2003 Blog
send me a comment

Bookmarking My Blog (Friday, Jan 31)
[ permalink ] [ e-mail your comments ]
Ah, the end of another month, and almost time for a new set of blog entries.

Just in case you've been bookmarking this particular page for the blog (http://www.nsftools.com/blog/blog-01-2003.htm), please note that it won't roll over to the February blog unless your bookmark is for http://www.nsftools.com/blog. The /blog page actually serves as a redirection to the current month's blog page, which isn't exactly how other people do it, but that's how it's done here.

I set it up that way because when someone sees something they like on one of the blog pages and wants to send a link to their friends, they generally just cut-and-paste the URL that's in the address bar of the browser and use that for the link (I know, that's why I have permalinks -- the little :: that appear next to the blog entry titles -- but some people don't use those). I wanted to make sure that if someone sends a link to this particular page, that the link will still be relevant after this month is over.

Also, I've been asked why I don't just make my home page the blog page, instead of making people click over to the /blog page. Well, I started off this site mainly as a resource for tools and tips, with the blog as a secondary feature. In my mind, I guess I can't really let go of that notion, even though the blog page gets a majority of the hits and takes a large part of my time. Maybe someday I'll relent and change the home page to the blog page, but for now when people come to the home page I still want them to know about all of the non-blog aspects of the site as well. And if the blog keeps you coming back, well that's great! I enjoy writing it, and I hope you enjoy reading it.

Okay, enough about me. See you in February.


Random Java Links (Thursday, Jan 30)
[ permalink ] [ e-mail your comments ]
Hope everyone had a good time at LotusSphere this week. Do they still call it that? Or did they go ahead change the name to WebSphereSphere to bring it in line with the corporate strategy? (Just kidding, of course -- and by the way, I know that it's really spelled "LotuSphere", but I hate that spelling, so I'll keep spelling it the way I spell it.)

Anyway, here are a few random links for you, all coincidentally having to do with Java:

That's all for now. Have a good weekend.


It's the Fries that'll Kill Ya (Wednesday, Jan 29)
[ permalink ] [ e-mail your comments ]
This has nothing to do with technology, but I just read this little bit in the local weekly (which most of you probably don't have access to) and thought you ought to know:

According to Greg Critser, whose new book is "Fat Land: How Americans Became the Fattest People in the World," a serving of McDonald's French fries "ballooned from 200 calories (1960) to 320 calories (late 1970's) to 450 calories (mid-1990's) to 540 calories (late 1990's) to the present 610 calories."

Yikes! You may as well order an extra double cheeseburger.


RSS Feed (Tuesday, Jan 28)
[ permalink ] [ e-mail your comments ]
I finally sat down and wrote an agent to produce an RSS feed for my blog last night (see the link to your left, or just click here). Wasn't too hard once I started, thanks to tips by Mike and Ben and Johan -- I get by with a little help from my friends. A lot of the time it took was just test-validate-test-validate, as I added new things or made small format changes (like getting the <pubDate> date format just right -- turns out all your dates have to have times).

So now what? I guess I need to find a few sites to register with, and then I need to go through this article at unganisha.org to figure out how to do an XML-RPC ping when the blog/feed changes. Seems like a lot of work to let people read the blog without visiting my site. I thought I wanted people to actually visit my site... Oh well.


Java Tips Database (Sunday, Jan 26)
[ permalink ] [ e-mail your comments ]
As promised on Friday, I just posted a Java Sample Code Database for you to download and use for your coding pleasure. It's a compilation of code and information that I use on a fairly regular basis, and it should help get you started if you're still learning Java. Heck, even if you've been coding Java for a while, there might be one or two things of interest in there for you. And if nothing else, it will give you a good framework for keeping track of your own Java tidbits.

Hope that helps...


Have Fun at LotusSphere (Friday, Jan 24)
[ permalink ] [ e-mail your comments ]
To all you lucky people who are heading to Orlando next week, have fun at LotusSphere! I'm really jealous. Maybe someday I'll get to go too. In the meantime, I'll guess I'll just be checking to see what the attending bloggers are saying about it (like the LotusSphere Gonzo Page and the Inside the 'Sphere diary).

I'll probably be spending my weekend following up on my earlier comments about learning Java by getting together a samples database for you that contains some bits of Java code to help get you started. Probably not a lot, but I figure I should at least give you a few samples to further whet your appetite. I mean, it's really not fair that I suggested you go forth and code Java without giving you one or two examples.

Speaking of earlier comments, I just saw the "Java is cack" family of comments on Mike's site (not made by Mike, of course) and decided to ignore them. I don't have the time to go back and forth with people about whether Java is worth learning or not. I think it is, and frankly if other people don't think so, that's fine with me. I'll probably be contending with them for a job in a few years, and we'll see how the chips fall. And what's "cack" anyway?

On a completely unrelated note, here's an interesting piece about using an empty Pringles can as a wireless Yagi antenna (I originally read a reference about this here on the BBC site). Not that I'm approving of war driving or anything, but I'm just amazed at what you can do with trash sometimes.


Behind the Times (Wednesday, Jan 22)
[ permalink ] [ e-mail your comments ]
Man, I'm behind the times. I'll probably lose a lot of respect by 'fessing up to this, but I'll go ahead and throw it out there anyway.

First, everyone seems to be talking about their RSS feeds as of late (Ben, Mike, Johan, and others). Man, I've got to get me one of those. And here I thought people still visited actual websites to read content -- I know next to nothing about the dark world of RSS aggregators. I'll add it to my huge list of future site enhancements.

Second, I was watching the Lord of the Rings Extended Version with my Dad this past weekend, and he was telling me about this easter egg he found on the DVD. "Easter eggs on DVDs?" I asked. I had no idea. I knew about software easter eggs, but DVDs? And then he pulled out a book he had that listed all sorts of easter eggs on a bunch of DVDs I already had: the Matrix (Special Features - Continue - on the second page choose "Follow the White Rabbit" mode and watch the movie again, hitting Enter whenever you see a rabbit), Star Wars Episode 1 (enter 1138 at the Options menu), Harry Potter (way too detailed to reproduce here, but there are 7 bonus videos and deleted scenes in there somewhere). I felt like I had been living in the dark, not knowing about all these things. I'll have to do a Google search and see what the Internet can tell me about DVD easter eggs.

(By the way, I didn't mean to leave you hanging about Lord of the Rings. On disk #1 of the Extended Edition DVD set, go to "Select a Scene", then go select the screen for scenes 25-27. At the bottom of that screen, there's a legend that says "* new scene ** extended scene". You can actually select the "* new scene" option on that screen. When you do, you get to watch an MTV-version of the Council of Elrond scene, starring Jack Black and Sarah Michelle Gellar. Pretty amusing.)


Why You Should Learn Java (Tuesday, Jan 21)
[ permalink ] [ e-mail your comments ]
A question I get asked a lot is: why should Notes developers learn and use Java? Why not just use LotusScript, which is built-in and is perceived to be faster? Well, since I do a little Java pushing on this site, and I've asked myself that same question dozens of times, here's my answer (in the form of a list):

1. Documentation and Examples
Go ahead, walk into a bookstore and look at the shelves and shelves of Java books. Now try to find the Lotus Notes section. Now compare the number of Internet sites about Java versus the number about LotusScript. There is a lot more information about Java than there is about LotusScript out there, and when you're in a bind you'll need as much reference material as possible. And look at all the classes you can download.

2. Source Code Availability
Along those same lines, there's no comparison between the amount of Java source code and LotusScript source code available in books, magazines, and the Internet. Examples are often your best teachers.

3. Communication with Other Products
Java is a very common means of communicating with other non-Notes products. Sure, you can sometimes use COM or ODBC or something similar instead, but Java is becoming a more common connector. Think WebSphere on this one.

4. XML
Java is much easier to use for XML processing than LotusScript is, and XML is something you'll end up using (or wanting to use) at some point.

5. Sockets
With LotusScript you can do a few things with Windows sockets using API calls, but it's not even close to what you can do with Java. And Java is cross-platform.

6. Threads
Once you start understanding threads, they come in very handy.

7. AWT
This one is a little bit of a trade-off, because LotusScript allows you to use a Notes form as an input box, but the Java AWT provides a very rich set of UI tools. You can even do things like cross-platform progress bars with the AWT, for example.

8. Applets and Stand-Alone Applications
While applets should generally be used with care, the ability to write stand-alone applications with Java is an attractive prospect. And if you have DIIOP running on your Domino server, you don't even have to have Notes installed on the client machine to be able to access remote Domino data.

9. Respect
Tired of non-Notes developers turning up their nose when you talk about programming in Notes? If you can whip their butts with some solid Java code, that'll make them take a little more notice. As much as you probably don't want to admit it, you'll get a lot more respect in many circles by talking about the Java you're writing than the LotusScript agents you're working on.

10. Your Resume
And with respect comes job opportunities. Maybe you don't want to be a Notes developer forever. Maybe you see the WebSphere tidal wave about to crash down on your head and you need to learn to swim. Maybe you just want a better range of development opportunities to choose from. Whatever the reason, you've always got to be thinking about keeping your resume current. Learning and using Java is a good choice.

...

Now, I'm not saying this as some kind of Java guru (I'm only a mediocre Java programmer) or as some guy who only writes agents in Java (LotusScript is still my bread and butter), just as one developer to another. Something to think about, anyway.


New Computer (Monday, Jan 20)
[ permalink ] [ e-mail your comments ]
Just started setting up my new computer today (yippee). Unfortunately, this also means I'm in driver download hell right now (rats). More blogging action for you tomorrow, once I'm a little more set up with the new system.

In the meantime, here's an article you can read to pass the time: How to re-use Domino sessions in Java servlets.


Reading XML Nodes with Java (Friday, Jan 17)
[ permalink ] [ e-mail your comments ]
Just added Domino References to my updated links list (and here's a link to the Babelfish translation, if your French is as poor as mine is). It's a French Notes news aggregator, similar to Christopher Arras' News4Notes. A great way to pick up the daily or weekly happenings of the online Domino community.

Also, a little more spring cleaning here: I posted a Java XML NodeReader class that allows you to easily filter and step through the element nodes of an XML document, so you can process the information with less code in your Java applications.

The class is fully compatible with the XML4j.jar package that's used by default by Notes Domino Java agents, so you can drop the code in an agent for a little added functionality within Notes (I tested with R5, but not 4.6 or ND6 -- not sure if there are any compatibility problems with non-R5 versions of Notes, but I know it also works with the 1.3 version of the JDK in stand-alone applications, for what that's worth). In fact, the reason why I wrote the class is because there's no TreeWalker class packaged in with XML4j.jar, and that seemed like a nice thing to have in an agent.

So grab the code, paste it into a Notes agent, and have at it. And if you haven't done anything with XML yet, now's your chance to start!


Updated Links (Thursday, Jan 16)
[ permalink ] [ e-mail your comments ]
I updated my links page today (I know, big fat hairy deal...). Please tell me who I forgot.


Java ProgressBar (Wednesday, Jan 15)
[ permalink ] [ e-mail your comments ]
Do you need a progress bar for your Java Notes agents? I just posted the source code for a ProgressBar class that creates a non-modal dialog with a progress bar that can be updated as your process runs. And I only used the java.awt.* classes, so you can just drop it right in to a Notes agent, no extra packages required (in fact, the source code/sample I provided is a Notes agent).

And once you've played with that, if you still want some more Java to play with, try out a game of Java Pong.


DxlScript Extract Update (Monday, Jan 13)
[ permalink ] [ e-mail your comments ]
I just updated the How to Extract LotusScript from a DXL Document tip and posted some new code for you. The original tip used JDom and Xerces to parse the DXL, but it occurred to me that someone might want to put this code into a Notes agent, which would make the JDom and Xerces dependencies a little awkward.

So, nice guy that I am, I retrofitted the Java source code to use the native Node functionality provided with the XML4j.jar package that ships with Notes. Now you can paste the code right into an agent and expect it to work without any additional packages. This meant I also had to write my own Base64 decode method in Java, so if you're looking for one of those you can find it here too (always trying to help).


Can You See Me Now? Good... (Saturday, Jan 11)
[ permalink ] [ e-mail your comments ]
I don't do any kind of exhaustive testing of my site for cross-browser compatibility, but I usually at least try to take a look with IE, Netscape, Opera, and Phoenix, just to make sure the pages aren't totally out of whack. Here's one I hadn't thought about before though: cell-phones.

I was looking through my server logs, and saw that someone had accessed my site with a cell-phone a few times last month. Seemed kind of crazy, but then I got more and more curious about what this site would look like on a WAP device. So I surfed around and found the free Deck-It WAP Emulator so I could check it out on my PC (I'm not one of those fancy rich kids who carries an Internet-enabled cell-phone or PDA, unfortunately). Surprisingly, the site was pretty manageable. Not great, but nothing that's going to make me undergo any huge re-design for the sake of that one person who decided to read the blog while they were driving to work.

Now I guess I'm going to have to find someone who's got that new Safari browser that everyone's talking about...


Early Spring Cleaning (Wednesday, Jan 8)
[ permalink ] [ e-mail your comments ]
I decided that one of the things I needed to do this year was to try and publish more of the "old" information I've got laying around, because it's not doing anyone any good just sitting here on my machine (that's sort of an open-source argument, isn't it...?). After all, one of the reasons I started this site in the first place was to do a partial "brain dump" from time to time. So in the next couple weeks, if I stick to my resolution, you may see some really old-looking links or random information popping up on the site. This seeming lack of direction is just a little early spring cleaning on my part.

Here's my first example: a quote I snipped from a John Dvorak article a little while back that I can't seem to find a good reason to use. So I'll just drop it right here in the middle of the blog:

"To summarize, Mr. Godavari saw an obvious cycle in the life of user groups in general. They all begin with experts getting together to learn things collectively, followed by business people joining to leverage the information, followed by never-ending newbies just there to get as much free help and tutoring as they can get. Once the newbies become the majority, they drive out the other two groups. Essentially the groups lose the true leadership base, become brainless, and eventually die off. Much of this is because of a natural conflict that will develop between the technologists who founded the group and the seemingly lazy newbies who try to exploit and dominate the technologists."

I just think that's a great observation, and in this new Internet society you can see that happening a lot on the online forums too (LDD in some respects, although there is still lots of activity there). I wonder if that's why there have been so many new Domino blogs popping up over the past several months (mine included)? Maybe people are getting frustrated with the constant "URGENT! How do you read a field on a document?" questions in the forums and are looking for more intelligent discussions about Notes, Domino, and related technologies.

Hmm, I guess if I had a comment form on this site, you could let me know what you think. For now, e-mail will have to do. Or an entry in your own weblog. :)


Another Blog Template? (Tuesday, Jan 7)
[ permalink ] [ e-mail your comments ]
Looks like Workflow Studios may be entering their own contender in the Lotus Notes blog template dog-fight. In this little announcement they mentioned that they are soon-to-release their "Studio Blogs" template for Notes. Their approach is interesting, as they're talking about "blog administrators" and maintaining multiple blogs (as opposed to being geared towards a single blog from a single user).

The "other" templates right now are, of course, the FreeDom Blog and Jake Howlett's DomBlog. I wonder when we're going to see a blog template on OpenNTF?


API Correction, SOAP Tester Tool (Monday, Jan 6)
[ permalink ] [ e-mail your comments ]
It seems that the new year will start out with small correction to the site. Normunds Kalnberzins visited the API Tips page and noticed that I had the wrong LotusScript conversions for int (should be Long, not Integer) and HANDLE (not a Long on all operating systems). He certainly knows what he's talking about, and I appreciate all the help I can get. By the way, he's got a great introductory tutorial about calling the Notes API from LotusScript on his site...

Also, I just posted a SOAP tester tool for you to take a look at. It's a Java application (source code included) that allows you to send raw SOAP requests to a server and view the SOAP response that comes back. It also has the ability to send the requests through a proxy server, if that's how your environment is set up. And to get you started in a hurry, I even included some sample SOAP requests that you can send to a few public servers to see how it all works.

If all goes well, I'll have even more SOAP stuff for you in the coming weeks.