The Unofficial Newsletter of Delphi Users - Banner

Downloadable UNDU Issues Delphi User Groups

News Page

February 28th, 1998

You will have to forgive me everyone if I am not my usual cheerful self today... I am in mourning. Apple computer today announced the discontinuation of the MessagePad and Emate line of hand-held computers. I have been an avid fan of the MessagePad line since the MP110 came out a number of years ago. I have since had an MP2000 and now have an MP2100. It is a fantastic device and I am greatly disappointed to see it dropped like a hot rock. Maybe it is not too late for some other company to revive it. I suppose I can still hope... Anyway, I still think that porting the Delphi development system to the Newton would have been the thing that would have saved them... <grin>...

Back on the Delphi scene, we have great article for all you digital sound fans out there. Tex Murphy presents Digital Sound and Music in Delphi.

Keep an eye out in the next day or two. I will be posting the prizes awarded for the contributors for the month of February! Also, another reminder to fill out the survey if you haven't already!

February 26th, 1998

Borland has recently announced that for its fiscal year 1998 third quarter and nine months ended December 31, 1997, that the company has delivered a third consecutive quarter of profitability with revenues up 17 percent. If you want to learn more about this, you can check out the Borland press report at http://www.borland.com/about/press/1998/3rdq98.html.

Need to look for files in your Delphi app? Eddie Shipman shows how you can access the Win95 FindFiles dialog from within your application.

I wanted to also say thanks to those of you who have been filling out the survey. It is clear that people still want some form of downloadable information, so maybe the solution is to offer a downloadable "archive" of all articles and tips/tricks each month. If you haven't had a chance to check out the survey, please take a few moments to do it... Thanks!

February 24th, 1998

I have put together a small survey to get some input on the new UNDU site. Please take a few moments to fill it out.

February 23rd, 1998

Do you have a hard time telling which edit field on a form has the focus? Problem solved... check out the tip on Giving Your EditBoxes Some Attention by Herbert J. Beemster. Also, Lance Leonard presents an improved method of cutting, copying, and pasting from the active control.

February 21st, 1998

More changes in the UNDU world... I have thought a great deal about this and have decided for the sake of simplicity to abandon the concept of specific "issues" of UNDU. Because of this decision, Issue #24 will the last real issue of UNDU that you will see. Instead, I will be posting my articles, and those I receive from outside contributors every couple of days and noting them here on the News page and adding them as links in the Tips & Tricks and Articles & Reviews pages.

The advantages are many: It will simplify my work load considerably, because I wouldn't have to dedicate many days of effort to get out a single issue. I will also be able to bring material to readers in a much more timely manner (i.e. every few days instead of every few months). The big disadvantage is of course that I would no longer be putting out the downloadable Windows Help File issues (*.HLP). I know this is going to upset quite a few of you out there who don't like to read things online, but I will keep that in mind when putting articles together. For example, I will try to keep articles all together as one link, so when you visit it, you can print it out, save it to disk, or whatever, without having to hunt your way through multiple links just to read one article.

I am excited about this new format and would welcome readers comments on this decision. I really appreciate everyones support to UNDU... I have a ton of really great articles that are going to start flooding your way. So brace yourself! Note also that I will still be giving out prizes to randomly-selected contributors. I have plenty of great things to give away so at the end of each month, there will be an announcement of who the winner(s) are!

To get things off to a good start, here are some new articles:

Delphi 3's Code Parameters - by Clinton R. Johnson
CD Change Notifications - by Tom Deprez

February 20th, 1998

Matt Price of Multizone International has announced low-cost (under £100) training seminars in the United Kingdom entitled "The Delphi Workout". Sessions will be held in London and Manchester on March 19th and 20th. For more information, you can check here, or go to their web site.

There is also now a non-frames version of the UNDU site.

February 19th, 1998

Many of you have sent me emails about the structure of the site, particularly the way the frames work so I have made some changes in this area. Also, note that for a while many of the links in the issues of UNDU will be wrong, as they are still pointing to the informant.com site. I will be correcting these as time goes on, so please bear with me.

February 17th, 1998

Some updated links in Tips & Tricks and Index of Articles.

February 16th, 1998

Welcome to the new site for The Unofficial Newsletter of Delphi Users! It has taken me a while to get this arranged, and I appreciate everyone's patience. Over the next week or so, I will be getting this site up to speed and also posting issue #25. As you can see, I am arranging things a bit differently here...

The Delphi News link will take you here to this page. This is where I will be reporting on Delphi-related events, product announcements, you name it. If it is happening in the Delphi world, I will try to report it here. I will attempt to report something every day or two, as it becomes available. If you have a new Delphi-related product, why don't you let me know about it?

The Current Issue link will take you to the latest issue of The Unofficial Newsletter of Delphi Users. This site uses Frames to display the issue, so for the time being your browser will need to be frames-capable (IE and Netscape both are). The Past Issue link will show you all the issues of UNDU that have been published. The Downloadable UNDU Issues link will show you all the downloadable issues of UNDU. Here, you can download them as Windows HLP files.

The Tips & Tricks link will show you just the tips and tricks articles from all back issues. This is a work in progress at this point, so it will become more complete as time goes on. The Articles & Reviews link will show you a list of all the other (non tips and tricks) articles from past issues of UNDU. Finally, for a list of Delphi User Groups (at least those who have let me know they exist), check out the Delphi User Groups link.

Make sure you check the UNDU site for all your Delphi-related needs!

Do you have comments? Feel free to email me!


The Unofficial Newsletter of Delphi Users - Tips & Tricks

Articles, Tips & Tricks

Below is a comprehensive list of links to all the Articles, Reviews, and Tips & Tricks published in The Unofficial Newsletter of Delphi Users. Because of the number of articles and tips & tricks in past issues, this will be a work in progress, so please keep checking back for updated links.

02/28/98 - Digital Sound & Music in Delphi
02/26/98 - Accessing the Win95 FindFiles Dialog
02/23/98 - Improving Cut, Copy & Paste
02/23/98 - Giving Your EditBoxes Some Attention
02/21/98 - Delphi 3's Code Parameters
02/21/98 - CD Change Notifications
Issue #24 - Speeding Up Master-Detail Tables
Issue #24 - Beginners Block: An Introduction to Pointers
Issue #24 - NIL Pointers: How Delphi Frees Objects
Issue #24 - RGB & HSL Colour Models
Issue #24 - More on Moving From VB to Delphi
Issue #24 - A Second Look at MicroEdge's Visual SlickEdit
Issue #24 - Delphi and the Year 2000
Issue #23 - Playing and Recording Sounds in Delphi
Issue #23 - An Immediate IF Function
Issue #23 - Two Lines of Text in a String Grid
Issue #23 - A Simple Drawing Program
Issue #23 - Finding the Cursor Coordinates in a Memo Control
Issue #23 - A Browse Directory Component
Issue #23 - Changing Event Handlers at Runtime
Issue #23 - Book Review: Hidden Paths of Delphi 3
Issue #23 - Book Review: Building Delphi 2 Database Applications
Issue #23 - Review: Raize Components
Issue #23 - Making the Move: VB to Delphi
Issue #23 - Add a Web Search Engine to Your Application
Issue #22 - Bitmaps in String Grids
Issue #22 - A Cure for Previous Instance Problems
Issue #22 - A Word Search Tip
Issue #22 - Unbridled Acceleration
Issue #22 - Showing the Caret Position
Issue #22 - Using the Win95 Registry
Issue #22 - Wallpapering MDI Forms
Issue #22 - The InputQueryEx Function
Issue #22 - Exceeding the Data Segment
Issue #22 - Delphi 2.0 and 3.0 on the Same Computer
Issue #22 - Review: Programmers Guild Animated Tray Icon
Issue #22 - Review: MicroEdge's Visual SlickEdit
Issue #22 - Review: IniOut Component
Issue #22 - Review: Addict 2.2 Spell Checker for Delphi
Issue #22 - Getting Control of the Control Panel
Issue #21 - Low-Level Windows Stuff
Issue #21 - Listing Procedures
Issue #21- Hiding Apps from the TaskBar
Issue #21 - Excel OLE Tips
Issue #21 - Playing Sounds Asynchronously
Issue #21 - Bitmaps on StringGrids
Issue #21 - How to Find Up-To-Date Delphi Books
Issue #21 - Using the Margin Marker in Delphi 1 & 2
Issue #21 - Lock Violations Revisited
Issue #21 - Object Creation Tip
Issue #21 - How To Compress a Bitmap
Issue #21 - The TEndSession Component
Issue #21 - Video Capture and Delphi
Issue #21 - Review: Delphi Component Design
Issue #20 - Is Someone Else Running? Revisited!
Issue #20 - InputQueryEx Function
Issue #20 - Multi-Colored Text in a String Grid
Issue #20 - Converting Pascal Source to HTML
Issue #20 - Processing Large Database Tables
Issue #20 - Making Your App Look Normal at Different Resolutions
Issue #20 - How to Make Your EXE's Lighter!
Issue #20 - Win95 Shell Operations - Update
Issue #20 - Form Aspect Ratio
Issue #20 - Previous Instances - Revisited
Issue #20 - Printing Raw Data
Issue #20 - Implementing a "Tip Of The Day" Component
Issue #20 - TFieldPanel
Issue #20 - TPageControl - Update
Issue #20 - Learning How To Drive: Disk Information in Delphi
Issue #20 - Delphi Books and Periodicals
Issue #19 - Using Win95's SHFileOperation to Move/Copy/Delete Files
Issue #19 - How to Create a Polygon Splash Screen
Issue #19 - Is Someone Else Running?
Issue #19 - Lock Violation Errors in Paradox
Issue #19 - Printing Directly to the Printer
Issue #19 - Refreshing MDI Menus
Issue #19 - Extending the Background Bitmap Technique
Issue #19 - Paradox File Size Limits
Issue #19 - Safer Use of Enumerated Types
Issue #19 - Simplifying Code Management with Include
Issue #19 - A Look at the TreeView Component
Issue #19 - Aligning Text in a Grid
Issue #19 - TPageControl
Issue #19 - Big Bitmaps
Issue #19 - Transparency Masks
Issue #19 - Review: SpeedDaemon Code Profiler
Issue #19 - A Look at MagiKit
Issue #19 - Humor: Are you Computer Illiterate?
Issue #18 - Storing Fonts in INI files
Issue #18 - Sorting Columns in a DBGrid
Issue #18 - Adding UNDU to an Edit Menu
Issue #18 - Put Anything in Your Delphi EXE!
Issue #18 - A Simple Clipboard Viewer
Issue #18 - Object Express by OopSoft
Issue #18 - Announcement: IniOut Component
Issue #18 - Book Review: Delphi Component Design by Dany Thorpe

