Free Advertising Forums | Free Advertising Board | Post Free Ads Forum | Free Advertising Forums Directory | Best Free Advertising Methods | Advertising Forums

Free Advertising Forums | Free Advertising Board | Post Free Ads Forum | Free Advertising Forums Directory | Best Free Advertising Methods | Advertising Forums (http://www.freeadvertisingzone.com/index.php)
-   General Free Advertising Directories (http://www.freeadvertisingzone.com/forumdisplay.php?f=83)
-   -   Discount Office 2007 A Simple Solution for Plurali (http://www.freeadvertisingzone.com/showthread.php?t=1048267)

04-10-2011 05:43 AM

Discount Office 2007 A Simple Solution for Plurali
 
Reader Patrick Jackman of Vancouver, BC has submitted a useful “fit-and-finish” tip. Here is a simple tip that I use quite often in MsgBox prompts when the message involves reporting the results of a count. Function Pluralize(ByVal varCount As Variant,Office Pro 2007 Key, Optional Singular _
                    As Variant, Optional Plural As Variant) _
                    As String     If Not IsNull(varCount) Then
        If varCount <> 1 Then
            If IsMissing(Plural) Then
                Pluralize = "s"
            Else
                Pluralize = Plural
            End If
        Else
            If Not IsMissing(Singular) Then
                Pluralize = Singular
            End If
        End If
    End If
End Function Here is an example of how I would use it without the optional parameters: strMsg = "Your search returned " & intCount & " item" & _
            Pluralize(intCount) & "." When intCount is 1,Office 2010 Home And Business, strMsg would be: Your search returned 1 item. When intCount is 2, strMsg would be: Your search returned 2 items. Here is an example using the optional parameters: strMsg = "Print " & intCount & " cop" & _
            Pluralize(intCount, "y",Office 2010 Keygen, "ies") & "?" When intCount is 1,Discount Office 2007, strMsg would be: Print 1 copy? When intCount is 2, strMsg would be: Print 2 copies? For more information,Office 2007 License, you can contact Patrick here. <div


All times are GMT. The time now is 01:24 AM.

Powered by vBulletin Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Free Advertising Forums | Free Advertising Message Boards | Post Free Ads Forum