XmlLinkedNode.PreviousSibling プロパティ
アセンブリ: System.Xml (system.xml.dll 内)

直前の XmlNode。直前のノードが存在しない場合は null 参照 (Visual Basic では Nothing)。

Imports System Imports System.Xml Imports Microsoft.VisualBasic public class Sample public shared sub Main() Dim doc as XmlDocument = new XmlDocument() doc.Load("books.xml") Dim lastNode as XmlNode = doc.DocumentElement.LastChild Console.WriteLine("Last book...") Console.WriteLine(lastNode.OuterXml) Dim prevNode as XmlNode = lastNode.PreviousSibling Console.WriteLine(ControlChars.LF + "Previous book...") Console.WriteLine(prevNode.OuterXml) end sub end class
using System; using System.Xml; public class Sample { public static void Main() { XmlDocument doc = new XmlDocument(); doc.Load("books.xml"); XmlNode lastNode = doc.DocumentElement.LastChild; Console.WriteLine("Last book..."); Console.WriteLine(lastNode.OuterXml); XmlNode prevNode = lastNode.PreviousSibling; Console.WriteLine("\r\nPrevious book..."); Console.WriteLine(prevNode.OuterXml); } }
#using <System.Xml.dll> using namespace System; using namespace System::Xml; int main() { XmlDocument^ doc = gcnew XmlDocument; doc->Load( "books.xml" ); XmlNode^ lastNode = doc->DocumentElement->LastChild; Console::WriteLine( "Last book..." ); Console::WriteLine( lastNode->OuterXml ); XmlNode^ prevNode = lastNode->PreviousSibling; Console::WriteLine( "\r\nPrevious book..." ); Console::WriteLine( prevNode->OuterXml ); }
import System.*; import System.Xml.*; public class Sample { public static void main(String[] args) { XmlDocument doc = new XmlDocument(); doc.Load("books.xml"); XmlNode lastNode = doc.get_DocumentElement().get_LastChild(); Console.WriteLine("Last book..."); Console.WriteLine(lastNode.get_OuterXml()); XmlNode prevNode = lastNode.get_PreviousSibling(); Console.WriteLine("\r\nPrevious book..."); Console.WriteLine(prevNode.get_OuterXml()); } //main } //Sample

Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からXmlLinkedNode.PreviousSibling プロパティを検索する場合は、下記のリンクをクリックしてください。

- XmlLinkedNode.PreviousSibling プロパティのページへのリンク