More links to come! To see the material in Issues 1 through 17, click here.


CD Change Noficiations

Notification of CD-ROM insertion and removal

by Tom Deprez - Tom.Deprez@uz.kuleuven.ac.be

I’m not a real programmer. I mean, everything I know of programming is from experimenting and reading books. But I think this can be interesting for everybody.

I often visit the Delphi site of experts exchange, there I can ask or answer a lot of Delphi questions. One day somebody asked if it was possible to get notified when a user pushed the insert/eject button on a CD-ROM drive. I found this a really interesting question and started to look for a solution. I searched a lot on the net, but nothing could still my hunger. All the detection’s were based on polling for media changes, i.e. looking for every e.g. millisecond if the media changed. Luckily I found some interesting information on the Microsoft Technical Support pages (article ID: Q163503).

Here is my solution based on the information I found in this article :

The notification message

When a compact disc is removed or inserted, then Windows 95 and Windows NT send a WM_DEVICECHANGE message to all top-level windows. This message contains an event (wParam) which describes the change and a structure (lParam) that provides detailed information about the change.

Here is the definition of WM_DEVICECHANGE: (from Win32 programmers reference)

    [New - Windows 95]

    Event = (UINT) wParam;
    dwData = (DWORD) lParam;

    The WM_DEVICECHANGE device message notifies an application or device driver of a change to the hardware configuration of a device or the computer.

    Parameters

    Event

    Event type. Can be one of these values:

    Value Meaning
    DBT_DEVICEARRIVAL A device has been inserted and is now available.
    DBT_DEVICEQUERYREMOVE Permission to remove a device is requested.
    Any application can deny this request and cancel the removal.
    DBT_DEVICEQUERYREMOVEFAILED Request to remove a device has been cancelled.
    DBT_DEVICEREMOVEPENDING Device is about to be removed. Can not be denied.
    DBT_DEVICEREMOVECOMPLETE Device has been removed.
    DBT_DEVICETYPESPECIFIC Device-specific event.
    DBT_CONFIGCHANGED Current configuration has changed.

    dwData

    Address of a structure that contains event-specific data. Its meaning depends on the given event.

    Return Value

    Returns TRUE to complete a requested action, FALSE otherwise.

    Remarks

    For devices that offer software-controllable features, such as ejection and locking, the operating system typically sends a DBT_DEVICEREMOVEPENDING message to let applications and device drivers end their use of the device gracefully.
    If the operating system forcefully removes of a device, it may not send a DBT_DEVICEQUERYREMOVE message before doing so.

As you can see in the definition, this message isn’t only send when a CD is inserted or removed. This message will be send whenever new devices or media are added and when existing devices or media are removed. But the purpose of this text is only to explain how to get notified when a compact disc is removed or inserted in the CD-ROM player.

Processing the wm_devicechange message (in case of a compact disc)

Now, when a new compact disc is inserted into a drive, a WM_DEVICECHANGE message is broadcasted. This message contains a DBT_DEVICEARRIVAL event.
When a compact disc is removed, the WM_DEVICECHANGE message contains the DBT_DEVICEREMOVECOMPLETE event. In this case (inserting and removing compact discs), we know that the device is of type volume (DBT_DEVTYP_VOLUME) and the event’s media flag is set (DBTF_MEDIA).

Getting to work

Great, intercepting WM_DEVICECHANGE and we’re done! Pity that all the needed constants and structures for interpreting this message aren’t declared in Delphi. So that’s the first thing we’ve got to do. Making some declarations which makes life easier. For that you can look at some libraries (in which these declarations are made) or have a look at the SDK kit of Microsoft. If you found them the only thing you still have to do is to translate them into something that Delphi understands. When you do this, always try to use the naming conventions. This makes live easier and less confusing for everybody.

Partial Translate of DBT.H

The first thing we make is a message-specific record for this windows message. We could use TMessage, but then we have to work with the ‘meaningless’ words like wParam and lParam.

TWMDeviceChange = record
   Msg : Cardinal;
   Event : UINT;
   dwData : Pointer;
   Result : LongInt;
  end;

When we got a DBT_DEVICECHANGE or DBT_DEVICEREMOVECOMPLETE event, dwData contains an address of a DEV_BROADCAST_HDR structure identifying the device inserted. We also need a pointer so we can point to this structure.

PDEV_BROADCAST_HDR = ^TDEV_BROADCAST_HDR;
 TDEV_BROADCAST_HDR = packed record
   dbch_size : DWORD;
   dbch_devicetype : DWORD;
   dbch_reserved : DWORD;
  end;

When the device is of type volume, then we can get some device specific information, namely specific information about a logical volume.

PDEV_BROADCAST_VOLUME = ^TDEV_BROADCAST_VOLUME;
  TDEV_BROADCAST_VOLUME = packed record
   dbcv_size : DWORD;
   dbcv_devicetype : DWORD;
   dbcv_reserved : DWORD;
   dbcv_unitmask : DWORD;
   dbcv_flags : WORD;
  end;

Next to this structures, necessary constants have to be declared :

