Copyright: ® 1994, Bits & Bytes Solutions.


CONTENTS
INIMAGIC Version 2.2

Registration

How to register INIMAGIC?

Description

The INIMAGIC custom control allows the application developer to easily
access initialization(.INI) files. Additionally, the control encapsulates the
functions and properties necessary to manage .INI files and more...

File Name

INIMAGIC.VBX

Version

2.2

Object Type

BBSIniMagic

Toolbox Icon

Remarks

The INIMAGIC custom control can only be used within Visual Basic© 3.0.
Additonally, an INIMAGIC.LIC file is needed to load/compile an application
using the INIMAGIC custom control, without this file it is impossible to do
any development work with INIMAGIC. Additionally, the INIMAGIC.LIC file
must reside in the Microsoft Windows directory.

Miscellaneous Information

What is Shareware?

Disclaimer of Warranty

Copyright

Distribution Note

When you create and distribute applications that use the INIMAGIC
custom control, you should install the file INIMAGIC.VBX in the customer's
Microsoft Windows \SYSTEM subdirectory. The INIMAGIC.LIC file should not be distributed with the application that uses INIMAGIC.VBX. The
INIMAGIC.LIC file is for the design time environment ONLY.


Types of Registration

Please select one of the registration methods that you prefer. On-Line
registration with CompuServe will be the fastest response.

Registration by Mail

Registration On-Line with CompuServe


Registration by Mail

To Register by Mail (Check or Money Order ONLY)

Please register my copy of INIMAGIC Version 2.2, I am sending a check
or money order for the appropriate amount:

*Single and Multi-User Registration Information

Single user      ........................$30.00

10 to 20 User   ......................$300.00

Unlimited User ......................$500.00

* Single User = 1 WorkStation. Additionally read the "Disclaimer of Warranty."

Registration Information

Signature: ___________________________________________________

Name:      ___________________________________________________
Company: ___________________________________________________
Address:   ___________________________________________________
Address:   ___________________________________________________
City:         ___________________________________________________
State:       ___________________________________________________
Zip Code:  ___________________________________________________
Country:   ___________________________________________________
Tel:          (____) ____-________ (optional)

Please specify disk size:        3½ inch        5¼ inch

Feedback:

_____________________________________________________________
_____________________________________________________________
_____________________________________________________________
_____________________________________________________________

Send Completed Form with Payment to:


Registration with CompuServe

To register through Compuserve, GO SWREG and select registration
Id# 3248, registration fee will be billed to your Compuserve account.


Definition of Shareware

Shareware distribution gives users a chance to try software before buying it.
If you try a Shareware program and continue using it, you are expected to
register. Individual programs differ on details -- some request registration while
others require it, some specify a maximum trial period. With registration, you
get anything from the simple right to continue using the software to an updated
program with printed manual.

Copyright laws apply to both Shareware and commercial software, and the
copyright holder retains all rights, with a few specific exceptions as stated
below. Shareware authors are accomplished programmers, just like commercial
authors, and the programs are of comparable quality. The main difference is in
the method of distribution. The author specifically grants the right to copy and
distribute the software, either to all and sundry or to a specific group.

Shareware is a distribution method, not a type of software. You should find
software that suits your needs and pocketbook, whether it's commercial or
Shareware. The Shareware system makes fitting your needs easier, because
you can try before you buy. And because the overhead is low, prices are low
also. Shareware has the ultimate money-back guarantee -- if you don't use the
product, you don't pay for it.


Disclaimer of Warranty

Users of INIMAGIC must accept this disclaimer of warranty: "INIMAGIC
is supplied as is.  The author, Bits & Bytes Solutions disclaims all
warranties, expressed or implied, including, without limitation, the
warranties of merchantability and of fitness for any purpose. The author
assumes no liability for damages, direct or consequential, which may
result from the use of INIMAGIC."

