   Help for SoundX

Properties

Registration Information

Order Form

Getting Custom Controls Written

Description

This control provides Soundex and Metaphone algorithms.  Soundex and Metaphone convert words or names to codes that represent how they sound.  This can be really useful in a database application where users need to find names they may not know how to spell exactly.

SoundX generates Soundex and Metaphone codes from words supplied to it.  You can use this codes to make database searching easier for your users.

To generate the code, simply set the Word propWord property with the word or name you want a code back for.  When you do this, SoundX generates the codes for all three of the algorithms (Soundex, Extended Soundex, and Metaphone).  All you have to do is read the appropriate property: Soundex, ExtSoundex, or Metaphone.

File Name

SOUNDX1.VBX

Object Type

SoundX

Compatibility

VB 1.0 and above

Remarks

When the Enabled property is set to True (default), SoundX automatically starts sending menu event notification messages when the user selects menu items at run-time.

SoundX should be placed on all forms where its functionality is required (including MDI forms and children).  SoundX can be placed directly on an MDI form.

About the Soundex Algorithm

Soundex is an algorithm developed and patented by Margaret Odell and Robert Russell in the early part of this century (U.S. Patent 1,261,167 (1918) and 1,435,663 (1922)).  Dont worry about the patents, theyve long since expired.

Many articles have been written about it, but the best description Ive seen so far is by Donald Knuth in The Art of Computer Programming, Vol. 3.

Soundex converts a word or name to a code comprised of a letter followed by three digits.  Some redundancy is taken out of the word (such as stripping vowels, consonant doubles, etc.).  The first letter is preserved and the code is generated from what remains.

About the Extended Soundex Algorithm

This is a minor change to the basic Soundex algorithm.  In this algorithm, the first letter is treated like all the rest of the letters (i.e., if its a vowel, its stripped, if its part of a consonant double, the second is stripped (as in LLAMA), etc.).

This code is purely numeric.  This can result in faster database scans to pick out like-sounding words or names.

About the Metaphone Algorithm

Quite frankly, I dont know where Metaphone came from.  I got some source code from a friend a few years ago in my E-mail with the comment attached to it: Try this, its cool!

Well, I thought so, thats why it has been included in SoundX.  Metaphone does a better job than Soundex and Extended Soundex when it comes to representing like-sounding names.  Its drawback is that Metaphone is comprised purely of letters.  In other words, it takes up more storage and, in a large database, this can be costly.

This implementation only returns the first four (4) characters of the Metaphone string generated.  The code will generate more than that, but after some experimentation, this seemed like an ideal compromise between accuracy and storage space.

Distribution Note     When you develop and distribute an application that uses SoundX, you should install the file SOUNDX1.VBX into the users Windows SYSTEM directory.  SoundX has version information built into it.  So, during installation, you should ensure that you are not overwriting a newer version of SoundX.


Properties

All of the properties that apply to this control are in this table.  Properties that have special meaning for this control or that only apply to this control are marked with an asterisk (*).

Align	Name

Enabled	*Soundex

*ExtSoundex	Tag

Left	Top

*Metaphone	*Word

Enabled is the default value for the control.


ExtSoundex Property

See Also	Example

Description

Extended Soundex representation of the Word property.

Usage

[form.][control.]ExtSoundex

Remarks

When the Word property is set, this property is generated.  This property is the Extended Soundex equivalent of the Word property.  This property is read-only.

Data Type

String


See Also

Properties:

Metaphone

Soundex

Word


ExtSoundex Property Example

In this example, the program will take a word entered by the user and display the extended Soundex equivalent. To try this example, paste the code into the Declarations section of a form that contains a text box, a label, and a SoundX control.  Press F5.  Then, try various words in the text box.

Sub Edit1_Change ()

   SoundX1.Word = Edit1.Text

   Label1.Caption = SoundX1.ExtSoundex

End Sub


Metaphone Property

See Also	Example

Description

Metaphone representation of the Word property.

Usage

[form.][control.]Metaphone

Remarks

When the Word property is set, this property is generated.  This property is the Metaphone equivalent of the Word property.  This property is read-only.

Data Type

String


See Also

Properties:

ExtSoundex

Soundex

Word


Metaphone Property Example

In this example, the program will take a word entered by the user and display the Metaphone equivalent. To try this example, paste the code into the Declarations section of a form that contains a text box, a label, and a SoundX control.  Press F5.  Then, try various words in the text box.

Sub Edit1_Change ()

   SoundX1.Word = Edit1.Text

   Label1.Caption = SoundX1.Metaphone

End Sub


Soundex Property

