This Page Updated: 3/17/2004
Personal
Resume
Programming
Hobbies
Weblog (old)
LiveJournal
Email

Personal
Resume
Hobbies
Email

Bookmarks
Pets
Fun!
Internet Security

    This is the page I put any tips about programming that I come across.
If you want to see what languages I program in, check my resume.
The bulk of my current work at my place of business is done in ASP.


Programming Bookmarks on Backflip

(click logo to go there)


Here's a subject you ought to look at: "The Invisible Web"


ColdFusion Tips:

Have you ever had your CF program throw you this error?....

Error Diagnostic Information
Just in time compilation error

Invalid token found on line 497 at position 3.
ColdFusion was looking at the following text:

Dont bother looking at Line 497; ColdFusion is BSing you, and it really doesn't know where the problem is. However WE do...
I've found (by painful experience) that the problem is USUALLY a missing close bracket > on a line JUST previous to that.

Look for an HTML or ColdFusion tag that you forgot to close on the few lines preceding that line.


FoxPro

Resources

On 5/10/99 and 5/11/99 I attended a FoxPro training class presented by APPDEV. On the whole, I felt it was well worth the time. Recommended!

The instructor was John Miller, a very knowledgable programmer-type indeed. He provided lots of little shortcuts and insights into the bowels of the language.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Specific Programming Tips

Here's a sneaky one, if you're doing MS Office automation using Fox, like I am:

How to find out the title bar text of the Active Window:

FUNCTION ActWinText
DECLARE Integer GetForegroundWindow in win32api
DECLARE Integer GetWindowTextLength IN WIN32API Integer nWnd
DECLARE Integer GetWindowText  IN WIN32API Integer nhWnd, String @cString, Integer nMaxCount
hforewnd = GetForegroundWindow()                    && determine the foreground window
slength = GetWindowTextLength(hforewnd) + 1         && length of its title bar text
wintext = REPLICATE( CHR(0), slength )              && make room in the buffer to receive the text
retval = GetWindowText(hforewnd, @wintext, slength) && get title bar text
wintext = Left(wintext, slength - 1)                && remove null character from end of string
RETURN wintext
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

How to insert a combo box into a grid control: Microsoft's Method (lacks details)

My Method - derived from http://www.iinet.net.au/foxpro/_foxy15.html

Q. How do I replace the default textbox in a grid with a different class?

  1. set up the grid the way you want to see it, with textboxes instead of the Combo Boxes. Get everything sized, etc.
  2. Right click on the grid and select "Edit" from the popup menu.
  3. Click on the header (title) of the column into which you want the Combo Box placed. The grid will flash for a moment.
  4. Click on the Combo Box button on the toolbar.
  5. Click on the grid _underneath_ the header, you clicked on before, to insert the Combo Box into the grid. The grid will flash again.
  6. Right click on the grid and select properties from the menu.
  7. Pull down the list box at the top of the properties sheet, and scroll down to the "Column#" entry where you inserted the Combo Box.
  8. Click on the Data tab, then change the CurrentControl from "Text1" to "Combo1".
If you want to know a real sneaky about the tip above...

If you place the combo box on the form first, you can use the builder to set the combo box up. Then you can mark it, do an EDIT / COPY, and paste that already set-up combo box INTO the grid using SHIFT INSERT, in place of step 4 above (it DOES work, trust me...)


Clipper Resources

Last Update: 06/08/99

I've been developing in Clipper since 1990, at Paradyne Corporation. You can look at my resume to see what I've done in the past, but I actually do very little work in Clipper now, since my efforts have been focussed on Visual FoxPro and ColdFusion applications.

Specific Programming Tips

  • none yet, stay tuned!