MacBook, defective by design banner

title:
Put the knife down and take a green herb, dude.


descrip:

One feller's views on the state of everyday computer science & its application (and now, OTHER STUFF) who isn't rich enough to shell out for www.myfreakinfirst-andlast-name.com

Using 89% of the same design the blog had in 2001.

FOR ENTERTAINMENT PURPOSES ONLY!!!
Back-up your data and, when you bike, always wear white.

As an Amazon Associate, I earn from qualifying purchases. Affiliate links in green.

x

MarkUpDown is the best Markdown editor for professionals on Windows 10.

It includes two-pane live preview, in-app uploads to imgur for image hosting, and MultiMarkdown table support.

Features you won't find anywhere else include...

You've wasted more than $15 of your time looking for a great Markdown editor.

Stop looking. MarkUpDown is the app you're looking for.

Learn more or head over to the 'Store now!

Thursday, February 26, 2004

It's a pain getting all the pieces for X11 on OS X 10.2 together. Here's most everything you need all in one place:

Mac OS X 10.2 only: Installation of Apple Developer Tools and Apple X11(SDK)

In order to download the Developer Tools CD, you need to register a free account on Apple's Developer Connection. After registration, log in on Apple's Developer Connection and click on Download Software in the left menu and then on Developer Tools.

From there, download the files

* December 2002 Mac OS X Developer Tools (301.2M) and then
* August 2003 gcc Updater (19.1M)

Then, download

* X11UserForMacOSX-beta3.dmg(41.8M) and finally

* X11SDK-beta3.dmg(4.0M)


I understand that Apple might want to mimize support issues with older products, but come on. Why not keep the 10.2 X11 beta accessible? Yeah, yeah, so that you have to upgrade to 10.3. Guess I oughta start learning some XonX.

posted by ruffin at 2/26/2004 12:19:00 PM
Wednesday, February 25, 2004

I'm a pretty big fan of naming conventions, and have just been asked by a customer to explain what I use to their programmers. Just for the fun of documenting that my conventions are exactly just, "the random musings of the freakinname author", here's my source:

What follows are the Reddick .NET Conventions. The objectives of the conventions are to make code:

* More readable: Conventions allow a reader to understand the meaning of the code with less effort.
* More maintainable: The code can be more reliably changed to fix bugs and enhance functionality.
* More reliable: The code is more likely to perform as expected.
* More efficient: The code performs faster or consumes fewer resources.

The current version of these conventions can always be found on the Xoc Software web site: http://www.xoc.net.


Now admittedly I don't hold absolutely true to his suggestions, for example I usually use bBooleanVar instead of boolBooleanVar. Yet if you're using bool as a prefix, I certainly won't mind. The point is the general concepts of a sort of naming convention are being followed. Might also be useful to check out the same fellow's VBA naming conventions, which are a little more fleshed out, due to age if nothing else.

posted by ruffin at 2/25/2004 12:50:00 PM

PowerPoint Presentation

posted by ruffin at 2/25/2004 10:30:00 AM

At least there's an explanation of why Windows Update is telling me Bookshelf Symbol 7's update is critical in more detail than "The font has been found to contain unacceptable symbols":

Microsoft said on Friday that its latest version of Office software inadvertently contained a font featuring two swastikas, and said it would offer tools to remove and replace the offending characters from the program.

The swastika, which was made infamous by Nazi Germany, was included in Microsoft's 'Bookshelf Symbol 7' font.


Apparently the font's lineage starts in Japan, where, "A form of the swastika has been used in the Buddhist religion to symbolize the feet or footprints of the Buddha." Now MS is cleaning up the two swastikas from the font with a "critical update". I always thought the whole deal was that if the "twirl" was clockwise it meant one thing and counter-clockwise meant another (one's Buddhist, the other Nazi).

Strangely, the Star of David is another symbol in the set of fonts. Now that is odd. Doesn't really mesh with the whole "this is from Japan" excuse. Wonder how the font got put together?

The tilde ("~") is apparently one offender in the font.

Might be worth noting that the report linked to at WiredNews, above, is from 12/12/2003 and the fix was apparently to blast the font entirely (though I haven't rebooted, which might fix that issue. I'll be sure to update me via this blog when I find out).

In any event, certainly some strange future search terms popping up in freakinname this morning.

posted by ruffin at 2/25/2004 09:41:00 AM
Tuesday, February 24, 2004

Ha, if only I could aspire to the same great heights:

an interesting idea every three months; a posting every day

posted by ruffin at 2/24/2004 11:27:00 AM



I'm a pretty big fan (as any routinue freakinname readers lament) of immediately addressing small issues when programming, from smacking a reference in the log to changing the initial size of a form. It's important to spew out whatever quick insight you have -- providing it doesn't drop you from "the zone".

So, in the above example, I'm starting up a pretty sizable VB.NET app and I'm debugging some ADO.NET code. I think while it's starting that what I've got for the initial form's size is currently too big for 800x600, a fairly reasonable screen resolution, not just from a hardware standpoint, but also by virture of the fact that some people "like everything on the screen to be big".

I could keep tracking down my current issue and make a mental note to set the size later, but my best bet is to quit the app, drop back into the GUI RAD, and make the change now.

Obviously if you think of a two-hour, much less two-day, change, that's probably best placed on a TODO list -- even if it's just a TODO comment in your code. But address the insight immediately in any event. That's valuable info, and though I'd likely remember to change the Form size later, some more minute ideas can drop off the mental note list and get lost if you don't do something now.

More uninivited didacticism from freakinname. You're welcome. ;^)

posted by ruffin at 2/24/2004 11:04:00 AM
Monday, February 23, 2004

Here's a particularly insightful parallel for the state of Windows browsers:

Having MSIE bundled with Windows poses no problem for me... However, I dislike sites that require it. It's like mailing around text files that need Notepad to read... Rude.

Minus the fact that IE is on the desktop and Notepad isn't, that's a great parallel. IE isn't evil, of course. It's the love of IE that's evil. Sites that require IE, MS software that requires -- no, more properly doesn't require yet ties itself inextricably to IE through API calls are examples of either lazy programming or evidence of the Profit Maximization Machine.

That said, IE is a stink-out browser now. Nothing's really happened to it for years. All it does better than the competition is run ActiveX! Sorry. That's really an off-topic rant.

Anyhow, very good parallel. No problem to bundle a browser with your OS, but it is when something requires its use -- when the whole purpose of a browser (imo, etc) is to deliver standardized markup anyhow.


posted by ruffin at 2/23/2004 02:35:00 PM



Just installed Visio and upgraded MS Office on my work box today. I'll let you guess what my default browser had been set to when I rebooted. Would be more anti-trust fodder, if anyone was listening, but I think MS's gotten away with this one for the most part.

posted by ruffin at 2/23/2004 11:03:00 AM
Friday, February 20, 2004



Maximizing profit almost by definition means not maximizing customer and employee satisfaction. If you did everything I say you should do when you're coding as if each little hint was manna from heaven, you'd not only be a little wacky in the head but you'd also have only really dealt with one part of your business -- product and process quality. As I've said a number of times before, Microsoft seems to be a company with tons of great ideas run through a profit maximization machine, but that's not completely true. They get -- and keep -- some of the best and the brightest in the world (which I obviously am not, if only b/c I just used the overworked phrase "best and brightest").

