PropertyNotFoundException Class

IT Hit WebDAV for .NET

Thrown when server responded with Property Not Found http response for some property.

For a list of all members of this type, see PropertyNotFoundException Members.

System.Object
   System.Exception
      ITHit.WebDAV.Client.Exceptions.WebDavException
         ITHit.WebDAV.Client.Exceptions.WebDavHttpException
            ITHit.WebDAV.Client.Exceptions.PropertyException
               ITHit.WebDAV.Client.Exceptions.PropertyNotFoundException

[Visual Basic]
Public Class PropertyNotFoundException
    Inherits PropertyException
[C#]
public class PropertyNotFoundException : PropertyException

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Remarks

A request to retrieve the value of a property which does not exist is an error.

Example

 string license = "<?xml version='1.0' encoding='utf...
 WebDavSession session = new WebDavSession(license);
 session.Credentials = new NetworkCredential("User1", "pwd", "DOMAIN");

 IHierarchyItem item = session.OpenResource(new Uri("https://server/Library/doc.txt"));
 PropertyName[] propNames = new PropertyName[2];
 propNames[0] = new PropertyName("ManagerApproved", "Sales");
 propNames[1] = new PropertyName("Branch", "Sales");
 Property[] properties = null;

 try
 {
     properties = item.GetPropertyValues(propNames);
 }
 catch(PropertyNotFoundException ex)
 {
     Console.WriteLine(ex.Message + " " + ex.PropertyName);
 }
 if (properties != null)
 {
     foreach (Property prop in properties)
     {
         Console.WriteLine(prop.Name.NamespaceUri + ":" + prop.Name.Name + " " + prop.StringValue);
     }
 }
 

Requirements

Namespace: ITHit.WebDAV.Client.Exceptions

Assembly: ITHit.WebDAV.Client (in ITHit.WebDAV.Client.dll)

See Also

PropertyNotFoundException Members | ITHit.WebDAV.Client.Exceptions Namespace