(* Events of WM_DEVICECHANGE (wParam) *)

  DBT_DEVICEARRIVAL = $8000;            (* system detected a new device *)
  DBT_DEVICEQUERYREMOVE = $8001;        (* wants to remove, may fail *)
  DBT_DEVICEQUERYREMOVEFAILED = $8002;  (* removal aborted *)
  DBT_DEVICEREMOVEPENDING = $8003;      (* about to remove, still avail *)
  DBT_DEVICEREMOVECOMPLETE = $8004;     (* device is gone *)
  DBT_DEVICETYPESPECIFIC = $8005;       (* type specific event *)
  DBT_CONFIGCHANGED = $0018;

 (* type of device in DEV_BROADCAST_HDR *)
  DBT_DEVTYP_OEM = $00000000;           (* OEM- or IHV-defined *)
  DBT_DEVTYP_DEVNODE = $00000001;       (* Devnode number *)
  DBT_DEVTYP_VOLUME = $00000002;        (* Logical volume *)
  DBT_DEVTYP_PORT = $00000003;          (* Port (serial or parallel *)
  DBT_DEVTYP_NET = $00000004;           (* Network resource *)

  (* media types in DBT_DEVTYP_VOLUME *)
  DBTF_MEDIA = $0001;                (* change affects media in drive *)
  DBTF_NET = $0002;                     (* logical volume is network volume *)

Making the component

Our component needs to intercept messages. For that we’ve to create an invisible window, which is able to intercept these messages. This is done with the AllocateHWnd function. With it we’ve to send the window-procedure and in return we get the handle to this invisible window. We may not forget to free this window when we don’t need it anymore! This can be done with the DeAllocateHWnd procedure. The correct place for creating and destroying this invisible window would be in the respective Create and Destroy procedures of our component. For this we’ve to override these methods in the public declarations sector :

constructor TCDEvents.Create(AOwner: TComponent);
begin
  inherited Create(AOwner);
  FWindowHandle := AllocateHWnd(WndProc);
end;

destructor TCDEvents.Destroy;
begin
  DeallocateHWnd(FWindowHandle);
  inherited Destroy;
end;

Offcourse we must also declare a variable for storing the handle of the invisible window and our window-procedure in the private sector. This procedure will intercept all the messages, so here we can check if the message is of WM_DEVICECHANGE. To be sure that any other will be processed, we call the DefWindowProc function if our message is different from WM_DEVICECHANGE.

procedure TCDEvents.WndProc(var Msg: TMessage);
begin
     if (Msg.Msg = WM_DEVICECHANGE) then
      try
        WMDeviceChange(TWMDeviceChange(Msg));
      except
        Application.HandleException(Self);
      end
    else
      Msg.Result := DefWindowProc(FWindowHandle, Msg.Msg, Msg.wParam, Msg.lParam);
end;

As you can see, we check if we received a WM_DEVICECHANGE message. If not, the procedure send the message to the default window procedure. Otherwise we call another procedure (WMDeviceChange) for further processing of the message. While sending to WMDeviceChange the Msg of type TMessage will be transformed to our self defined tWMDeviceChange type.

procedure TCDEvents.WMDeviceChange(var Msg : TWMDeviceChange);
var lpdb : PDEV_BROADCAST_HDR;
       lpdbv : PDEV_BROADCAST_VOLUME;
begin
 (* received a wm_devicechange message *)
  lpdb := PDEV_BROADCAST_HDR(Msg.dwData);
  (* look at the event send together with the wm_devicechange message *)
   case Msg.Event of
    DBT_DEVICEARRIVAL : begin
      if lpdb^.dbch_devicetype = DBT_DEVTYP_VOLUME then begin
       lpdbv := PDEV_BROADCAST_VOLUME(Msg.dwData);
       if (lpdbv^.dbcv_flags and DBTF_MEDIA) = 1 then
        if Assigned(fAfterArrival) then
         fAfterArrival(Self, GetFirstDriveLetter(lpdbv^.dbcv_unitmask));
      end;
     end;
    DBT_DEVICEREMOVECOMPLETE : begin
      if lpdb^.dbch_devicetype = DBT_DEVTYP_VOLUME then begin
       lpdbv := PDEV_BROADCAST_VOLUME(Msg.dwData);
       if (lpdbv^.dbcv_flags and DBTF_MEDIA) = 1 then
        if Assigned(fAfterArrival) then
         fAfterRemove(Self, GetFirstDriveLetter(lpdbv^.dbcv_unitmask));
      end;
     end;
   end;
 end;

In this procedure we check the message thoroughly. We first look at the event send with the WM_DEVICECHANGE message. Next, we must check if the message is send by a CD-ROM drive. For this we check if the sending device is of type volume (DBT_DEVTYP_VOLUME). This specific information we can find in the record to which the address (dwData) points stored in the message record (TWMDeviceChange).

Then we’ve to look from which device the message is send, this we do by looking at the record through the ‘eyes’ of the TDEV_BROADCAST_HDR type. The dbch_devicetype field defines the type. In our case, we only want to be notified when a CD is removed or ejected from the CD-ROM player. So the device has to be a logical volume (DBT_DEVTYP_VOLUME).

Now, we know from which device the message comes and we can look at the record with the correct ‘glasses’, namely TDEV_BROADCAST_VOLUME. This record especially defined for logical volumes, gives us extra information about this sort of device.
If the device change message comes from a logical volume, we still have to check if the change was owing to the CD inside the CD-ROM drive or the CD-ROM drive itself. For knowing this, we’ve to check if the media flag is set in the dbcv_flags field. If so, the message is owed by a change in CD.

With the dbcv_unitmask field we can find the valid drive letters, from which the message comes. The function below, returns the first valid drive letter. A valid drive letter is defined when the corresponding bit is set to 1 in the mask of drive letters, namely dbcv_unitmask field.

function TCDEvents.GetFirstDriveLetter(unitmask : longint):char;
var DriveLetter : shortint;
begin
 DriveLetter := Ord('A');
 while (unitmask and 1)=0  do begin
  unitmask := unitmask shr 1;
  inc(DriveLetter);
 end;
 Result := Char(DriveLetter);
end;

Well, if the message cames from a CD, we can send the events. And that’s it, not much as you can see and it isn’t really that hard to accomplish.
I hope that you liked this article and also I hope you give me some comments about it. Just send it to my e-mail address. You can also look at the source code, included with this article. Please, read the header in the .pas file. That’s all that I ask from you, I don’t think this is much asked.

If you are interested in the source code for this project, you can download it by clicking here.


Delphi 3's Code Parameters

by Clinton R. Johnson - xepol@poboxes.com

One of the best new features of Delphi 3 is the CODE PARAMETERS code insight feature (the hint that shows the parameters to the call you are typing in). The thing that I really hate, is that it appears to come at will, and go at will - not my will either. I looked high and low, and couldn't find any documentation on how to pop up this handy little hint window at will.

One day, I got annoyed, and went hunting on my keyboard - lo and behold! SHIFT-CTRL-SPACE does the trick! In any editor configuration no less!

Hidden in the editor are a whole slew of new features which just are not getting the attention they deserve.

I've found that unless you are using epsilon keys, you can now mark blocks in entirely new ways - even a rectangular region on the screen that never starts at the start of the line! (much like QEdit's anchor feature).

Straight from the help file:

CLASSIC/DEFAULT
Ctrl+O+C Marks a column block
Ctrl+O+I Marks an inclusive block
Ctrl+O+K Marks a non-inclusive block (default when the editor starts)
Ctrl+O+L Marks a line as a block

BRIEF
Alt+A Marks a non-inclusive block
Alt+C Marks a column as a block
Alt+L Marks a line as a block
Alt+M Marks an inclusive block

Aside from the other many useful editor keys, it seems that every time they release Delphi, you need to go and hunt down wonderful new features Borland decided to hide on us.


Give Your EditBox Some Attention!

The Unofficial Newsletter of Delphi Users - by Robert Vivrette

Give Your Editbox Some Attention!

by Herbert J. Beemster - HerbertJB@compuserve.com

Did you ever see an application with many editboxes on the screen, and was it easy to detect where the caret was? Which editbox had the focus? Ofcourse, when you move around with the tab-key you'll see the selected text in the editbox, that is: if there is text! When you click on an editbox, you only see the caret blinking.

I figured that there must be a beter way to show where you are! As you'll probably know a TEdit component has a property called BorderStyle with two values: bsSingle and bsNone. If you toggle between these values in the Object Inspector, you'll notice that there is a rectangle at the border of the editbox. In the descendant of TEdit I added two extra properties: BorderColor and BorderFocusColor. With BorderColor you can change the default clWindowFrame to any fancy color you like and with BorderFocusColor you'll be able to set the color of the border when the editbox has the focus.

In the Test project you can check it out. You don't have to install THJBEdit first because the program creates instances on the fly.

It's all freeware, enjoy! Click here for the source code.


Cut, Copy & Paste Improved

The Unofficial Newsletter of Delphi Users - by Robert Vivrette

Cut, Copy, & Paste... Improved!

by Lance Leonard, lleonard@alldev.com

In Issue #17 of UNDU, Brad Evans suggested the following for Cut, Copy, and Paste:

    SendMessage(ActiveControl.Handle, WM_CUT, 0, 0);

He also noted that you need to change this slightly for MDI Applications. Actually, there is a simpler way that you don't have to worry about at all:

    PostMessage(getFocus(), WM_COPY, 0, 0 );

This approach offers two advantages:

1. It doesn't matter what kind of form (or window, for that matter) is active. GetFocus is an API call that returns the handle of the active child control. So, it will work even if you have an OLE/ActiveX child control embedded on your form.

2. Since we're not concerned with the return value, PostMessage is a somewhat better solution because it places the Clipboard request at the bottom of the controls current event queue. If the control just happened to be in the middle of something when your user triggered the Clipboard command, PostMessage makes sure that task is complete.