One way of ensuring, as an officer of a company, that your customer is happy is by giving them a fair price, which might be less than you theorhetically can charge. One way of ensuring, as an officer of a company, that you'll retain your employees is by treating them fairly, which might mean working them less [hard] than you theorhetically could and paying them more than you theorhetically have to.

But when I get to the "why", it's not nearly so clean cut as when I spout off about programming best practices. Morality? Who knows. But I would encourage business owners with the ability to to make a healthy profit while not obsessing about making maximum profit.

End of random morality play.

posted by ruffin at 2/20/2004 02:05:00 PM
Thursday, February 19, 2004

Ah, SpeedScript 3.2 for the Commodore 64. This program is responsible for any number of my secondary school papers. Very nice word processor, and look at all the features!

It won't necessarily make you a better writer, but you may become a better writer once the tedium of retyping and erasing is replaced by the flexibility of a word processor. Words are no longer frozen in place by ink; they become free-floating entities. You no longer think about typewriting-you can stand back and work directly with words and ideas. The distinction between rough and final drafts becomes blurred as you perfect your writing as you write.

Crazy to think that 6k was a huge program and that people used to get magazines (myself included) and type in what was printed there. Actually more neat to me than crazy, but, then, I was alive then. ;^)

posted by ruffin at 2/19/2004 08:59:00 PM



What? You want to programmatically add a button to a VB.NET Windows.Forms Form/Panel/User Control and hook up an event handler? Heck, that's easy. Here we go. Start a new WindowsApplication and open up Form1 to the code view.

Paste in this:

Friend WithEvents cmdTemp As _
    System.Windows.Forms.Button = New Button

Private Sub cmdTemp_Click(ByVal sender As System.Object, _
    ByVal e As System.EventArgs) Handles cmdTemp.Click

    MsgBox("I've been clickified!!!")
End Sub

Private Sub Form1_Load(ByVal sender As System.Object, _
    ByVal e As System.EventArgs) Handles MyBase.Load

    Me.Controls.Add(Me.cmdTemp)
End Sub


Enjoy. For more form designerless goodness, make your canvas a PnlGridLayout. For ugly, generic UIs where you don't know what's coming ahead of time, using the Java-style GridLayout and adding things to the Form.Controls collection really is the way to go.

Even neater is when you hook up handlers with the AddHandler function, like this:

    Private Sub Form1_Load(ByVal sender As System.Object, _
        ByVal e As System.EventArgs) Handles MyBase.Load

        Me.Controls.Add(Me.cmdTemp)
        AddHandler cmdTemp.Click, AddressOf Me.genericButtonHandler
    End Sub

    Private Sub genericButtonHandler(ByVal sender As System.Object, _
        ByVal e As System.EventArgs)

        MsgBox("send all the button clicks you want here!")
    End Sub


You can use the AddHandler jive to hook that sub up to any button you make at any time, which is awfully useful stuff when creating buttons out of thin air.

posted by ruffin at 2/19/2004 02:13:00 PM
Wednesday, February 18, 2004



When you're done debugging please PLEASE don't get rid of your debugging code. It might look a little uglier, but for the most part it's going to be a good thing to leave it in. You might kludge it with a "if bDebugging Then Console.Writeline(strDebugInfo)" but keep it in there.

posted by ruffin at 2/18/2004 04:17:00 PM



One problem I see with object oriented programming as it's typically used today is that you can't have objects that have "required partners" in different tiers of your system.

In other words, let's say you've got a business logic tier that accesses your data services tier (the rdbms), and you want to hook up to a GUI in the presentation layer/tier. Well, you don't want, in theory, to have to have any one tier to build any of the others, at least not more than a stubbed reference API to build against (at the very least, you want the interdependence to be absolutely minimized before you can feel good about your design). So though the business tier object to presentation tier logic is often going to have a lot of one-to-one and onto patners, there's no mechanism to relate the partners that doesn't, in turn, require that you start building the two layers together. Though in theroy you want to be able to run the business tier on a box that knows nothing about what presentation tier might be accessing it, practically you'd like to give warnings if your system has a particular sort of GUI object without a correndsponding partner in the business tier and vice versa.

If you had this relationship, you could build a "contract-based interface" for your programming staff to build towards. "Do we have the UI for Function X? Check. Do we have business tier logic to pull in intialization values for Function X's UI? Check. Do we have clearly referenced relationships between each data column type between UI and what the business tier is pulling back? Hrm, we've got a compiler warning that we don't, though it'll still build, of course."

You could make your n-tier system three dimensional in structure and pass another layer of interfaces that helped tie that together, but it'd be difficult to do so without killing your compile. I'm just asking for structure to facilitate linkages without demanding them, pointing out where you may have failed in an implicit contract, and have generic code to help back up those holes.

posted by ruffin at 2/18/2004 02:50:00 PM



Some more Oracle SQL fun:

ALTER TABLE "SCHEMA_NAME"."TABLE_NAME"
ADD ("COLUMN_NAME" NUMBER(10) DEFAULT 1 NOT NULL)

posted by ruffin at 2/18/2004 10:32:00 AM

I guess this is at least part of why programming is fun.

Why is programming fun?

First is the sheer joy of making things. As the child delights in his mud pie, so the adult enjoys building things, especially things of his own design.

Second is the pleasure of making things that are useful to other people. Deep within, we want others to use our work and to find it helpful.

Third is the fascination of fashioning complex puzzle-like objects of interlocking moving parts and watching them work in subtle cycles, playing out the consequences of principals built in from the beginning.

Fourth is the joy of always learning. In one way or another the problem is ever new, and its solver learns something.

Finally, there is the delight of working in such a tractable medium. The programmer, like the poet, works only slightly removed from pure thought-stuff. He builds his castles in the air, from air, creating by exertion of the imagination. Few media of creation are so flexible, so easy to polish and rework, so readily capable of realizing grand conceptual structures.

-- extracted from 'The Mythical Man Month' by Fred Brooks


Of course, that doesn't much dwell on why it isn't. If there's one thing programming's not, it's lasting. Oh, sure, there's code from the 1960-80's that needed ye old y2k fix way back when that was still screamin' along while most new apps were written in whatever the latest and greatest language was. But most of us never get to work on such important apps, and those that do don't get to create it from scratch. And even if you did create an app that'd be used for decades from scratch, what happens as soon as you leave the company? Ever gone back to look at your code after someone else has grabbed it and changed it? "Ah, man, why did you do it like *that*? That's a kludge! You've lost reusability!" And that's usually a best case.

Let's face it, not even Fred Brooks comes close to William Shakespeare -- or even John Donne. Though people might start building interactive fiction that approaches literature on the backs of your work, nobody remembers who made Mark Twain's paper.

(That said, the pens he used in Mysterious Stranger helped scholars pinpoint (har har) where he wrote what part of what draft. Purple meant Europe, I believe, since that's where he got the pen, etc. Sorry, it's been over ten years since I researched that paper... :^D)

posted by ruffin at 2/18/2004 10:08:00 AM
Tuesday, February 17, 2004



