Visual Basic (VB and VBA)

Copyright 1999-2001 Christopher Greaves. All rights reserved.
Home Page and email to [email protected]
If in doubt, record a macro and inspect the entrails!

 

 

Please read the DISCLAIMER.

Here is an INDEX to all the procedures.

You will probably need one copy of my GLOBAL DECLARATIONS.



Public Function strCharsFromDigit(strDigit As String) As String
' Procedure :   strCharsFromDigit
' Description:  Test the position of the selection cursor
' Copyright: Chris Greaves Inc.
' Inputs:           None
' Returns:         TRUE if the selection is at the start of the document.
' Assumes:      Nothing
' Side Effects: None.
' Tested:           By the calls shown below.
    strCharsFromDigit = ""
    Select Case strDigit
        Case "1"
            strCharsFromDigit = "abc"
        Case "2"
            strCharsFromDigit = "abc"
        Case "3"
            strCharsFromDigit = "def"
        Case "4"
            strCharsFromDigit = "ghi"
        Case "5"
            strCharsFromDigit = "jkl"
        Case "6"
            strCharsFromDigit = "mno"
        Case "7"
            strCharsFromDigit = "prs"
        Case "8"
            strCharsFromDigit = "tuv"
        Case "9"
            strCharsFromDigit = "wxy"
        Case "0"
            strCharsFromDigit = "wxy"
        Case Else
            strCharsFromDigit = ""
    End Select
'Sub TESTstrCharsFromDigit()
'MsgBox strCharsFromDigit("0") ' empty string
'MsgBox strCharsFromDigit("1") ' empty string
'MsgBox strCharsFromDigit("2") ' abc
'MsgBox strCharsFromDigit("3") ' def
'MsgBox strCharsFromDigit("4") ' ghi
'MsgBox strCharsFromDigit("5") ' jkl
'MsgBox strCharsFromDigit("6") ' mno
'MsgBox strCharsFromDigit("7") ' prs
'MsgBox strCharsFromDigit("8") ' tuv
'MsgBox strCharsFromDigit("9") ' wxy
'MsgBox strCharsFromDigit("") ' empty string
'MsgBox strCharsFromDigit("a") ' empty string
'MsgBox strCharsFromDigit("*") ' empty string
'MsgBox strCharsFromDigit("#") ' empty string
'End Sub
End Function

We all knew nothing when we started …
Home Page and Contact Information
Send email to [email protected].
This page was last updated Thursday, November 15, 2001

 

 

Hosted by www.Geocities.ws

1

Visual Basic (VB and VBA)

Copyright 1999-2001 Christopher Greaves. All rights reserved.
Home Page and email to [email protected]
If in doubt, record a macro and inspect the entrails!

 

 

Please read the DISCLAIMER.

Here is an INDEX to all the procedures.

You will probably need one copy of my GLOBAL DECLARATIONS.

Public Function strCharsFromDigit(strDigit As String) As String
' Procedure :   strCharsFromDigit
' Description:  Test the position of the selection cursor
' Copyright: Chris Greaves Inc.
' Inputs:           None
' Returns:         TRUE if the selection is at the start of the document.
' Assumes:      Nothing
' Side Effects: None.
' Tested:           By the calls shown below.
    strCharsFromDigit = ""
    Select Case strDigit
        Case "1"
            strCharsFromDigit = "abc"
        Case "2"
            strCharsFromDigit = "abc"
        Case "3"
            strCharsFromDigit = "def"
        Case "4"
            strCharsFromDigit = "ghi"
        Case "5"
            strCharsFromDigit = "jkl"
        Case "6"
            strCharsFromDigit = "mno"
        Case "7"
            strCharsFromDigit = "prs"
        Case "8"
            strCharsFromDigit = "tuv"
        Case "9"
            strCharsFromDigit = "wxy"
        Case "0"
            strCharsFromDigit = "wxy"
        Case Else
            strCharsFromDigit = ""
    End Select
'Sub TESTstrCharsFromDigit()
'MsgBox strCharsFromDigit("0") ' empty string
'MsgBox strCharsFromDigit("1") ' empty string
'MsgBox strCharsFromDigit("2") ' abc
'MsgBox strCharsFromDigit("3") ' def
'MsgBox strCharsFromDigit("4") ' ghi
'MsgBox strCharsFromDigit("5") ' jkl
'MsgBox strCharsFromDigit("6") ' mno
'MsgBox strCharsFromDigit("7") ' prs
'MsgBox strCharsFromDigit("8") ' tuv
'MsgBox strCharsFromDigit("9") ' wxy
'MsgBox strCharsFromDigit("") ' empty string
'MsgBox strCharsFromDigit("a") ' empty string
'MsgBox strCharsFromDigit("*") ' empty string
'MsgBox strCharsFromDigit("#") ' empty string
'End Sub
End Function

We all knew nothing when we started …
Home Page and Contact Information
Send email to [email protected].
This page was last updated Thursday, November 15, 2001

 

 

Hosted by www.Geocities.ws

1