Nedir?
Tarihe ait her hangi bir alanı alır, örneğin, saat, gün gibi.
<Production>
<User Name="Deniz" SurName="Kocaboğa" LastLogin="2008-04-28T18:00:00Z">205</User>
<User Name="Ertan" SurName="Tike" LastLogin="2008-04-29T10:00:00Z">411</User>
</Production>
Örnek sentaks a göre ilk Value tarih değerinine ait Second(Saniye) değerini $(Result) değişkenine yazar.
SetVariable Name="$(Result)">
<DateTimePart Part="Second">
<Value Target="Date">::/Production/User[1]/@LastLogin</Value>
</DateTimePart>
</SetVariable>
Özellikler
Adı | Açıklama | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Part | Birim Bölümü bu bölümde bildirilir.
|
Örnekler
$(Result) sayı tipinde bir değerdir ve bu değer /Production/User[1]/@LastLogin yolunda bulunan tarih değerinin Minute(Dakika) bölümünü tutar.
SetVariable Name="$(Result)">
<DateTimePart Part="Minute">
<Value Target="Date">::/Production/User[1]/@LastLogin</Value>
</DateTimePart>
</SetVariable>
$(Result) sayı tipinde bir değerdir ve bu değer /Production/User[1]/@LastLogin yolunda bulunan tarih değerinin Hour(Saat) bölümünü tutar.
SetVariable Name="$(Result)">
<DateTimePart Part="Hour">
<Value Target="Date">::/Production/User[1]/@LastLogin</Value>
</DateTimePart>
</SetVariable>
$(Result) sayı tipinde bir değerdir ve bu değer /Production/User[1]/@LastLogin yolunda bulunan tarih değerinin Day(Gün) bölümünü tutar.
SetVariable Name="$(Result)">
<DateTimePart Part="Day">
<Value Target="Date">::/Production/User[1]/@LastLogin</Value>
</DateTimePart>
</SetVariable>
$(Result) sayı tipinde bir değerdir ve bu değer /Production/User[1]/@LastLogin yolunda bulunan tarih değerinin Month(Ay) bölümünü tutar.
SetVariable Name="$(Result)">
<DateTimePart Part="Month">
<Value Target="Date">::/Production/User[1]/@LastLogin</Value>
</DateTimePart>
</SetVariable>