Watch out for APIs (link muses about APIs in general, not bad ones) that show signs of Ivory Tower Syndrome. Take Swing as the worst case. You've got endless flexibility to create as complicated a model as you'd ever want, and can pull, say, JTable values from rdbms', screen-scrapers, rss feeds, even online weather-predicting toasters.

But to simply have a JTable that self-sorts, a real-world issue, well, you're in big trouble. VB.NET, heck even REALbasic (realsoftware.com) come out of the box with grids that do it, but in Java, you're relearning the quick sort -- or, worse, making do stumbling through reteaching yourself how a bubble sort works b/c "that'd be easier and Moore's Law has caught up with the bubble anyhow".

API makers need to get out of the Ivory Tower and hit the streets before they're done. Or, if they're *only* on the street (exhibit A: VB6 & Windows.Forms; ever try databinding in VB6? Great for demos, and demos *only*), they could learn to hit the Tower.

There's no reason for APIs to get in the way of using great objects, and its the job of the API designer to ensure that their objects cater to both the quick hacker and the truely brilliant power user (who's probably helping make the APIs in the first place, at least with Java).

posted by ruffin at 2/17/2004 03:40:00 PM

I'm not sure if this remark about turning HTML display off in an email is good or not. It certainly shows that our reviewer has a horrible Microsoft bias -- you're not (99.44% of the time; there were one or two javascript bugs in NS, I *think*) going to get anything malicious from opening html email in Netscape like you could in Outlook, which embeds IE's engine and its security holes. At the same time, this shows that 1.) Even MS sellouts understand on some level that IE has had (and may still have) serious problems and that 2.) Even techno-junkies are unwittingly arguing for plain text email.