SendMessage does have an advantage over PostMessage. Its result indicates whether or not the control accepted the message. Thus, you could extend the code to provide the user with feedback if the message wasn't accepted by the control.

There is an additional reason I'd like to add to Brad's thoughts about the advantages of such an approach. If the control supports selection, such as a TEdit or TMemo, you don't need to change the code in order to affect just the selected text.

Hope this helps...


Opening the Find Files Dialog Using Delphi

 The Unofficial Newsletter of Delphi Users - by Robert Vivrette

Opening the "Find Files..." Dialog Using Delphi.

by Eddie Shipman - eshipman@inetport.com

I received an e-mail asking how to programatically open the "Find Files..." dialog. I scratched my head and wondered how it was done. So, the trek began to find out how to accomplish this using Delphi.

To begin you need to know how Windows actually does it. Windows uses the lpVerb parameter of the SHELLEXECUTEINFO structure in a ShellExecuteEx call to accomplish this. In Delphi, the structure is called TShellExecuteInfo and it is defined in ShellAPI.PAS like this:

    TShellExecuteInfoA = record
        cbSize: DWORD;
        fMask: ULONG;
        Wnd: HWND;
        lpVerb: PAnsiChar;
        lpFile: PAnsiChar;
        lpParameters: PAnsiChar;
        lpDirectory: PAnsiChar;
        nShow: Integer;
        hInstApp: HINST;
        { Optional fields }
        lpIDList: Pointer;
        lpClass: PAnsiChar;
        hkeyClass: HKEY;
        dwHotKey: DWORD;
        hIcon: THandle;
        hProcess: THandle;
      end;
     TShellExecuteInfo = TShellExecuteInfoA;
These units are required in your uses clause: ShlObj, ShellAPI, ActiveX.