INIMAGIC is a "shareware program" and is provided at no charge to the
user for evaluation.  Feel free to share it with your friends, but please do
not give it away altered or as part of another system.  The essence of
"user-supported" software is to provide personal computer users with
quality software without high prices, and yet to provide incentive for
programmers to continue to develop new products.  If you find this program
useful and find that you are using INIMAGIC and continue to use INIMAGIC
after a reasonable trial period, you must make a registration payment of
$30.00 to Bits & Bytes Solutions. The $30.00 registration fee will license
one copy for use on any one computer at any one time.  You must treat
this software just like a book.  An example is that this software may be
used by any number of people and may be freely moved from one computer
location to another, so long as there is no possibility of it being used at
one location while it's being used at another. Just as a book cannot be read
by two different persons at the same time.

Commercial users of INIMAGIC must register and pay for their copies
of INIMAGIC within 30 days of first use or their license is withdrawn.
Site-License arrangements may be made by contacting Bits & Bytes
Solutions.

Anyone distributing INIMAGIC for any kind of remuneration must first
contact Bits & Bytes Solutions at the address below for authorization.

You are encouraged to pass a copy of INIMAGIC along to your friends
for evaluation.  Please encourage them to register their copy if they find
that they can use it.  All registered users will receive a copy of the latest
version of the INIMAGIC system.


Copyrights and Trademarks

INIMAGIC is a copyright © 1994 of Bits & Bytes Solutions.
All rights reserved.

Microsoft Visual Basic is a registered trademarks of
Microsoft Corporation.

Information in this document is subject to change without
notice. No part of this document may be reproduced or
transmitted in any form or by any means, electronic or
mechanical, for any purpose, without express written
permission of Bits & Bytes Solutions.

This product is licensed to you pursuant to the terms of
the Bits & Bytes Solutions license agreement, and is
protected by copyright law and international treaties.
Unauthorized reproduction or distribution may result in
severe civil and criminal penalties, and will be prosecuted
to the maximum extent possible under the law.


About

Description

Displays the about dialog box for the INIMAGIC custom control.

Usage

At Visual Basic [design] time double click the "About (INIMAGIC)" property
and a dialog box will be displayed in the center of the screen.

Remarks

Displays Bits & Bytes Solutions company information, how to register to INIMAGIC custom control, some of the features, and some other pertinent information.


AccessMode

Description

Sets the access mode for initialization (.ini) files.

Usage

[form].AccessMode = {setting}

Remarks

The AccessMode property is useful for situations where all that needs to be done accomplished is updating/writing to (.ini) files, simply set the AccessMode to 1, and the only access to that (.ini) file is writing. No string data will actually be displayed.

Setting                 Description

     0                      Read ONLY mode

     1                      Write ONLY mode

     2                      Both (Read and Write) mode

Data Type

Boolean (Enumerated)

Code Example

Me!INIMAGIC1.AccessMode = 1


Current Direcory Text Display

This is a textual representation of the
current directory that you are in.


DIALOGBUTTONS
Available Dialog Buttons

Button Type            Description

     OK                      Closes down the dialog
                                with the currently selected
                                (.ini) file referenced.

     Cancel                 Closes down the dialog
                                with no (.ini) file referenced.

     *Network...           Displays network dialog for
                                connection to other drives.

                                           *Not available on all systems.


Directory Selector

A file manager approach to select
a directory to look into for some
(.ini) files.


Drive Selector

The different drives available to
search through.


Encryption

Description

Encrypts (.ini) string values. It does not support encryption of the entire
(.ini) file, only the string values stored for a paticular key.

Usage

[form].INIMAGIC1.Encryption = {True|False}

Remarks

With a small amount of code and turning on/off (True/False) the
encryption property it is possible to encrypt only certain strings within
a (.ini) file. Additionally, the encryption property can and will handle encryption of both alpha and/or alphanumeric constants.

Setting                  Description

  True                     Encryption support for the (.ini) string

  False                   Encryption not supported for the (.ini) string

Data Type

Boolean (Bool)

Code Example

Me!INIMAGIC1.Encryption = True


EncryptionKey

Description

Makes available the ability to encrypt strings within a (.ini) file. There are 2
levels of encryption for the INIMAGIC custom control:

1	EncryptionKey property (developer defined)

2	Internal VBX has an encoded encryption key
for an added level of security

Usage

[form].INIMAGIC1.EncryptionKey = {any text string}