See Also	Example

Description

Soundex representation of the Word property.

Usage

[form.][control.] Soundex

Remarks

When the Word property is set, this property is generated.  This property is the Soundex equivalent of the Word property.  This property is read-only.

Data Type

String


See Also

Properties:

ExtSoundex

Metaphone

Word


Soundex Property Example

In this example, the program will take a word entered by the user and display the Soundex equivalent. To try this example, paste the code into the Declarations section of a form that contains a text box, a label, and a SoundX control.  Press F5.  Then, try various words in the text box.

Sub Edit1_Change ()

   SoundX1.Word = Edit1.Text

   Label1.Caption = SoundX1.Soundex

End Sub


Word Property

See Also	Example

Description

Seed word for Soundex, ExtSoundex, and Metaphone properties.

Usage

[form.][control.] Word [ = word$ ]

Remarks

When this property is set, SoundX uses the appropriate algorithms to generate the Soundex, ExtSoundex, and Metaphone properties.

Data Type

String


See Also

Properties:

ExtSoundex

Metaphone

Soundex


Word Property Example

In this example, the program will take a word entered by the user and display the Soundex, Extended Soundex, and Metaphone equivalents. To try this example, paste the code into the Declarations section of a form that contains a text box, a wide label, and a SoundX control.  Press F5.  Then, try various words in the text box.

Sub Edit1_Change ()

   Dim S As String

   SoundX1.Word = Edit1.Text

   S = "Soundex:" & SoundX1.Soundex

   S = S & "    ExtSoundex:" & SoundX1.ExtSoundex

   S = S & "    Metaphone:" & SoundX1.Metaphone

   Label1.Caption = S

End Sub


Registration Information

Credits

SoundX was written by James Shields.  Inquiries can be sent to 71231,2066 on CompuServe, or mabry@halcyon.com on Internet.  Our mailing address is:

Mabry Software, Inc.

Post Office Box 31926

Seattle, WA  98103-1926

Registration

You can register this program by sending $10 ($15 for international orders) and your address.  You can register SoundX and its C source code by sending $25 ($30 for international orders).  With your order, you will receive a copy of our manual documenting all of our controls.

For your convenience, an order form has been provided that you can print out directly from this help file.

E-mail Discount

You may take a $5 discount for e-mail delivery of this package (CompuServe or Internet).  If you choose this option, please note: a printed manual is not included.  Be sure to include your full mailing address with your order.  Sometimes (on the Internet) the package cannot be e-mailed.  So, we are forced to send it through the normal mails.

CompuServe members may also take the $5 e-mail discount by registering this package in the software registration forum (GO SWREG).  SoundXs SWREG ID number is 1272.  The source code version's ID number is 1273.

Credit Card Orders

We accept VISA and Mastercard.  If you e-mail your order to us, please be sure to include your card number, expiration date, complete mailing address, and your phone number (in case we have any questions about your order).

© Copyright 1993-1995 by Mabry Software, Inc.


Order Form
 SoundX Order Form

Use the Print Topic.. command from the File menu to print this order form.

Mail this	Mabry Software, Inc.

form to:	Post Office Box 31926

Seattle, WA  98103-1926

Phone: 206-634-1443

Fax: 206-632-0272

BBS: WinDev BBS 206-634-0783

CompuServe: 71231,2066

Internet: mabry@halcyon.com

Where did you get this copy of SoundX?

____________________________________________________________________

Ship to:	____________________________________________________________________

____________________________________________________________________

____________________________________________________________________

____________________________________________________________________

____________________________________________________________________

Phone:	_________________________________________________________________

Fax:	_________________________________________________________________

E-Mail:	_________________________________________________________________

MC/VISA:	_________________________________________ exp. ___________________

Disk Size:	(circle one)	 3½	5¼

qty ordered	____	REGISTRATION

$10 each, postpaid (check or money order in hard currency). Outside of North America add $5.00 shipping.

qty ordered	____	SOURCE CODE AND REGISTRATION

$25 each, postpaid (check or money order in hard currency). Outside of North America add $5.00 shipping.


Getting Custom Controls Written

If you or your organization would like to have custom controls written, you can contact me at the following:

James Shields

Mabry Software, Inc.

Post Office Box 31926

Seattle, WA  98103-1926

Phone: 206-634-1443

Fax: 206-632-0272

BBS: WinDev BBS 206-634-0783

CompuServe: 71231,2066

Internet: mabry@halcyon.com

You can also contact Zane Thomas.  He can be reached at:

Zane Thomas

Post Office Box 300

Indianola, WA  98342

CompuServe: 72060,3327