In our case we only need a few of the parameters. To open the "Find Files..." dialog on a specific Drive, you must pass the path to the drive via the lpFile parameter. The record will be defined like this to open the dialog on drive C:

      with sei do
      begin
        cbSize := SizeOf(sei);
        nShow := SW_SHOWNORMAL;
        lpFile := PChar('C:\'); // This parameter can also be suffixed with
                                // another '\' so you would have PChar('C:\\')
        lpVerb := 'find';
      end;
The lpVerb parameter set to 'find' instructs the call to ShellExecuteEX to open the "Find Files..." dialog. The nShow parameter defaults to SW_SHOWNORMAL so it is not really needed.

This is the entire call to open with a Drive selected from a DriveComboBox:

    procedure TForm1.Button1Click(Sender: TObject);
    var
      PMalloc: IMalloc;  // IMalloc is defined in ActiveX.PAS
      sei :  TShellExecuteInfo;
    begin
      try
        SHGetMalloc(PMalloc);
        ZeroMemory(@sei, sizeof(sei));
        with sei do
        begin
          cbSize := SizeOf(sei);
          lpFile := PChar(String(DriveComboBox1.Drive) + ':\');
          lpVerb := 'find';
        end;
        ShellExecuteEx(@sei);
      finally
        pMalloc._Release;
        pMalloc := nil;
      end;
    end;
Now, suppose you wanted to open with "My Computer" as the stating place? You will have to do things a little different. Here's how:
    procedure TForm1.Button1Click(Sender: TObject);
    var
      pidl: PITEMIDLIST;
      PMalloc: IMalloc;
      sei :  TShellExecuteInfo;
    begin
      try
        SHGetMalloc(PMalloc);
        ZeroMemory(@sei, sizeof(sei));
        SHGetSpecialFolderLocation(0,CSIDL_DRIVES,pidl);
        with sei do
        begin
          cbSize := SizeOf(sei);
          fMask := SEE_MASK_INVOKEIDLIST;
          lpVerb := 'find';
          lpIDList := pidl;
        end;
        ShellExecuteEx(@sei);
      finally
        pMalloc._Release;
        pMalloc := nil;
      end;
    end;
As you can see, we are using two new parameters for the SHELLEXECUTEINFO record. The first thing the needs to be done is to fill the pidl ItemIdList with a call to SHGetSpecialFolderLocation. The parameter CSIDL_DRIVES tells the function to return the info for "My Computer", which is actually just a list of drives accessable to your computer. The parameter fMask set to SEE_MASK_INVOKEIDLIST instructs ShellExecuteEX to use the lpIDList parameter. This must be set correctly for the dialog to open.

So, now you can give your users access to the "Find Files..." dialog without them having to open Explorer or moving to the Start Menu.

Here is the complete code to the project:

    unit uFileOpen;

    interface

    uses
      Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
      StdCtrls, ShlObj, ShellAPI, FileCtrl, ActiveX;

    type
      TForm1 = class(TForm)
        Button1: TButton;
        DriveComboBox1: TDriveComboBox;
        CheckBox1: TCheckBox;
        procedure Button1Click(Sender: TObject);
        procedure DriveComboBox1Change(Sender: TObject);
      private
        { Private declarations }
      public
        { Public declarations }
      end;

    var
      Form1: TForm1;

    implementation

    {$R *.DFM}

    procedure TForm1.Button1Click(Sender: TObject);
var
pidl: PITEMIDLIST;
PMalloc: IMalloc;
sei :  TShellExecuteInfo;
begin
try
SHGetMalloc(PMalloc);
ZeroMemory(@sei, sizeof(sei));
if CheckBox1.Checked then
begin
SHGetSpecialFolderLocation(0,CSIDL_DRIVES,pidl);
with sei do
begin
cbSize := SizeOf(sei);
fMask := SEE_MASK_INVOKEIDLIST;
lpVerb := 'find';
lpIDList := pidl;
end;
end
else
begin
with sei do
begin
cbSize := SizeOf(sei);
lpFile := PChar(String(DriveComboBox1.Drive)
+ ':\');
lpVerb := 'find';
end;
end;
ShellExecuteEx(@sei);
finally
pMalloc._Release;
pMalloc := nil;
end;
end;

    procedure TForm1.DriveComboBox1Change(Sender: TObject);
    begin
      if CheckBox1.Checked then CheckBox1.Checked := False;
    end;

    end.

Here is the DFM:
    object Form1: TForm1
      Left = 200
      Top = 112
      Width = 258
      Height = 142
      Caption = 'Open Find Files... Dialog'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'MS Sans Serif'
      Font.Style = []
      PixelsPerInch = 96
      TextHeight = 13
      object Button1: TButton
        Left = 58
        Top = 63
        Width = 133
        Height = 38
        Caption = 'Open Find Files...'
        TabOrder = 0
        OnClick = Button1Click
      end
      object DriveComboBox1: TDriveComboBox
        Left = 52
        Top = 14
        Width = 145
        Height = 19
        TabOrder = 1
        OnChange = DriveComboBox1Change
      end
      object CheckBox1: TCheckBox
        Left = 76
        Top = 40
        Width = 97
        Height = 17
        Caption = 'My Computer'
        TabOrder = 2
      end
    end


Digital Sound and Music in Delphi

The Unofficial Newsletter of Delphi Users - by Robert Vivrette

Digital Sound and Music in Delphi

by Stanislav Holenda - texmurphy@email.cz

Introduction

Digital sound on the PC has been a very tricky business in past years. There were no sound cards with a DAC (digital to analogue converter) and the PC speaker was capable of playing only 4-bits audio (compared to modern 16-bit cards), thus there were only a few programs capable of playing digital audio like MODPLAY (written in assembler). These however took a lot of processor time, because they had to do all the stuff.

Then the SoundBlaster was introduced. This card allowed you to play sound using DMA transfer. This means that the only thing the playing program has to do is prepare data - the playing of the sound itself is done by the hardware of the sound card.

This sound card allowed programs to play music in the background and do some other stuff. This brought a few sound-systems written in assembler, which might be used in Turbo Pascal as linked objects (e.g. GOLDPLAY). These programs were able to play usually 4 channel Amiga music modules. Some of these systems were good but they all had one common problem - they were design to work in real mode. In protected mode (BP7.0 or BPW and any Windows compiler) they crashed the application or even caused a system crash.

So disappointed I was with this fact, I started searching for a protected mode compatible player. Finally I’ve found it! - MIDAS.

MIDAS Digital Audio System 1.1.1

So let me tell you what MIDAS is and why it is so good:

In brief, MIDAS is a multichannel digital sound and music system, capable of playing an unlimited number of channels of digital sound on all supported platforms. It can play music modules, individual samples, and digital audio streams, in any combination.

MIDAS supports the following module formats:

  • 4-channel Protracker modules plus 1-32-channel variants (.MOD)
  • 1-32 -channel Scream Tracker 3 modules (.S3M)
  • 2-32 -channel FastTracker 2 modules (.XM)
  • 1-64 -channel Impulse Tracker modules (.IT)

In the Win32 and Linux platforms, MIDAS accesses the sound hardware through the system sound drivers, and thus works with any sound card that has proper drivers available. In Win95/NT, both the standard multimedia API's and DirectSound are supported. Under MS-DOS, MIDAS supports the following sound cards:

  • Creative Labs Sound Blaster series (1.0 through SB 16 and AWE32)
  • Gravis UltraSound (regular, MAX, and Plug and Play, with native Interwave support)
  • Media Vision Pro Audio Spectrum series (PAS, PAS+ and PAS16)
  • Microsoft Windows Sound System and compatible cards using the
  • Crystal/Analog CODEC. Most inexpensive 16-bit sound cards sold nowadays are WSS compatible.

This release of MIDAS can be used for free for free programs, but commercial usage requires a separate license. Contact midas@housemarque.fi for details.

The Complete MIDAS package can be downloaded from http://www.s2.org/midas or http://kalahari.ton.tut.fi/s2/midas (about 1.5 megs), but all you need is MIDAS.DLL and MIDASDLL.PAS units plus licence and manuals and such stuff. See the link below for the Delphi source code that interfaces with this DLL.

MIDAS in Delphi

Usage of MIDAS in Delphi is quite easy - users call all the functions from the MIDAS.DLL using a supplied unit called MIDASDLL.PAS. The basic functions are documented in example application MINIPLAY.

First of all you need to initialize MIDAS (best in the form.create method or in application startup):

    module := NIL;
    playHandle := 0;
    playing := false;
    MIDASstartup;
    if not MIDASinit then
      MIDASerror;
    if not MIDASstartBackgroundPlay(0) then
      MIDASerror;

Second open one or more modules:

    var
      cfilename : array[0..256] of char;
      info : MIDASmoduleInfo;
      captxt : string[64];
      playHandle : MIDASmodulePlayHandle;
      playing : boolean;

    begin
      if playHandle <> 0 then begin
          if not MIDASstopModule(playHandle) then
            midasError;
          playHandle := 0;
        end;
        if module <> NIL then begin
          if not MIDASfreeModule(module) then
            midasError;
          module := NIL;
        end;

        module := MIDASloadModule(cfilename);
if module = NIL then begin
Application.MessageBox(MIDASgetErrorMessage(MIDASgetLastError),
'Module loading error', MB_OK or
  MB_ICONSTOP);
exit;
end;

        playHandle := MIDASplayModule(module, true);
        if playHandle = 0 then
          MIDASerror;
        playing := true;

        if not MIDASgetModuleInfo(module, @info) then
          MIDASerror;
    end;

Third play the module you want:

    if (not playing) and (module <> NIL) then
      begin
        playHandle := MIDASplayModule(module, true);
        if playHandle = 0 then
          MIDASerror;
        playing := true;
      end;

Fourth stop the module:

    if (playing) and (playHandle <> 0) then
    begin
    if not MIDASstopModule(playHandle) then
    MIDASerror;
    playHandle := 0;
    playing := false;
    end;

Fifth close and uninstall MIDAS on application exit:

    procedure TForm1.FormClose(Sender: TObject; var Action: TCloseAction);
    begin
      if playing then BitBtn2Click(sender); {call the stop routine attached to BitBtn2}

      if not MIDASstopBackgroundPlay then
         MIDASerror;
      if not MIDASclose then
         MIDASerror;
    end;

Auxiliary routine(s) like MIDASError and routines for detection of song name, setting volume, echoes, etc. are in source code of my simple test player, MIDASDLL.PAS and MINIPLAY. I think they are fairly self-explanatory (if they don’t just e-mail me and we could discuss the problems). Next time we might take a look on the sound FX if someone is interested.

MIDAS was written by Petteri Kangaslampi (pekangas@sci.fi)and Jarno Paananen (jpaana@iki.fi)

Click here for the Source code and support files for this project.


Delphi Users Groups

If you run a Delphi Users Group that is not on this list, please feel free to send me an email with the essentials. Please include basic information about where and when the group meets, and particularly any web links you may have to support the group. I am going to keep the info to a minimum so I can include in each issue (or maybe every other issue). I have provided a sample form to help you provide the right information.

Arizona

    Tucson Delphi Users Group - TDug
California
    Orange County Delphi Users Group
    North Bay Delphi SIG
    Delphi SIG of the Sacramento PC User Group
Canada
    Metro Halifax Delphi Developers Group
    The Toronto Area Delphi Developers Association
    Vancouver Delphi Developers Association
Colorado
    Western Slope Visual Developers Group
    Denver Borland Users Group
Iowa
    Central Iowa Delphi Users Group
Kansas
    Kansas City Delphi Users Group
Massachusetts
    The Delphi Developers Group of Greater Boston
Minnesota
    TCPC Delphi SIG
Michigan
    Royal Oak Delphi Users Group
North Carolina
    Research Triangle Park Delphi Users Group
Ohio
    Delphi SIG of the Greater Cleveland PC Users Group
    Columbus Delphi SIG
    Greater Dayton Delphi Group
Oregon
    Oregon Delphi Users Group
Pennsylvania
    Pittsburgh Area Delphi Users Group
    Borland Technologies User Group
Utah
    Salt Lake City Delphi Users Group


Tucson Delphi Users Group

Group Name: | Tucson Delphi Users Group - TDug
Person(s) in Charge: | Matthew J. Brock, Oscar Speed
Meeting Date/Time: | Third Saturday of each month, 9:00am-10:00am
Meeting Location: | DRA Software Training Center, 3434 E. 22nd St. Suite 100, Tucson, AZ
Dues: | Free
Email Address: | mjb@azstarnet.com
Phone Number: | 520-571-7203
Internet URL: |
Description: | One or more presentations, Q&A, Product Reviews


Orange County Delphi Users Group

Group Name: | Orange County Delphi Users Group
Person(s) in Charge: | Greg Stevenson
Meeting Date/Time: | Fourth Tuesday of each month at 7:00 pm
Meeting Location: | See Web Site
Dues: | See Web Site
Email Address: | See Web Site
Phone Number: | See Web Site
Internet URL: | http://www.ocdelphi.org
Description: |


North Bay Delphi Special Interest Group

Group Name: | North Bay Delphi Special Interest Group
Person(s) in Charge: | Bjarne Winkler
Meeting Date/Time: | Second and Fourth Wednesday of each month from 7:00 pm to 9:00 pm
Meeting Location: |
Dues: |
Email Address: | nts4618086@aol.com
Phone Number: |
Internet URL: |
Description: | Announcements, Q&A, Special topics each meeting.


Delphi SIG of the Sacramento PC User Group

Group Name: | Delphi SIG of the Sacramento PC User Group
Person(s) in Charge: | Robert Muir, Mike Prestwood
Meeting Date/Time: | 2nd Monday of the Month - 6:30pm
Meeting Location: | New Horizons Building, 1215 Howe Avenue, Sacramento, CA
Dues: | None
Email Address: | robertmuir@worldnet.att.net or mike@prestwood.com
Phone Number: |
Internet URL: | www.prestwood.com/forums/delphi/sdug
Description: | Announcements, Q&A, Special Topics each meeting


Metro Halifax Delphi Developers Group

Group Name: | Metro Halifax Delphi Developers Group
Person(s) in Charge: | Dave Hackett
Meeting Date/Time: | First Tuesday of each month from 7:00 pm to 9:00 pm
Meeting Location: | Maritime Life Business Park
Dues: | None
Email Address: | 71650.2646@compuserve.com
Phone Number: |
Internet URL: |
Description: | News, Q&A, Presentations


Toronto Area Delphi Developers Association

Group Name: | Toronto Area Delphi Developers Association (TaDDA!)
Person(s) in Charge: | Henri Fournier (President), Robert Kozak (Membership Director), Ted Nye (Executive Director)
Meeting Date/Time: | First Tuesday of each month
Meeting Location: | North Youk Public Library, Toronto, Ontario, Canada
Dues: | $60/year
Email Address: | membership@TaDDA.com
Phone Number: | 416-366-7150
Internet URL: | http://www.tadda.com
Description: | 3 Hours. Sessions by well known Delphi experts such as Mark Miller, Ray Konopka, Charlie Calvert, etc. and in depth sessions on all aspects of Delphi for New to Advanced users.


Vancouver Delphi Developers Association

Group Name: | Vancouver Delphi Developers Association
Person(s) in Charge: | Michael Li
Meeting Date/Time: | Third Wednesday of each month, 6:30pm
Meeting Location: | Liquor Distribution Branch, 2625 Rupert Street, Vancouver, BC
Dues: | None
Email Address: | mli@infocan.com
Phone Number: | 604-736-5888 x728
Internet URL: | http://www.infocan.com
Description: | Michael Li is usually the main speaker at meetings. Informal setting. Michael's main focus is on Delphi and Borland related topics and discussion, updates on new technology (hardware, software) coming out to the market, updates on books that are useful to particular products (provide evaluation copies for review), information on conferences coming up in Vancouver. May have guest speakers depending on the topic.


Western Slope Visual Developers Group

Group Name: | Western Slope Visual Developers Group
Person(s) in Charge: | Shane Holmes, Software Engineer, ViA Software Services
Meeting Date/Time: | Last Wednesday of each month, 6:30pm
Meeting Location: | ViA Software Services, 743 Horizon Court, Suite 368, Grand Junction, CO 81506
Dues: | None
Email Address: | sholmes@viagj.com
Phone Number: | 970-257-7010, 970-248-9733
Internet URL: | http://www.gj.net/~hap
Description: |


Denver Borland Users Group

Group Name: | Denver Borland Users Group (DeBUG)
Person(s) in Charge: | Ron Kocsis, Chuck Gadd
Meeting Date/Time: | 6:30pm, 2nd Tuesday of the Month
Meeting Location: | Suite #1350 at 5299 E. Prentice Ave, Greenwood Village, CO
Dues: | $30/year
Email Address: | cgadd@cfxc.com
Phone Number: | 303-933-4159
Internet URL: | www.fcxc.com/debug
Description: | Presentation by members or third-party companies.


Central Iowa Delphi Users Group

Group Name: | Central Iowa Delphi Users Group
Person(s) in Charge: | David W. Body
Meeting Date/Time: | Third Thursday of every month at 5:30 pm
Meeting Location: | Offices of Iowa Bankers Association, Liberty Building, 418 6th Ave. Suite 430, Des Moines, Iowa.
Dues: | None
Email Address: |
Phone Number: | 515-984-6243
Internet URL: | http://www.bigcreek.com/delphi
Description: |


Kansas City Delphi User Group

Group Name: | Kansas City Delphi User Group
Person(s) in Charge: | Shawn McDonald, Kerri VanMevern
Meeting Date/Time: | 1st Wednesday of each month, 6:30pm
Meeting Location: | DRT Systems, 4501 College Blvd., Leawood, KS
Dues: | $24/year
Email Address: | mofnet@aol.com
Phone Number: | 913-661-9669 x265
Internet URL: | http://www.kcdelphi.org
Description: | Flexible format includes presentations by members, code reviews, and question and answer


Delphi Developers Group of Greater Boston

Group Name: | Delphi Developers Group of Greater Boston
Person(s) in Charge: | Al Renhart, DisCom Systems
Meeting Date/Time: | Third Monday of each month, 7:00 pm
Meeting Location: | 10 New England Executive Park, Burlington, MA
Dues: |
Email Address: | reinhart@discom.com
Phone Number: | 508-869-6417
Internet URL: |
Description: |


TCPC Delphi SIG

Group Name: | TCPC Delphi SIG
Person(s) in Charge: | Richard Hansen
Meeting Date/Time: | 4th Wednesday of Month, 7pm
Meeting Location: | 2850 Metro Drive, Room 124 - Bloomington, MN
Dues: | None
Email Address: | rickh@artemisalliance.com
Phone Number: | 612-227-7172
Internet URL: | http://www.tcpc.com
Description: | Questions & Answers, Monthlu topic, Focus Groups.


Royal Oak Delphi Users Group

Group Name: | Royal Oak Delphi Users Group
Person(s) in Charge: |
Meeting Date/Time: | First Thursday of each month at 7:00 pm
Meeting Location: | William Beaumont Hospital (Lower Level), Royal Oak, MI. Classrooms in AB-West building.
Dues: | None
Email Address: |
Phone Number: | 810-551-5000
Internet URL: | http://ourworld.compuserve.com/homepages/STNICOL/
Description: | Constructing DLL's, SQL Server 6.5, CGI, Email enabled databases, data collection alternatives, VCL parties, book review night, etc.


Research Triangle Park Delphi Users Group

Group Name: | Research Triangle Park Delphi Users Group
Person(s) in Charge: | Mark Hutchinson
Meeting Date/Time: | Third Wednesday of each month, 5:00 pm
Meeting Location: | New Horizons Computer Learning Center - Willow Oak Bldg, Suite 116, 4625 Creekstone Drive, Durham, NC
Dues: |
Email Address: | aikimark@aol.com
Phone Number: |
Internet URL: | http://www.geocities.com/CapeCanaveral/Lab/1185/rtpdig.html
Description: |


Delphi SIG of the Greater Cleveland PC Users Group

Group Name: | Delphi SIG of the Greater Cleveland PC Users Group
Person(s) in Charge: | Bill Querry
Meeting Date/Time: | Fourth Wednesday of each month, 6:30 pm - 8:30 pm
Meeting Location: | 2747 SOM Center Rd, Willoughby OH 44094
Dues: | Free for Meetings. $25/year for GCPCUG
Email Address: | bq@bigfoot.com
Phone Number: | 440-944-9980
Internet URL: | http://www.gcpcug.org
Description: | Demos of some feature of Delphi or 3rd Party Add-On. General discussion of user's current projects & problems. Talk about latest magazines/book releases.


Columbus Delphi SIG

Group Name: | Columbus Delphi SIG
Person(s) in Charge: | Rick Ross
Meeting Date/Time: | 2nd Wednesday of every month. 7-9pm
Meeting Location: | 1091 W. Broad St., Columbus, OH
Dues: | None
Email Address: | rickross@compuserve.com
Phone Number: | 614-898-2767
Internet URL: |
Description: | Demonstrations, discussion, and training


Greater Dayton Delphi Group

Group Name: | Greater Dayton Delphi Group (GDDG)
Person(s) in Charge: | Keith Wire
Meeting Date/Time: | Second Thursday of each month
Meeting Location: | Dayton, OH
Dues: | $50/Year
Email Address: | kwire@compuserve.com
Phone Number: |
Internet URL: | http://www.aii-usa.com/gddg
Description: | Sharing of Delphi-related information


Oregon Delphi Users Group

Group Name: | Oregon Delphi Users Group
Person(s) in Charge: | Greg Postlewaite
Meeting Date/Time: | 3rd Monday of every month, 7pm
Meeting Location: | Lorenzen Center, Emanuel Hospital, Portland, OR
Dues: |
Email Address: |
Phone Number: |
Internet URL: |
Description: |


Pittsburgh Area Delphi Users Group

Group Name: | Pittsburgh Area Delphi Users Group
Person(s) in Charge: | Kirk A. Farra
Meeting Date/Time: | Second Thursday of the month at 7:00 pm
Meeting Location: | Mastech Inc.
Dues: | None
Email Address: |
Phone Number: | 412-452-6121
Internet URL: | http://www.nauticom.net/www/kfarra
Description: | We cover Delphi and any related products/tools. Members are exposed to many 3rd party components and have a local support network for Q/A. Members get to review many products before they are released and get information on local job opportunities and contracting positions.


Borland Technologies User Group

Group Name: | Borland Technologies User Group
Person(s) in Charge: | Matt Beckius
Meeting Date/Time: | Undetermined (we are just forming now)
Meeting Location: | Philadelphia, PA
Dues: | Undetermined
Email Address: | Undetermined
Phone Number: | 610-409-8229 extension 8
Internet URL: | http://www.sourcetechcorp.com/borland.htm
Description: | Product Reviews, Demonstrations, Discussions


Salt Lake City Delphi Users Group

Group Name: | Salt Lake City Delphi Users Group
Person(s) in Charge: | Robert Love, John Rendell, Mike Mormondo
Meeting Date/Time: | 3rd Thursday of every month
Meeting Location: | Franklin Covey Headquarters
Dues: | None
Email Address: | slcdug@lovedata.com
Phone Number: | 801-296-0809
Internet URL: | http://www.lovedata.com/delphislc
Description: | Each meeting is different but usually it is a presentation of a new idea or product that relates to delphi. There is a Q/A Session in every meeting to help you move along as well.


Form For Users Groups

If your Delphi Users Group is not mentioned in the list, please take a moment to email me the particulars about your group. To make the information as uniform as possible, please cut and paste this form into an email and send it to me at RobertV@compuserve.com. Please only send one if you are in charge of the group… I don't want to have to wade through 30-40 copies for each group… Thanks!

Group Name:
Person(s) In Charge:
Meeting Date/Time:
Meeting Location (include City & State):
Dues:
Email Address:
Phone Number:
Internet URL:
Brief description of meeting format:


 The Delphi Workout
  • Professional Delphi Training for Under £100
  • One of the World's leading Delphi Trainers
  • Great sessions to enhance your Delphi Skills
  • FREE Full 170 page course book
  • FREE Developers CD with over 1200 tools and components
  • FREE £600 off Borland Tools
  • Sessions in London (Westminster Hall) and Manchester (United Football Club)

    • Zack Urlocker (Borland VP Marketing) says: "A must for Developers who want to take their Delphi skills to the next level. Highly recommended"

    To register:

    Phone:      0800 833022
    Fax back:   0118 954 6978
    E-Mail:     workout@multizone.com
    On-Line:    http://www.multizone.com/workout
    Mail:       The Delphi Workout
                Multizone International
                Caversham Business Centre
                23 Prospect St, Caversham, RG4 8JB.
    When:       19th, 20th March 1998 and other dates TBA

    Course Outline:

    8.30-9.00 Registration

    9.00-9.30 Warming up
    In this section we'll discuss some generic tips to working with Delphi 2 including some focus on exciting new methods of working in Delphi 3

    9.00-9.30 - Delphi Overview
    Delphi 2&3, ObjectPascal, Code Insights, Components, BDE. This session will give a very quick overview of some 32-bits Delphi features, such as Code Insights, the VCL Component Palette/Packages, Data Modules, Form Inheritance, ActiveX controls, and the Database-Form Wizard, etc.

    9.30-10.45 The Top 10 Ways to becoming a better Delphi Programmer
    In this section we'll focus on ObjectPascal, exception handling, and performance optimization, positioning most of this on Delphi 2, but highlighting new better ways to do it in Delphi 3 as well

    9.30 -10.00 - ObjectPascal
    ObjectPascal, Exceptions, Try-Except, Try-Finally, Raise, Assert. This session will start with new ObjectPascal features, followed by the benefits of structured exception handling as the preferred way of error detection, error handling and resource management. All Delphi 2 compatible. At the end of the session, we'll also examine a new Delphi 3 feature called assertions, to support preconditions and error detection.

    10.00-10.45 - 32-bits Efficiency
    Profiling, Algorithms & Datastructures, Language Features. This session will identify the steps of performance optimization: finding bottle-necks, checking algorithms & datastructures, and new 32-bits Delphi language features. A number of examples will illustrate what difference it can make in performance to know and apply the tips and techniques from this session.

    10.45-11.00 Coffee

    11.00-12.30 The Top 10 Secrets to building Rapid Applications
    In this section we'll focus on the developer and his building tools (components, packages and Delphi IDE experts/wizards) to help building Rapid Applications.

    11.00-11.45 - Component Building
    Component Wizard, Properties, Methods, Events. This session will teach the basics of component building, as we focus on the Component Wizard, followed by the creation of a component skeleton, the addition of properties, methods, events and event handlers. We'll move on by installing the component in the Component Palette, or in a Delphi 3-specific package

    11.45-12.00 - Delphi 3 Packages
    Design Time, Run Time, Deployment, Versioning. This session will explain what Delphi 3 packages are, how they can benefit our projects (size of executable), how to make our own custom packages with components, and how to deploy them correctly.

    12.00-12.30 - Experts and Wizards
    IDE, Open Tools API, Experts, Wizards. This session will show how to extend the Delphi IDE itself by using the Open Tools API to write Experts (that plug into the IDE) and Wizards, including some User Interface guidelines for writing Wizards.

    12.30-13.30 Lunch

    13.30-14.00 Unleashing the hidden power of Databases within Delphi
    BDE, Tables, Queries, data-aware components. This session will show the database basics, including tables, queries, data-aware components and how to (re-) create your own tables with ObjectPascal source code.

    14.00-14.45 - The Best of Delphi (UK-BUG)
    A Borland User Group representative will highlight how to unearth the most comprehensive guide (the DIL database) where to find free Delphi Code,
    tools, samples and support.

    14.45-17.00 Building Killer Web Applications
    In this section we'll start by seeing how we can use Delphi 2 for data-aware net development, followed by some next exciting techniques and net development support in Delphi 3.

    14.45-15.10 - Table to HTML
    HTML, Tables, Image Map, Table-layout, Index Fields, Frames. This session will shortly introduce the basic concepts of HTML, followed by a Wizard that can be used to convert the contents (records) of a table to a set of static HTML-pages that can be uploaded to the web.

    15.10-15.30 - CGI and WinCGI
    CGI/WinCGI, GET/POST, State, Debugging CGI. This session will extend our HTML knowledge with the Common Gateway Interface protocol, which is a way to interact between the web client and the web server. Delphi 2 compatible.

    15.30-15.45 Afternoon Tea

    15.45-16.15 - Delphi 3 ActiveForms
    New ActiveForm, Converting existing Forms, Deployment. This session will illustrate how to write, use and deploy ActiveForms on the web, including an example where we publish a table on an ActiveForm on the Internet.

    16.15-17.00 - Delphi 3 C/S WebModules
    WebModule, Dispatcher, PageProducer, TableProducers. This session will demonstrate the Delphi 3 Client/Server-only capabilities of the Web Modules to create and support CGI/WinCGI and ISAPI/NSAPI web server applications, including an example where we connect a database to the web, with options to browse, query and update the database contents.

    17.00-17.30 Cooling Down

    17.00-17.30 - The Future of Delphi (Borland)
    A Borland Product Manager will talk to the audience for half an hour on the future of Delphi... and answer questions from the audience.


Product Reviews & Announcements

I have moved all the announcements and reviews of books, and other Delphi related products to this page. If you have a product you would like to see reviewed, or wish to do a review yourself, please feel free to contact me at RobertV@csi.com.

Issue #24 - A Second Look at MicroEdge's Visual SlickEdit
Issue #23 - Book Review: Hidden Paths of Delphi 3
Issue #23 - Book Review: Building Delphi 2 Database Applications
Issue #23 - Raize Components
Issue #22 - Programmers Guild Animated Tray Icon
Issue #22 - MicroEdge's Visual SlickEdit
Issue #22 - IniOut Component
Issue #22 - Addict 2.2 Spell Checker for Delphi
Issue #21 - Book Review: Delphi Component Design
Issue #20 - Delphi Books and Periodicals
Issue #19 - SpeedDaemon Code Profiler
Issue #19 - A Look at MagiKit
Issue #18 - Object Express by OopSoft
Issue #18 - Announcement: IniOut Component
Issue #18 - Book Review: Delphi Component Design by Danny Thorpe

More links to come! To see the material in Issues 1 through 17, click here.


Delphi Job Sites

Below are some of the Delphi Job sites currently available. If you know of others, please let me know about them and I will add a link on this page.

    Employment at Borland/Inprise
    http://www.borland.com/about/hr/

    Borland/Inprise Delphi Jobs Newsgroup
    news://forums.inprise.com/borland.public.delphi.jobs

    Delphi Job Hunter
    http://www.inthemiddle.co.uk/jobhunter/delphi/default.htm

    Mike Strock's Delphi Jobs Site
    http://www.oz.net/~mstrock/delphijobs.html

    Greg Postlewait's Delphi Jobs Site
    http://www.teleport.com/~gpost/djobs

    Richard Fellner's Delphi Job Exchange
    http://www.user.xpoint.at/r.fellner/DELPHIJ.HTM

    Richard Maley's Delphi Jobs Service
    http://www.advdelphisys.com/jobs/jobs_all.html

    Becker Technology, Inc.
    http://www.beckertechnology.com/emplopps.htm

Additional Programming-Related Job Sites
    Jobs for Programmers
    http://www.prgjobs.com

    JobServe UK
    http://www.jobserve.com


The Unofficial Newsletter of Delphi Users - Past UNDU Issues

Past UNDU Issues

Below are links to all the issues of UNDU that are currently available to read online. If you want to obtain these same issues in a downloadable format, please check the section on Downloadable UNDU Issues.

Issue #24 - December '97
Issue #23 - September '97
Issue #22 - June '97
Issue #21 - May '97
Issue #20 - March '97
Issue #19 - January '97
Issue #18 - November '96
Issue #17 - October '96
Issue #16 - September '96
Issue #15 - August '96
Issue #14 - June '96
Issue #13 - May '96
Issue #12 - February '96
Issue #11 - January '96
Issue #10 - December '95
Issue #9 - November '95
Issue #8 - October '95
Issue #7 - August '95
Issue #6 - July '95
Issue #5 - June '95
Issue #4 - May '95 (b)
Issue #3 - May '95 (a)
Issue #2 - April '95
Issue #1 - March'95


The Unofficial Newsletter of Delphi Users - Downloadable UNDU Issues

Downloadable UNDU Issues

Since issue #1 in March of 1995, all issues of The Unofficial Newsletter of Delphi Users has been published as Windows Help files. Below are links to each of these files so you can download them individually, or all at once. To speed downloading time, I have Zipped them, so you will need PKUNZIP or an equivalent program to decompress them. If you don't have a ZIP compatible program, you can download just the HLP file.

When you unzip them, I suggest that you put all issues in a single directory. Many of the files have links to other issues and if they are all present together, they will behave normally. Most of the later issues in ZIP file format also have a contents file (*.CNT) which is used to by the Windows help system to display a complete list of all issues available.

Effective January, 1998 - I will no longer be arranging UNDU as "issues", but rather as individual articles that will be posted on the UNDU web site every few days. At some time in the future, I may start packaging these articles as downloadable WinHelp files, but I am not promising anything at this point.

Issue # - Month of Release | Zip File | HLP File
Issue #24 - December '97 | DN971201.ZIP | DN971201.HLP
Issue #23 - September '97 | DN970901.ZIP | DN970901.HLP
Issue #22 - June '97 | DN970601.ZIP | DN970601.HLP
Issue #21 - May '97 | DN970501.ZIP | DN970501.HLP
Issue #20 - March '97 | DN970301.ZIP | DN970301.HLP
Issue #19 - January '97 | DN970101.ZIP | DN970101.HLP
Issue #18 - November '96 | DN961101.ZIP | DN961101.HLP
Issue #17 - October '96 | DN961001.ZIP | DN961001.HLP
Issue #16 - September '96 | DN960901.ZIP | DN960901.HLP
Issue #15 - August '96 | DN960801.ZIP | DN960801.HLP
Issue #14 - June '96 | DN960601.ZIP | DN960601.HLP
Issue #13 - May '96 | DN0596.ZIP | DN0596.HLP
Issue #12 - February '96 | DN0223.ZIP | DN0223.HLP
Issue #11 - January '96 | DN0118.ZIP | DN0118.HLP
Issue #10 - December '95 | DN1212.ZIP | DN1212.HLP
Issue #9 - November '95 | DN1109.ZIP | DN1109.HLP
Issue #8 - October '95 | DN1010.ZIP | DN1010.HLP
Issue #7 - August '95 | DN0831.ZIP | DN0831.HLP
Issue #6 - July '95 | DN0725.ZIP | DN0725.HLP
Issue #5 - June '95 | DN0626.ZIP | DN0626.HLP
Issue #4 - May '95 (b) | DN0524.ZIP | DN0524.HLP
Issue #3 - May '95 (a) | DN0501.ZIP | DN0501.HLP
Issue #2 - April '95 | DN0401.ZIP | DN0401.HLP
Issue #1 - March '95 | DN0315.ZIP | DN0315.HLP


The Unofficial Newsletter of Delphi Users - News

News Page

February 28th, 1998

You will have to forgive me everyone if I am not my usual cheerful self today... I am in mourning. Apple computer today announced the discontinuation of the MessagePad and Emate line of hand-held computers. I have been an avid fan of the MessagePad line since the MP110 came out a number of years ago. I have since had an MP2000 and now have an MP2100. It is a fantastic device and I am greatly disappointed to see it dropped like a hot rock. Maybe it is not too late for some other company to revive it. I suppose I can still hope... Anyway, I still think that porting the Delphi development system to the Newton would have been the thing that would have saved them... <grin>...

Back on the Delphi scene, we have great article for all you digital sound fans out there. Tex Murphy presents Digital Sound and Music in Delphi.

Keep an eye out in the next day or two. I will be posting the prizes awarded for the contributors for the month of February! Also, another reminder to fill out the survey if you haven't already!

February 26th, 1998

Borland has recently announced that for its fiscal year 1998 third quarter and nine months ended December 31, 1997, that the company has delivered a third consecutive quarter of profitability with revenues up 17 percent. If you want to learn more about this, you can check out the Borland press report at http://www.borland.com/about/press/1998/3rdq98.html.

Need to look for files in your Delphi app? Eddie Shipman shows how you can access the Win95 FindFiles dialog from within your application.

I wanted to also say thanks to those of you who have been filling out the survey. It is clear that people still want some form of downloadable information, so maybe the solution is to offer a downloadable "archive" of all articles and tips/tricks each month. If you haven't had a chance to check out the survey, please take a few moments to do it... Thanks!

February 24th, 1998

I have put together a small survey to get some input on the new UNDU site. Please take a few moments to fill it out.

February 23rd, 1998

Do you have a hard time telling which edit field on a form has the focus? Problem solved... check out the tip on Giving Your EditBoxes Some Attention by Herbert J. Beemster. Also, Lance Leonard presents an improved method of cutting, copying, and pasting from the active control.

February 21st, 1998

More changes in the UNDU world... I have thought a great deal about this and have decided for the sake of simplicity to abandon the concept of specific "issues" of UNDU. Because of this decision, Issue #24 will the last real issue of UNDU that you will see. Instead, I will be posting my articles, and those I receive from outside contributors every couple of days and noting them here on the News page and adding them as links in the Tips & Tricks and Articles & Reviews pages.

The advantages are many: It will simplify my work load considerably, because I wouldn't have to dedicate many days of effort to get out a single issue. I will also be able to bring material to readers in a much more timely manner (i.e. every few days instead of every few months). The big disadvantage is of course that I would no longer be putting out the downloadable Windows Help File issues (*.HLP). I know this is going to upset quite a few of you out there who don't like to read things online, but I will keep that in mind when putting articles together. For example, I will try to keep articles all together as one link, so when you visit it, you can print it out, save it to disk, or whatever, without having to hunt your way through multiple links just to read one article.

I am excited about this new format and would welcome readers comments on this decision. I really appreciate everyones support to UNDU... I have a ton of really great articles that are going to start flooding your way. So brace yourself! Note also that I will still be giving out prizes to randomly-selected contributors. I have plenty of great things to give away so at the end of each month, there will be an announcement of who the winner(s) are!

To get things off to a good start, here are some new articles:

Delphi 3's Code Parameters - by Clinton R. Johnson
CD Change Notifications - by Tom Deprez

February 20th, 1998

Matt Price of Multizone International has announced low-cost (under £100) training seminars in the United Kingdom entitled "The Delphi Workout". Sessions will be held in London and Manchester on March 19th and 20th. For more information, you can check here, or go to their web site.

There is also now a non-frames version of the UNDU site.

February 19th, 1998

Many of you have sent me emails about the structure of the site, particularly the way the frames work so I have made some changes in this area. Also, note that for a while many of the links in the issues of UNDU will be wrong, as they are still pointing to the informant.com site. I will be correcting these as time goes on, so please bear with me.

February 17th, 1998

Some updated links in Tips & Tricks and Index of Articles.

February 16th, 1998

Welcome to the new site for The Unofficial Newsletter of Delphi Users! It has taken me a while to get this arranged, and I appreciate everyone's patience. Over the next week or so, I will be getting this site up to speed and also posting issue #25. As you can see, I am arranging things a bit differently here...

The Delphi News link will take you here to this page. This is where I will be reporting on Delphi-related events, product announcements, you name it. If it is happening in the Delphi world, I will try to report it here. I will attempt to report something every day or two, as it becomes available. If you have a new Delphi-related product, why don't you let me know about it?

The Current Issue link will take you to the latest issue of The Unofficial Newsletter of Delphi Users. This site uses Frames to display the issue, so for the time being your browser will need to be frames-capable (IE and Netscape both are). The Past Issue link will show you all the issues of UNDU that have been published. The Downloadable UNDU Issues link will show you all the downloadable issues of UNDU. Here, you can download them as Windows HLP files.

The Tips & Tricks link will show you just the tips and tricks articles from all back issues. This is a work in progress at this point, so it will become more complete as time goes on. The Articles & Reviews link will show you a list of all the other (non tips and tricks) articles from past issues of UNDU. Finally, for a list of Delphi User Groups (at least those who have let me know they exist), check out the Delphi User Groups link.

Make sure you check the UNDU site for all your Delphi-related needs!

Do you have comments? Feel free to email me!