Spread ASP.NET 6.0 Product Documentation
GetHashCode Method
See Also  Example Send Feedback
FarPoint.Web.Spread Assembly > FarPoint.Web.Spread Namespace > NamedStyle Class : GetHashCode Method


Glossary Item Box

Gets the hash code of this object.

Syntax

Visual Basic (Declaration) 
Public Overrides Function GetHashCode() As Integer
Visual Basic (Usage)Copy Code
Dim instance As NamedStyle
Dim value As Integer
 
value = instance.GetHashCode()
C# 
public override int GetHashCode()

Return Value

Integer hash code

Remarks

For more information about the GetHashCode method and hash codes, refer to Object.GetHashCode method in the Microsoft .NET Framework Reference.

Example

This example illustrates the use of this member by returning the hash code of the NamedStyle object.
C#Copy Code
FarPoint.Web.Spread.NamedStyle ns = new FarPoint.Web.Spread.NamedStyle();
FarPoint.Web.Spread.StyleInfo si = new FarPoint.Web.Spread.StyleInfo();
int i;
si.BackColor = Color.LightBlue;
ns.CopyFrom(si);
i = ns.GetHashCode();
listBox1.Items.Add(i.ToString());
fpSpread1.ActiveSheetView.DefaultStyle = ns;
Visual BasicCopy Code
Dim ns As New FarPoint.Web.Spread.NamedStyle()
Dim si As New FarPoint.Web.Spread.StyleInfo()
si.BackColor = Color.LightBlue
ns.CopyFrom(si)
FpSpread1.ActiveSheetView.DefaultStyle = ns
Dim b As Boolean
Dim doc As New System.Xml.XmlDocument()
Dim node As System.Xml.XmlNode
Dim r As System.Xml.XmlNodeReader
doc.Load("..\files\mystyle.xml")
node = doc.FirstChild
While Not (node.Name.Equals("Style"))
 node = node.NextSibling
End While
r = New System.Xml.XmlNodeReader(node)
r.Read()
b = ns.Deserialize(r)
ListBox1.Items.Add(b)

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2002-2012 GrapeCity, Inc. All Rights Reserved.