To reduce your chances of getting hit by a virus [while using Netscape's email client], you can opt not to display HTML -- but the setting is global and applies to all messages in your in-box. Other clients let you do this on a per-message basis by clicking on a message body or header, a much better approach.

Of course the winner for irony is the following statement from the same review (reviewing NS 7.1):

... While this [problem with NS's search function] may seem like a minor problem, it's indicative of the program's need for revamping.

Heh. Hey, Netscape, whoever you are now, do you hear that? You need to do what you do best -- Toss it all out and start again!

posted by ruffin at 2/17/2004 12:31:00 PM

For heaven's sake, take some responsibility, people. One thing that bothers me about my desk job is the complete lack of excercise. Heck, retail workers get a five-star workout compared to my typist duties. And no doubt marketing and market power is influencial and so are barriers to entry (witness what an icon for IE on desktops by default does for browser dominance. Heck, Phoenix/Firebird/Firefox has had superior features compared to IE for years other than desktop placement).

That said, I've had enough of the victim mindset and the, "I can't help but sit on my fat arse; the TV tells me to," crap like the below. Why don't people excercise in February? Because it's danged COLD, daggummit. I put off my every-other-day run for a day due to nasty weather. It's just not fun today.

Anyhow, here's the quote:

To Sallis, it's not just lack of will that keeps people from following through on their New Year's resolutions to exercise; it's because the exercise game is fixed.

'From TVs and movies to cars, huge industries don't make money when you exercise, and they push things that make you sedentary,' said Sallis. 'The Super Bowl is a case study in this.'


Yeah, there are no ads nor huge companies that want you buying shoes, shorts, sweats, swimsuits, balls, gloves, pads, or skates. And the car companies, they don't want you travelling much either. Yeah, they want you sitting around typing too. Nor does society put any value whatsoever on looking thin; it wants you to have a fat arse sitting on a phat sofa too (though you might argue they like you yo-yo'ing so that you have to buy two sets of clothes, perhaps). ARGH. Idiots.

And no, other than the fact that most programmers spend entirely too much time on their butt not moving and a few tenuous parallels from the hacker world, I've pretty much broken my rule of confining the topics here to comptuer science with this post. Shaddup and go run.

posted by ruffin at 2/17/2004 10:44:00 AM
Monday, February 16, 2004

Pure Mac: Usenet

posted by ruffin at 2/16/2004 04:01:00 PM

Google Groups: View Thread "How to view .prn files?"

A .prn file may be anything. They are produced when a Windows printer driver is told to print to file, and the content depends on the printer driver which produced it. Unless you know what driver produced the .prn file, you won't be able to do anything.

posted by ruffin at 2/16/2004 12:32:00 PM

Another "good to know". I didn't think I'd done anything other than install a few reputable apps that would have exposed my work machine to a virus. But then, all you need is one open mail relay and you can make an email to anyone from anyone. As I've quoted here before, most SMTP servers are so "helpful" that all you have to do is telnet in and say "HELP" to figure out how they work.

Anyhow, here's the good to know part:

Note: Receiving an email alert stating that the virus came from your email address is not an indication that you are infected as the virus often forges the from address.

Just to be on the safe side, Network Associates even has a free MyDoom scanner you can download from the same page.

posted by ruffin at 2/16/2004 09:03:00 AM
Sunday, February 15, 2004

Who says you can't play mp3s on a Mac old enough to be in a museum? These guys sure don't:

The biggest reason to use MpegDec is that it can play MP3 files in realtime on almost any Mac. Even 'older' Macs with 68K processors are now able to play MP3's.

MpegDec also offers quite a few features at an incredible price - free. And the feature list is growing rapidly. Whether you have a new PowerMac or an old Quadra, you owe it to yourself to try MpegDec on your system.

posted by ruffin at 2/15/2004 11:06:00 PM
Saturday, February 14, 2004



I recently posted on a Slashdot thread about whether a new Powerbook was up to the task of being someone's main Java development box. The short of the long of it is that, sure, Apple's got some great 'books for developers now but that (as any reader of this blog knows, so, um, me and one or two others) there are some drawbacks to having to wait on Apple to create the JVM.

Most uninformed -- or at least underexperienced -- posts said, "Yay! Apple's great for Java! Apple rocks rocks!"

Today I thought of what should really drive your development: Where are you going to deploy? I'm upset I haven't updated The Digest Handler in months. The Mac version is a release behind the Windows version, and that's only because I haven't made time to hack out a few Mac-specific issues. Hooking up all the Mac specific event handlers, etc, is a simple but slightly nontrivial task. I've also done a little work with the way it handles licenses, and haven't finished getting that kosher.

The upshot, however, is that I developed the most recently released version on Windows, and that's where it behaves as expected. My next release will be on the Mac, and there will be a few bits in that app that Windows users would have to wait on. Do GUI tweaks work as expected? Did I take any stupid shortcuts with file paths (likely no, but you get the picture)?

It's kinda like when VB6 idiots leave in hard coded paths to files that exist only on their machine. No amount of testing on that machine is going to discover the bug. Same with Java and testing on different OSes. If you're really targetting the Mac, hack there daily. If you're targetting Windows, hack there. Solaris? Install that on your laptop, if possible (ie, if you're targetting a SPARC, I'm not sure you have a mobile option). And if you're targetting multiple platforms, you're going to need to have one of each at any rate.

But what most people ignore is the fact that most "real" Java hackers are shooting for installation on Windows or some JSP/servlet jive on Solaris. In that case, you probably *shouldn't* be using a Mac and losing all that implicit testing time on your delivery platform.

posted by ruffin at 2/14/2004 09:44:00 AM
Friday, February 13, 2004



Ack. Erased post. Back again. Don't ask how. Magic.

The GridLayout should be an easy thing to whip up in Windows.Forms land. I've seen a couple of attempts to bring Java's concept of Layout Management to .NET, and they are both pretty buggy and fairly complicated to fix.

So what if you only wanted a GridLayout and you didn't mind not having resizable controls and controls that overlap when the form's too small? Sounds simple, eh? It is simple.

Do note that this isn't a GridLayout as in ASP.NET, where GridLayout (in another embrace and CHANGE COMPLETELY) for MS means you can place controls on a grid with explicit x,y coords, even in an html page, just like you can in a Windows.Forms GUI RAD. No, that's not what we're doing at all. We're adding controls to your panel's Controls collection without any regard for spacing, and the GridLayout does the rest. Check the link, above. Instead of dragging to where you want it, we're letting the LayoutManager (look, a manager doing its job! give or take) do the formatting work.

So with that, I introduce the example/sample code "GridLayout made easy in VB.NET" (edited without warning). Smack this code into a form (or another control like a UserControl) and you're ready to go. Extend a form with only this code to have grid layouts all over the place. Turn appropriate vars into properties to feel better about yourself. Enjoy. (again, edited without warning; goofy formatting to fit my blogger template without wrapping)

Imports System.Windows.Forms

Public Class PnlGridLayout
    Inherits Windows.Forms.Panel

    Public intRows As Integer = 0
    ' how many rows there should be; 0 for any number 
    ' (at least one, rows or cols, must be non-zero)

    Public intCols As Integer = 6
    ' how many columns there should be; 0 for any number 
    ' (at least one, rows or cols, must be non-zero)

    Public dblRequiredHeight As Double = 0
    ' allows objects to pull how high this panel needs
    ' to be to display properly

    Public bFillColumn As Boolean = False
    ' make each control fill up all the space available 
    ' in the horizontal

    Public intCellSpacing As Integer = 3
    ' space between cells, hopefully

    Public Sub alignControls()
        Dim ctlTemp As Control
        Dim intCtrlCnt As Integer

        Dim intTempRows As Integer
        Dim intTempCols As Integer

        Dim dblRowHeight As Double
        Dim dblColWidth As Double

        Dim dblDistFromTop As Double = 0
        Dim dblTallestControlHeight As Double = 0

        dblDistFromTop = intCellSpacing

        ' have to have init'd at least one measuring stick for the grid
        ' to work.
        If Not (Me.intRows = 0 And Me.intCols = 0) Then


            '====================================================
            ' figure out how many rows and cols we've got.
            If Me.intRows > 0 Then
                intTempRows = Me.intRows
            Else
                ' note int vs. common division usage; 
                ' might get a few cases a little closer
                intTempRows = Me.Controls.Count / Me.intCols
            End If

            If Me.intCols > 0 Then
                intTempCols = Me.intCols
            Else
                intTempCols = Me.Controls.Count / Me.intRows
            End If
            '====================================================

            dblColWidth = Me.Width / intTempCols
            dblColWidth = dblColWidth - Me.intCellSpacing

            dblRowHeight = Me.Height / intTempRows


            For Each ctlTemp In Me.Controls
                intCtrlCnt = intCtrlCnt + 1
                With ctlTemp

                    ' have it fill the column space entirely if
                    ' preferred.
                    If Me.bFillColumn Then
                        .Width = dblColWidth - Me.intCellSpacing
                    End If

                    .Top = dblDistFromTop
                    .Left = intCellSpacing _
                        + (dblColWidth * ((intCtrlCnt Mod intTempCols) - 1))

                    If ctlTemp.Height > dblTallestControlHeight Then
                        dblTallestControlHeight = ctlTemp.Height
                    End If

                    ' fix last on row
                    If (intCtrlCnt Mod intTempCols) = 0 Then
                        .Left = dblColWidth * (intTempCols - 1)

                        If dblTallestControlHeight < dblRowHeight Then
                            dblDistFromTop = dblDistFromTop _
                                + dblTallestControlHeight + intCellSpacing
                        Else
                            dblDistFromTop = dblDistFromTop _
                                + dblRowHeight + intCellSpacing
                        End If

                        dblTallestControlHeight = 0
                    End If

                    'MsgBox(intCtrlCnt & " :: " & .Top & " :: " & .Left)

                End With
            Next

            If dblTallestControlHeight = 0 Then
                Me.dblRequiredHeight = dblDistFromTop
            ElseIf dblTallestControlHeight < dblRowHeight Then
                Me.dblRequiredHeight = dblDistFromTop _
                    + dblTallestControlHeight + intCellSpacing
            Else
                Me.dblRequiredHeight = dblDistFromTop _
                    + dblRowHeight + intCellSpacing
            End If


        End If
    End Sub


    Private Sub PnlGridLayout_Resize(ByVal sender As Object, _
     ByVal e As System.EventArgs) Handles MyBase.Resize

        Me.alignControls()
    End Sub
End Class

posted by ruffin at 2/13/2004 05:35:00 PM



Consistency is the precursor of good management.

posted by ruffin at 2/13/2004 05:23:00 PM



I actually like a declaration section in my code. Lots of people, especially Java programmers, tend to like inline declarations. I'd rather get a sort of table of contents to the code in a declaration section up top. Even in Java, I'll tend to put a lot of...

Foo foo = null

... with the = null so that I don't get "var wasn't initialized" errors in my garbage collection routine at the end.

So initializing VB.NET vars with values in the declarations section has gotten me a little turned around. Some people try to be all "Java cool" now and you see lots of...

Dim strFoo as String = "I'm putting in a value now, and if you think I'm just declaring you'll miss it!"

... kinda code. At the same time, I like ensuring everything has a default value. So I've finally decided that...

Dim strReturn As String = ""

... is okay; it's what VB6 was doing by default anyhow. But more complicated than essentially a default constructor or a set = Nothing is bad news.

There's some wasted blogspace for you. Sheesh.

posted by ruffin at 2/13/2004 03:53:00 PM

Just to take away this fellow's Googlewhack, let me say that where I work was just hit by the "Deleting orphan file record segment" gremlin today. Fun. A drive stopped responding, the box was bounced, and I noticed that it wasn't back up several minutes later. Checked the screen in the "server room" and "deleting orphan file record segment 12345" was going down the screen, increasing segment number with each line.

After than were a couple of messages about repairing a minor problem in file 5 & 11, then indexes for the files getting blasted. Super. I cut the power and rebooted. Drive gave the same error message that it was giving before the boot and automatic scandisk invocation. Fun fun fun.

Looks like the files are gone. Almost luckly, it was our backup drive, so nothing's down, we didn't lose much of archival importance, and we're ready to grab another drive, slap it in there, and fix it. I guess.

posted by ruffin at 2/13/2004 03:26:00 PM

PageSpinner is a Mac app for writing html with live previews. It's apparently been around quite a while, and I'm somewhat surprised this is the first I've heard of it. Apparently missing robust search & replace functions (like jEdit, BBEdit, or Ultra-Edit have), but might be worth checking out next time I'm near my Mac. Not that I get to do much html any more at work; it's all VB.NET, ADO.NET, Oracle & Windows.Forms right now.

posted by ruffin at 2/13/2004 11:11:00 AM

Right on the heels of my rant on Diebold not writing its own OS, I come to find out parts of the Windows 2000 source have been released. From that same Washingtonpost article, I particularly enjoyed this quote:

Unlike open-source software like the widely used Linux operating system, the code comprising Microsoft's Windows software is not open for public inspection. Linux users are encouraged to participate in an open, continuous cycle of modifications and upgrades that its proponents say results in systems that are more secure and reliable than those powered by proprietary code like Windows.

Stated in such a way to retain fairly unbiased reporting, yet interesting to see how Linux is being portrayed in the mainstream press. If you can't keep your source completely secret (which includes the constant bombarding that allows people to find flaws in Windows), why not just give up? It's a brilliant move that Linux has passively discovered, and it's finally getting the traction in our collective consciousness that it deserves.

posted by ruffin at 2/13/2004 12:14:00 AM
Thursday, February 12, 2004

Finally, Windows directions for allowing iTunes music sharing through XP's firewall:

Savvy Windows XP users will have enabled the built-in firewall for their network ports. This works well to keep out the bad guys, but it also stops incoming traffic you might actually prefer to allow.

In order to allow iTunes sharing with the firewall enabled, you need to 'punch a hole', so to speak. Well, the truth is you actually need to punch two holes. You need to allow the following two ports to get through if you want to access other peoples' iTunes shared files:

Port 3689 TCP
Port 5353 UDP


I still get relatively choppy performance, but at least the firewall's not the issue now.

posted by ruffin at 2/12/2004 03:14:00 PM

This is something I don't quite understand:

The machines were in an advanced line of Diebold ATMs built atop Windows XP Embedded, which, like most versions of Windows, was vulnerable to the RPC DCOM security bug exploited by Nachi, and its more famous forebear, Blaster.

Isn't it easy enough to write an OS that ATMs can go without any specific vendor's offering? I mean, it's not like ATMs are doing anything outrageous -- they have a fairly limited set of functions and, for the most part, that's not going to change. I've gotten somewhat familiar with the insides of an Atari 2600 hacking a demo or two in 6507 assembler, and even it had enough power to interact with me the way I'd hope my ATM would.

So I'd think Diebold could've, should've, and should've wanted to make their own OS from scratch to ensure security. Even if Windows didn't have so many gaping holes (making XP perhaps the *worst* choice Diebold could've made), you'd think something proprietary would be best anyhow.

