Thursday, September 11, 2003

fun at Venice Beach

I am in LA visiting a client. They had a company picnic yesterday so I had the day off. I went to Venice beach for a few hours. Venice beach is very nice. It was bitter-sweet.

It gave me a chance to evaluate goals and priorities and sort of meditate while listening to the ocean. I love the ocean. I love the sound and the smell.

As I traveled west of Venice Blvd. I ....

Friday, September 05, 2003

How to ask a question?

I have written a couple of books and from time to time I get asked questions.
Most times these questions are pretty vague.

Jame Peterson knows how to ask a question.

He wrote me a little document that walks me through his environment. Pretty cool.

BTW I was still not able to really answer his question. It works on my box not on his.

Response

But at least I was able to try.

Wednesday, September 03, 2003

crazybob.org - web log

crazybob.org - web log

BeanShell 2.0 looks really cool. Read what Crazy Bob wrote about it.

Tuesday, September 02, 2003

Will program Swing for remodeling.... (one day of my labor day)

I had a relative help me with some remodeling... Putting up some cabinets, hanging curtains and such. In exchange I helped his wife with a little problem at work.

I took some Excel spreadsheets that they used to track some billing data. I converted the highly unnormalized data from the Excel spreadsheet to a normalized set of database tables. I had to write a script in Python that would clean up the redundant data and arrange it into normalized tables (this was the longest part). I have to admit; I love this type of programming.

I then wrote a simple GUI to track items to bill. You enter in the serial number of the item, it shows its picture plus a list of maintenance parts. You just pick the part and the qty and hit add. Simple, but fun to write. I wrote it all in Swing.

It took me one day to write the data normalizer and the GUI.

You can add an optional date field (it defaults to today). I used the InputVerifier so you can't leave the date field until you enter in a proper date. I use labels associated with components that have displayMnemonics to make navigation easy.

90% of the GUI is written in HTML (I know I said swing, but swing does HTML). I use an EditorPane with its content type set to text/html. This allows me to easily put up pretty pictures of the machines (the machine changes based on the serial number), the company logo, the vendor logo, etc. I wrote the whole thing in Jython (Python running in the JVM).

I have a text field to enter in the serial number.... as you enter in the serial number, it highlights the closest serial number in a list, once you get close entering in the 10 digit serial number, you can pick it from the list. Then it pulls up that product data in a editable view (with a picture of the machine and a list of parts you can change).

I have to admit programming in Swing was fun, and a nice break from programming in Struts.

I am a big fan of Jython. I guess that is why I wrote a book on it. (Based on the book sales, there aren't as many jython fans as I would like.)