Remarks

With the usage of the encryption property the EncryptionKey property can
be useful for hiding passwords within (.ini) files. The only limitation of the
EncryptionKey property is that it can only be a text string that can be used
for encryption, but it can be as long as you want it, and it can be upper or
lowercase. Just keep in mind the larger the EncryptionKey string the more
memory is being consumed.

Data Type

String

Code Example

Me!INIMAGIC1.EncryptionKey = "BitsBytesSolutions"

Important Note

If the Encryption property is set to True and an EncryptionKey string is not
specified the INIMAGIC custom control will handle the encryption by using
its own internal encryption coding. But its always best to specify your own
EncryptionKey.


File Name

The specified file name of the
(.ini) file to be accessed.


File Selector

Listing of current (.ini) files
within the current directory
that can be selected.


File Types

The various file types that can be accessed
using the INIMAGIC custom control. But, in
the INIMAGIC custom control's case ONLY
(.ini) files can be accessed.


INIFileName

Description

Sets the (.ini) file that will be accessed and manipulated.

Usage

[form]!INIMAGIC1.INIFileName = {[path]:\{ini file}}

Remarks

Within the usage of the INIFileName property if the (.ini) file is located in
the application directory there is no need to include the [path], but if the
(.ini) file is not within the application directory then the [path] must be
included.

Open Dialog Explanation

  * Pop-Up help available.

Data Type

String

Code Example

Me!INIMAGIC1.INIFileName = "C:\WINDOWS\WIN.INI"


INIKey

Description

The INIKey property is used to identify a key that is located under a
section header within an (.ini) file.

Simple example of an (.ini) file.

Usage

[form].INIMAGIC1.INIKey = {key string}

Remarks

After the selection of the INIFileName the rest of the properties of the
INIMAGIC control can be set at runtime. So that only one INIMAGIC.VBX
has to be utilized.

Data Type

String

Code Example

Me!INIMAGIC1.INIKey = "run"


INISection

Description

The INISection property is used to identify a section that is located within
the (.ini) file.

Simple example of an (.ini) file.

Usage

[form].INIAMGIC1.INISection = {section string}

Remarks

After the selection of the INIFileName the rest of the properties of the
INIMAGIC control can be set at runtime. So that only one INIMAGIC.VBX
has to be utilized.

Data Type

String

Code Example

Me!INIMAGIC1.INISection = "windows"


INIString

Description

The INIString property is used to identify the string that is associated with
the paticular key that is located under a section within the (.ini) file.

Simple example of an (.ini) file.

Usage

[form].INIMAGIC1.INIString = {a string | a number}

Remarks

After the selection of the INIFileName the rest of the properties of the
INIMAGIC control can be set at runtime. So that only one INIMAGIC.VBX
has to be utilized.

Data Type

String

Code Example

Me!INIMAGIC1.INIKey = "c:\vb\vb.exe"


Methods

All of the methods for this control are listed in the following table.


Properties

All of the properties for this control are listed in the following table.
Properties that require special attention for the INIMAGIC custom control
are marked with an asterisk (*).


Refresh

Description

Forces the INIMAGIC custom control to read/write data to the selected
(.ini) file.

Syntax

[form].INIMAGIC1.Refresh

Remarks

Use of this method is to force an immediate update of the selected (.ini)
file.

Code Example

Sub Form_Click()

  INIMAGIC1.INIFileName = "C:\WINDOWS\WIN.INI"
  INIMAGIC1.INISection = "windows"
  INIMAGIC1.INIKey = "test"
  INIMAGIC1.INIString = "INIMAGIC Version 2.2 Test"

  INIMAGIC1.Refresh

End Sub

Code Example Note

The above example also takes into consideration that the VBX is set to an
AccessMode of 2 (Both).


Version

Description

Gives the developer the ability to have full version information about the
INIMAGIC custom control.

Usage

[form].INIMAGIC1.Version

Remarks

This enables version controlling when installing on systems that may
already have another"older" version of INIMAGIC.

Data Type

String

Code Example

Msgbox Me!INIMAGIC1.Version, 64, App.Title