posted by ruffin at 2/12/2004 03:05:00 PM
Wednesday, February 11, 2004



As a follow-up to yesterday's blog on billing programming time by hours, I believe I've refined where I was coming from a little bit better.

If your business is where it should be, you should be able to fix price your programming. No matter what. That's should be the rule. You might start a new contract once you're done, and you might very well take some time to amend a current contract, both of which likely happen b/c of customer requests/scope creep once you've start showing what it is you can really do. That's just what happens -- you can only create so vivid a picture in your mind before you see operating code.

How can you do this? By creating great scoping docs in the first place, and it's here (and here only) that you've got your wiggle room. You might charge $X,000 for Y hours of system design consultation, but once you've got a good design, your UI sketched, your data fields mapped, and your functionality set, it's time to estimate hours and come up with a good, fair, fixed price. Then build the app as described for that amount.

Again, some people will be tempted to say, "But every project changes so much during design! If I keep everything set in stone, I'll fall behind simply during the time I'm developing!" Well, if you're in a competitive enough niche, perhaps that's not an exaggeration. More likely you don't have good management practices. And in either event, you don't build in wiggle-room when dealing with software development. What you build-in are processes to deal with change, now matter how small, including times during development where change can naturally occur, and you don't move one programmer from what s/he's doing now until your new specs are every bit as solid as today's.

posted by ruffin at 2/11/2004 02:08:00 PM



Seems in VB.NET you can't just not provide a null constructor, you have to explicitly call it private:

Private Sub New()
    ' This disallows the default constuctor and forces users to use
    ' the index constructor.
End Sub

posted by ruffin at 2/11/2004 12:15:00 PM



To view the SQL being executed against your Oracle rdbms, the following statement seems to be useful:

select * from v$sqltext where sql_text like '%some value%'

posted by ruffin at 2/11/2004 10:44:00 AM

Seriously folk, this is a problem:

Newsgroups: microsoft.public.dotnet.framework.adonet
Date: 2003-02-08 15:38:04 PST

I'm working with OleDb. So are you saying that there isn't a way to
capture what is actually being sent to the database? Am I alone or
doesn't that sound like a good feature (especially when dealing with
those obnoxious multiple-step errors that reveal nothing.


As far as I can tell, when you let ADO.NET's DataAdpater clan run SQL to update your rdbms from changes in a DataSet, there's no way to view what's actually being run short of profiling tools from your rdbms. That's crazy. I should be able to see what SQL my code's creating without bothering the specific rdbms involved. Sad design from MS.

posted by ruffin at 2/11/2004 10:14:00 AM
Tuesday, February 10, 2004



Apparently you shouldn't set a VB.NET Windows.Forms control to Nothing, you should call its .Dispose() method instead.

posted by ruffin at 2/10/2004 04:14:00 PM



It's impossible for a person to truly multitask. You might do work that's applicable to more than one project at the same time, but you'd have to be one heck of a worker to hack on two projects concurrently. It's pretty much impossible.

So beware of jobs that state that an applicant needs to be able to juggle multiple tasks simultaneously. That's a sign of bad management. Sure, sure -- reality means you're always got something on more than one burner at a time almost endlessly. But good management has a worker working on one thing -- completing it as closely as possible -- and shielded from the next task until the first one's complete. That's what mangement means, for crimminy sake. Sometimes those two tasks are just small parts of larger projects, and if you've got management that works with you so well that you're able to finish one task on Project 1, then another task on Project 2, then a task back on Project 1 again, bless your luck; you've found management that's doing its job. Switching takes time, and switching daily at times that aren't natural to your project wastes your time. Wasting your time means wasting your company's and your customer's time as well.

Be wary of jobs where tasks are dumped in your lap and you're supposed to truly juggle them. That's not management at all.

posted by ruffin at 2/10/2004 03:21:00 PM

I'm sure nobody reading or writing this blog has ever put themselves into a situation like this:

When something hits me, I'll drop everything I'm behind deadline on and spend 20 hours automating a task that takes five manual minutes; I know I'll eventually recoup the benefits months down the road, after I've long forgotten the automation exists ('you only notice electricity when it's missing').

posted by ruffin at 2/10/2004 11:40:00 AM



Argh. Another post eaten by bad wireless connections (and me not copying to the clipboard before posting). The quick version follows:

* Billing by programmer hours == crazy. Rates should match ability, as programmer ability can vary the time to completion by an order of magnitude or more. A standard rate where team size > 1 is madness.
* If you find yourself stuck in a position where you're billing hours, find out how you bill time given as support to your team/internal support. I had a job where you had 75 hours a quarter (!!) for everything not specifically spent on a certain customer. Whether it was a utility to make faster code next time or internal support, over 75 hours a quarter (less than eight weeks a year!) meant money out of your pocket.

Some jobs expect you to charge this time against your teammate's customer. That makes some sense, but rarely is a customer expecting to contract for, essentially, training time. Some expect you to quietly bill that time against what you were working on in the meantime. That's immoral.

Try to use this to get projects billed in a reasonable way. You can use hours to estimate internally, sure, but let the hours stop there when it comes to billing.

I know, I know, sounds easy enough, but... See, the thing is, managers use overruns on hours so that they can keep soaking the customer when they estimate badly, and that happens awfully frequently. At the same time, if you did get out a good (read: slightly high) estimate, they can always find something to task you with to ensure all those hours get eaten up -- documentation, code review, documentation revision number seventy-two, another code review, etc. That's also immoral, and those together are the problems with hours. Billing by hours doesn't put the customer first, nor adaquately values the hacker doing the work.

posted by ruffin at 2/10/2004 09:38:00 AM
Monday, February 09, 2004

CBS News | Yeltsin: Russian Democracy Firm | May 6, 2003 10:15:23: "'An experienced journalist like yourself,' Yeltsin said, 'should express himself in a more civilized fashion. But this may be the translator's fault, and if so, he is the hippopotamus!'"

posted by ruffin at 2/09/2004 11:31:00 PM

Russia (News & Politics): President Yelstin: " 'An experienced journalist like yourself,' Yeltsin said, 'should express himself in a more civilized fashion. But this may be the translator's fault, and if so, he is the hippopotamus!'"

posted by ruffin at 2/09/2004 11:29:00 PM



Getting a user's interactions with a DataGrid isn't as straightforward as it could be.

    Private Sub grdReview_MouseDown(ByVal sender As Object, _
        ByVal e As System.Windows.Forms.MouseEventArgs) _
        Handles grdReview.MouseDown

        Dim myGrid As DataGrid = CType(sender, DataGrid)
        Dim hti As System.Windows.Forms.DataGrid.HitTestInfo
        hti = myGrid.HitTest(e.X, e.Y)
        Select Case hti.Type
            Case System.Windows.Forms.DataGrid.HitTestType.None
                Console.WriteLine("You clicked the background.")
            Case System.Windows.Forms.DataGrid.HitTestType.Cell
                Console.WriteLine("You clicked cell at row " & _
                    hti.Row & ", col " & hti.Column)
            Case System.Windows.Forms.DataGrid.HitTestType.ColumnHeader
                Console.WriteLine("You clicked the column header for column " & _
                    hti.Column)
            Case System.Windows.Forms.DataGrid.HitTestType.RowHeader
                Console.WriteLine("You clicked the row header for row " & _
                    hti.Row)
            Case System.Windows.Forms.DataGrid.HitTestType.ColumnResize
                Console.WriteLine("You clicked the column resizer for column " & _
                    hti.Column)
            Case System.Windows.Forms.DataGrid.HitTestType.RowResize
                Console.WriteLine("You clicked the row resizer for row " & _
                    hti.Row)
            Case System.Windows.Forms.DataGrid.HitTestType.Caption
                Console.WriteLine("You clicked the caption")
            Case System.Windows.Forms.DataGrid.HitTestType.ParentRows
                Console.WriteLine("You clicked the parent row")
        End Select

    End Sub

posted by ruffin at 2/09/2004 04:32:00 PM

More along the lines of "good to know"

"=?Utf-8?B?TWFuZGFy?= wrote:
> How do i instantiate a class if I get the name of the class at runtime ?
> I am looking for something like class.forname('classABC') in Java .

Well, Type.GetType is roughly the equivalent of Class.forName, but Activator.CreateInstance is roughly the equivalent of Class.newInstance.
Note that in order to get a Type object for a type in an assembly other than either the calling one or mscorlb, you need to either load the assembly yourself and use Assembly.GetType, or include the full name of the type including assembly information in the call to Type.GetType.

posted by ruffin at 2/09/2004 03:31:00 PM



Folks, the subject line of an email is there to allow you to help people differentiate it from other emails. Do not use the same subject for every email dealing with the same superset. "Project X" is not a good email subject. "Developer documentation" is better. "Project X -- Location of developer documentation" is super, and helps you search efficiently, both by eyeballing and through mail client search interfaces, later.

That should be a no-brainer. See, you agree. You wonder why I wrote this. Then you don't use descriptive subjects. SHAME!!!

posted by ruffin at 2/09/2004 10:37:00 AM
Sunday, February 08, 2004



From a recent post on the Apple Java Development mailing list:

Is it just me or did the shortcut key to the preferences menu disapear with Java 1.4.2? Is this an api change, some kind of ui guideline issue, my imagining things, or Apple just randomly deciding to change things?

I'm really, really not impressed with Apple's Java support now. I mean, sure, I'm still impressed and excited to know that Java 2 ships with OS X out of the box, and that any Mac running OS X from 10.0 on up has it. At the same time, the people doing the hacking of things that aren't obvious no-brainers need to stop changing their collective mind about everything else [that's not a no-brainer]. Apple's already changed the way Java apps handle the Apple specific application menu (Preferences, About [this app], Quit [this app], etc on the top left of the menu bar) and how they want you to package apps so that they look like a native, double-clickable executable.

I don't care how bone-headed the implementation is, but they really need to stick to their guns for more than a couple of years at a time. And, as pointed out above, when they break things they 1.) shouldn't do it so that the old way is automatically gone and 2.) should warn their developers.

posted by ruffin at 2/08/2004 09:19:00 PM
Friday, February 06, 2004



There's nothing wrong with making XML with code like:

ts.writeline("<name property=""smack"">smack smack</name>")

Nor is there anything really wrong with well-written text stream parsing code that reads and expects a certain flavor of XML to read in. You can still gain all of the extensibility of XML without making code that's overkill.

A crazied Perl hacker can quickly understand and write a particular type of XML (ie, one DTD's worth) and still not worry about understanding files created by extended versions in the future. As long as the original DTD's conventions are still followed, you've got great code -- and having it all in randmo objects flying all over the place that you're code has a hard time dealing with doesn't help much anyhow.

posted by ruffin at 2/06/2004 03:37:00 PM

Creating and Deleting Folders with VB.NET (VB.NET):

Imports System.IO


Public Function CreateFolder(ByVal strPath As String) As Boolean
        Dim objDir As New DirectoryInfo(strPath)

        Try
            objDir.Create()
            Return True
        Catch
            Return False
        End Try
    End Function

    Public Function DeleteFolder(ByVal strPath As String) As Boolean
        Dim objDir As New DirectoryInfo(strPath)

        Try
            objDir.Delete(True)
            Return True
        Catch
            Return False
        End Try
    End Function


Reading and writing text files in VB.NET:

Public Function GetFileContents(ByVal FullPath As String, _
       Optional ByRef ErrInfo As String = "") As String

        Dim strContents As String
        Dim objReader As StreamReader
        Try

            objReader = New StreamReader(FullPath)
            strContents = objReader.ReadToEnd()
            objReader.Close()
            Return strContents
        Catch Ex As Exception
            ErrInfo = Ex.Message
        End Try
    End Function

    Public Function SaveTextToFile(ByVal strData As String, _
     ByVal FullPath As String, _
       Optional ByVal ErrInfo As String = "") As Boolean

        Dim Contents As String
        Dim bAns As Boolean = False
        Dim objReader As StreamWriter
        Try

       
            objReader = New StreamWriter(FullPath)
            objReader.Write(strData)
            objReader.Close()
            bAns = True
        Catch Ex As Exception
            ErrInfo = Ex.Message

        End Try
        Return bAns
    End Function

posted by ruffin at 2/06/2004 03:32:00 PM

More VB.NET "don't forgets" (which == spam for most blog readers, I'm afraid)!!!

Making custom modal dialog forms in VB.NET:

Select the form itself (click any empty area of the design surface) and set its AcceptButton and CancelButton properties to the saveAddress and cancelAddress buttons.

[Update: No, it takes more than this. You also have to throw in an explcit DialogResult = DialogResult.OK wherever the logic says that what happened worked. DialogResult is a sort of implicit object, apparently belonging to System.Windows.Forms.Form. You can't Me.DialogResult, however, for some reason]

posted by ruffin at 2/06/2004 01:10:00 PM

Microsoft QuickStart Tutorials

posted by ruffin at 2/06/2004 12:49:00 PM

Layout Managers In C#: "Layout Managers In C#"

posted by ruffin at 2/06/2004 12:09:00 PM

Get the Microsoft Internet Control BeforeNavigate2 method working with VB.NET (the way you'd expect it to):

Private WithEvents doc As SHDocVw.DWebBrowserEvents_Event

posted by ruffin at 2/06/2004 10:21:00 AM

App.Path for VB.NET/ASP.NET

Public Function App_Path() As String
     Return System.AppDomain.CurrentDomain.BaseDirectory()
End Function


(update 3/29/2004) Note that the String does end in "\"

posted by ruffin at 2/06/2004 10:02:00 AM
Thursday, February 05, 2004

While reading this comment on the new iChat AV beta that supports video conferencing with AOL's AIM...

I wonder if it tells you now if someone is on a cell phone. I am getting tired of using AIM to find out who is on a phone.

... I started thinking what so many others already are, "When is iChat/AIM going to let us make a phone call?" Heck, everything else is already there. Now, double-click Mom, talk to her through the mic on your Mac/PC/what-have-you. And yes, I know there's software that already does this, but not all cheesily integrated with my AIM client. That'd be great. Not to mention away messages on peoples' phones...

posted by ruffin at 2/05/2004 04:41:00 PM

Can't tell if it's funny or sad, but it's true:

You know who they are. They ramble on and on about the evils of integrated development environments. 'You use an IDE. Then you aren't a real programmer' they exclaim. It is then that they drop the bomb. In their arrogance to assert supreme programming dominance, the words they are about to say begin salivating at the crown of their lips. You feel it coming as your blood pressure begins beating faster and faster. Here it comes... 'I write all my code... in... Notepad!'

posted by ruffin at 2/05/2004 04:19:00 PM
Wednesday, February 04, 2004

Options for accessing VSS via the Net:

VssConnect (http://www.voxcode.com)
SourceOffSite (www.sourcegear.com)
Sekonden SourceWeb (http://sourceweb.sekonden.se/SekondenITAB.htm)
VSS.net (http://www.dmbcllc.com/products.htm)

posted by ruffin at 2/04/2004 01:38:00 PM

Oracle SELECT INTO equivalent:

Oracle:SQL Server
CREATE TABLE
student_backup as
SELECT * FROM
student_admin.student
SELECT * INTO
student_backup
FROM
student_admin.student

posted by ruffin at 2/04/2004 10:26:00 AM



Ah yes, I did want to blog this as well, just for the heck of it. (Becoming right bloggeriffic again lately.)

For all the people whining about how Jaguar (Mac OS X 10.2) won't run the recently released Safari 1.2 or the latest versions of Mail.app and iChat AV (iChatAV without paying $30 for it, at any rate), stop. You sound like babies (and I have as well on this blog once or twice). Look, we (as in I'm running 10.2 and have no plans to upgrade now) did get the security updates, and what else do you really need?

You can run OmniWeb if you need a Mac-only browser, or you might do yourself a favor and check out Mozilla Firebird, which lets you type in the first few letters of a link on a page, hit return, and start browsing without bothering with the mouse (other features that non-programmers might enjoy also included). You might try Adium for instant messaging or Fire, which spellcheck and can run MSN messenger along side your AIM session. You have alternatives to Apple's software, and very very good ones.

No, you don't get Java 1.4.2, and that annoys me a little, but I'd rather Apple release it for those who really need it and are willing to pay to upgrade than not at all.

And heck, you can still run the new iLife '04.

What the heck are you complaining about?

posted by ruffin at 2/04/2004 09:48:00 AM

More from the article on the Mac BU that I started reading yesterday and finished this morning.

When McDonough ["Mac Business Unit's director of marketing and business development"] visits Apple, for example, many of the initial questions about a product are about the user experience -- how it looks and feels, why a certain color was chosen, or how a given button works. At Microsoft, conversations tend to start with the underlying technology, or what kinds of protocols were used.

Thought that was right interesting. Seems like it'd be hard to code that way -- making the GUI first, or at least with it as the first priority -- or, rather, it seems like both companies should have different parts of the team whose job it is to do one or the other, and have all their resepective energies focused on doing their part right. Which I bet is the way the programmers *are* thinking.

Which means is that what we have here is a reflection of the business fellows' priorities -- management's goals. I suppose that shows in the final product, fairly obviously (eg, it's much easier to set up a firewall via the OS in OS X than WinXP). And it helps explain why the coders on the Apple Java dev list, a place where by definition you'd expect the concentration to be on faceless apps, has such a heavy emphasis on user interface guidelines. That's the Apple culture, and for some reason it's trickled down quite a ways.

Interesting that the REALbasic mailing list, in my experience, hasn't been so interface centric, though what REALbasic does best is make GUIs quickly and easily! REALbasic isn't made, ported, or used by Apple, and the culture apparently hasn't had any medium for trickling.

posted by ruffin at 2/04/2004 09:34:00 AM
Tuesday, February 03, 2004

This gets me a wondering...

For that reason, some Mac users worry about Microsoft's long-term commitment to Mac software.

...

'I'm sure it is a profitable part of Microsoft, but in the big picture, at the big board meeting, do they even see on there somewhere, 'We have a Mac business unit?' ' he asked. 'I think that fear runs through every Mac user.'"


Okay, I don't think all that many Mac users are worried about MS leaving the Mac all that much -- Panther's TextEdit edits *.doc files at some level, much as Appleworks has in the past, and Apple's shown with Keynote that they'll fill in the gaps if absolutely necessary.

That said, what gets me most interested is the chance that MS might spin off the MacBU. I wonder if they'd let them spin off if part of the deal was no release on Windows for X years. If the profit isn't enough that MS thinks they'd get more dough by investing elsewhere, there's no reason not to sell off the MacBU assests to someone willing to give it a go.

And, for those of you missing it, the deal here is that if I've got $1000 in a savings account making 2% and have an opportunity to make 5% by buying US Bonds, I'm losing money by having the dough in savings. If the MacBU doesn't pump out enough moolah, MS could start thinking it's more of a savings account than a gold mine.

And for those of you wondering, I finally got DTS to work to export Access files into Oracle 9 (via ODBC). Cheating, I know. But it worked fairly well.

posted by ruffin at 2/03/2004 05:59:00 PM



Fookin Oracle. I hate it already.

Oracle Product Info: Authentication adapter initialization failed:

--------
When scheduling Jobs or Events through the Enterprise Manager 2.x Console, the Oracle Management Server takes the request from the Console and submits it to the Intelligent Agent on the target server. The Intelligent Agent attempts to establish a 'new' Operating System (OS) logon session for each job that itreceives. The OS logon credentials are pulled from the Console's Preferred Credentials settings. In the Preferred Credentials section, each discovered service is listed along with its service type. For OS logons, the ' NODE ' service type must contain a valid OS user that has the correct permissions.


If the logon information provided to the Intelligent Agent is incorrect or missing, the Intelligent Agent will return the error:

VNI-2015: Authentication Error"


From MS help:

To assign user rights for your local computer
Open Local Security Settings.
In the console tree, click User Rights Assignment.
Where?


Security Settings
+-Local Policies
    +-User Rights Assignments


Possible solution:
try this:

please do the first three steps in windows. do step 4 in OEM.

1: create a user login ,such as orajob. This user(orajob) should be created in windows. it's a windows user account.

2: put orajob in ora_dba (not required) group

3: grant orajob the ' log on as a batch job'.
from control panel->administrative tools -> local security policy->local policies-> user right asignment -> select 'log on as a batch', add orajob to it.

4: in your OEM, set database prefered credential, specify orajob as the user to run your jobs for your database.

5: then create your job.

Hope it works.

posted by ruffin at 2/03/2004 03:06:00 PM

Apple - Discussions - IMPORTANT security steps for everyone: "Home > Mac OS X > Mac OS X v10.2 > Information & Resources > User-Contributed Tips & Answers (Mac OS X) > IMPORTANT security steps for everyone"

posted by ruffin at 2/03/2004 10:49:00 AM

Well said, none-too-anonymous-poster:

Most curious to me is that someone who presented themselves fairly competently via the Net also seems to be the candidate with the weakest social skills. And before *I* get flamed, honestly, you've all experienced it. Some people communicate gracefully and intelligently in, say, their usenet posts, but one quick disagreement over minutia later and you're watching a thirty-reply flame war explode in a hail of usenet spam.

Until typing somehow is able to express character as well as actually spending time with a person -- or until people start doing all their interaction through simple ASCII -- expect blogs to remain a tool, not a panacea. And when it comes to the man you'll have sitting across the table from Putin or Chirac or another world leader, political/social skills are always going to remain a top concern.

posted by ruffin at 2/03/2004 10:11:00 AM
Monday, February 02, 2004



Quick intro to .NET validation in VB.NET. Add Textbox1 to your Form. Cut & Paste.

Note that you'll need to add a Button called "cmdCancel". Note that if you even have cmdCancel with *focus* after screwing up entry into TextBox1 (so, for example, you tab off of TextBox1 into Cancel), the validation won't happen. Haven't messed much yet with when events fire (can you get a click from cmdCancel before validation happens, etc).

    Private Sub TextBox1_Validating(ByVal sender As Object, _
        ByVal e As System.ComponentModel.CancelEventArgs) Handles _
        TextBox1.Validating

        Dim strQaMsg As String
        
        strQaMsg = ""

        If Not ActiveControl Is cmdCancel Then

            If TextBox1.Text.Length < 4 Then
                e.Cancel = True
                strQaMsg = "TextBox1's text length " & _
                    "must be at least four characters long"
            End If
        End If

        If e.Cancel Then
            MsgBox(strQaMsg, MsgBoxStyle.Exclamation, _
                "Data entry validation issue")

        End If

    End Sub

posted by ruffin at 2/02/2004 06:45:00 PM



Mo' Oracle fun.

To get the top 10 rows in SQL Server, you'd use:

SELECT TOP 10 * FROM TABLE1

In Oracle, you use...

SELECT * FROM TABLE1 WHERE ROWNUM <= 10

Love me some nonstandard SQL implementations. Working with Oracle & SQL Server is like working with IE & NS again. And when I say NS, I mean Netscape 4.x, where they were just as eager to shove their proprietary layers on us as Microsoft was with IE specific jive. Feeeee-uhn.

posted by ruffin at 2/02/2004 03:05:00 PM



Well, as cliche as it sounds, the dog ate my homework. Yes, that's right, I had a hard drive crash. What fun.

Most aggravating is finding all the "unofficial quick crap" I'd hacked that I hadn't bothered to back up since, "That'd be easy to figure out again." Well, as I jump back into VB.NET, we're no longer taking that tack. I'll be hacking this blog as I relearn a few things, like the VB.NET parallel for using import statements in Java.

Imports Oracle.DataAccess.Client

Public Class SmackDataSet
    Inherits DataSet

    Sub New(ByVal strSmack As String)
        MsgBox("smack")
    End Sub

    Public Sub attemptOracleCxn()
        Dim conStr As String = "User Id=id;Password=pwd;Data Source=server"

        'Create the OracleConnection
        Dim con As OracleConnection
        con = New OracleConnection
        con.Open()
    End Sub


Nice ms-help url showing old VB6 functions and their VB.NET equivalents.

posted by ruffin at 2/02/2004 02:08:00 PM



Strangely, Microsoft has manged to even embrace and extend when it comes to googling their programming languages. Want to find something on Visual Basic.NET? No problem! Google "VB.NET" and/or "Visual Basic.NET" along with your other search words, and you'll get pretty much exactly what you wanted and expected.

But how about Visual Basic 6.0? Forget it. Now you get VB 6 and VB.NET hits for your "Visual Basic" searches. What a pain! MS even has Google pushing you to "upgrade", if only so that your searches are more useful again. Sheesh.

(Obviously what Google needs is regexps, but that's another blog...)

posted by ruffin at 2/02/2004 01:46:00 PM

When reading a few popular chapters out of Mythical Man Month, I did manage to stumble over the now-famous discussion of, "Build one to throw away." But I missed this gem:

Conway's Law

Discussed in The Mythical Man-Month. Layered organizations produce software with layered architectures, etc. Conway's original formulation in 1968 was: If you have four groups working on a compiler, you'll get a four-pass compiler.


Funny and insightful! ;^)

posted by ruffin at 2/02/2004 11:30:00 AM

<< Older | Newer >>


Support freedom
All posts can be accessed here:


Just the last year o' posts:

URLs I want to remember:
* Atari 2600 programming on your Mac
* joel on software (tip pt)
* Professional links: resume, github, paltry StackOverflow * Regular Expression Introduction (copy)
* The hex editor whose name I forget
* JSONLint to pretty-ify JSON
* Using CommonDialog in VB 6 * Free zip utils
* git repo mapped drive setup * Regex Tester
* Read the bits about the zone * Find column in sql server db by name
* Giant ASCII Textifier in Stick Figures (in Ivrit) * Quick intro to Javascript
* Don't [over-]sweat "micro-optimization" * Parsing str's in VB6
* .ToString("yyyy-MM-dd HH:mm:ss.fff", CultureInfo.InvariantCulture); (src) * Break on a Lenovo T430: Fn+Alt+B
email if ya gotta, RSS if ya wanna RSS, (?_?), ยข, & ? if you're keypadless


Powered by Blogger etree.org Curmudgeon Gamer badge
The postings on this site are [usually] my own and do not necessarily reflect the views of any employer, past or present, or other entity.