Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
NumericValue Property

IUccProperty.NumericValue Property

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

Gets and sets the numeric value of the property.

Namespace: Microsoft.Office.Interop.UccApi
Assembly: Microsoft.Office.Interop.UccApi (in microsoft.office.interop.uccapi.dll)

int NumericValue { get; set; }
/** @property */
int get_NumericValue ()

/** @property */
void set_NumericValue (int value)

function get NumericValue () : int

function set NumericValue (value : int)

Property Value

A value of the LONG* (int, for a .NET application) type.

An application should verify that a given property is set before accessing the property. An application must enclose a reference to a property NumericValue within a try/catch block to catch the COM exception raised when an un-initialized value property is accessed on the IUccProperty instance.

Win32 COM/C++ Syntax

HRESULT get_NumericValue
(
   LONG* plPropertyValue
);
HRESULT put_NumericValue
(
   LONG plPropertyValue
);
Cc715571.note(en-us,office.12).gifNote:
In a Win32 application, the return value of a method or property is always an HRESULT value indicating the status of the call to the interface member. Any result of the operation is returned as a parameter marked with the [out, retval] attribute. In contrast, in a .NET application the HRESULT value indicating an error condition is returned as a COM exception and the [out, retval] parameter becomes the return value. For the Unified Communications Client API-defined HRESULT values, see Trace and Handle Errors in Unified Communications Client API.

The following example returns a boolean value of true when the numeric property value of interest is initialized and a false value otherwise. The actual numeric value of the property is returned in an out parameter of the example method.


public Boolean GetPropertyIntValue(
   IUccPropertyCollection pPropertyCollection,
   int propertyId,
   out int propertyValue)
{
   //initialize return value
   Boolean returnValue = false;

   //initialize out value of interested property boolean value
   propertyValue = 0;

   //verify interested property was set
   if (pPropertyCollection.IsPropertySet(propertyId))
   {
      //get interested property and fill returnValue with string value of property
      IUccProperty property = pPropertyCollection.get_Property(propertyId);
      try
      {
         propertyValue = property.NumericValue;
         returnValue = true;
      }
      catch
      {
      }
   }
   return returnValue;
}

All public static (Shared in Visual Basic) members of this type are thread-safe. Instance members are not guaranteed to be thread-safe.

Development Platforms

Windows XP Professional with Service Pack 2 (SP2), Windows Server 2000 with Service Pack 4, Windows Server 2003, Windows Vista Ultimate Edition, Windows Vista Business Edition, Windows Vista Enterprise Edition

Target Platforms

Show:
© 2015 Microsoft