Attributes

This page will contain useful functions for managing attributes

Table of Contents

'Written by Graham French, NBN Trust September 2008 and is supplied as is, this function has not been extensively checked. Please check that it is correctly determining the number of characters for the attribute. Send any comments to ku.gro.nbn|atad#ku.gro.nbn|atad
'WORKS IN MICROSOFT ACCESS AND EXCEL (in ACCESS replace IsEmpty function with IsNull function)

Attributes

This function checks that the attribute is not longer than 80 characters
'CHECKS ATTRIBUTE IS NOT LONGER THAN 255 CHARACTERS

**Public Function NBN_Check_Length_of_Attribute(attributevalue As Variant) As String**

Dim attributelength As String

If IsEmpty(attributevalue) Then
    attributelength = "Ok"
Else
    If Len(attributevalue) <= 255 Then
        attributelength = "Ok"
    Else
        attributelength = "Too long (" & Len(attributevalue) & " characters)"
    End If
End If

NBN_Check_Length_of_Attribute = attributelength

**End Function**
Page tags: attributes client vba
page_revision: 7, last_edited: 1237830001|%e %b %Y, %H:%M %Z (%O ago)
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License