質問編集履歴
9
追記3
test
CHANGED
File without changes
|
test
CHANGED
@@ -256,7 +256,7 @@
|
|
256
256
|
|
257
257
|
$XmlSavePath = "保存先パス"
|
258
258
|
|
259
|
-
$TagName = "抜き出したいタグ名
|
259
|
+
$TagName = "'title','genre','price'" # 抜き出したいタグ名
|
260
260
|
|
261
261
|
|
262
262
|
|
8
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -246,6 +246,46 @@
|
|
246
246
|
|
247
247
|
|
248
248
|
|
249
|
+
【作成したプログラム】
|
250
|
+
|
251
|
+
```PowerShell
|
252
|
+
|
253
|
+
# 変数宣言
|
254
|
+
|
255
|
+
$XmlFilePath = "XMLファイル保存先パス"
|
256
|
+
|
257
|
+
$XmlSavePath = "保存先パス"
|
258
|
+
|
259
|
+
$TagName = "抜き出したいタグ名"
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
# XMLファイル読み込み
|
264
|
+
|
265
|
+
$xml = [xml](Get-Content $XmlFilePath)
|
266
|
+
|
267
|
+
|
268
|
+
|
269
|
+
# XMLタグ抜き出し
|
270
|
+
|
271
|
+
$CustomXML = $xml.catalog.book |
|
272
|
+
|
273
|
+
ForEach-Object {
|
274
|
+
|
275
|
+
$_[$TagName].OuterXml
|
276
|
+
|
277
|
+
}
|
278
|
+
|
279
|
+
|
280
|
+
|
281
|
+
# ファイル出力(文字コード:UTF8)
|
282
|
+
|
283
|
+
$CustomXML | Out-File $XmlSavePath -Encoding UTF8
|
284
|
+
|
285
|
+
```
|
286
|
+
|
287
|
+
|
288
|
+
|
249
289
|
【必要なタグのみ抽出したXMLファイル】抽出するタグ名 → title, genre, price
|
250
290
|
|
251
291
|
```XML
|
7
文源訂正
test
CHANGED
@@ -1 +1 @@
|
|
1
|
-
PowerShellで、XMLファイルにタグを追加し、項目毎で
|
1
|
+
PowerShellで、XMLファイルにタグを追加し、項目毎で囲いたい。
|
test
CHANGED
File without changes
|
6
初心者アイコン追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -480,7 +480,7 @@
|
|
480
480
|
|
481
481
|
③のコード記述が分からず困っております。
|
482
482
|
|
483
|
-
もし、分かる方がいれば、よろしくお願い致します。
|
483
|
+
もし、分かる方がいれば、よろしくお願い致します。。
|
484
484
|
|
485
485
|
|
486
486
|
|
5
詳細追加。
test
CHANGED
File without changes
|
test
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
---
|
4
4
|
|
5
|
-
①PowerShellを使用し、SharePoint Online上のリストを、「XMLファイル」でローカルに保存する。
|
5
|
+
①PowerShellを使用し、SharePoint Online上のリストを、「XMLファイル」でローカルに保存する。。
|
6
6
|
|
7
7
|
(*プログラム作成済)
|
8
8
|
|
4
実行環境追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -246,7 +246,7 @@
|
|
246
246
|
|
247
247
|
|
248
248
|
|
249
|
-
【必要なタグのみ抽出したXMLファイル】抽出するタグ名 → title,genre,price
|
249
|
+
【必要なタグのみ抽出したXMLファイル】抽出するタグ名 → title, genre, price
|
250
250
|
|
251
251
|
```XML
|
252
252
|
|
3
誤字を修正。
test
CHANGED
File without changes
|
test
CHANGED
@@ -246,7 +246,7 @@
|
|
246
246
|
|
247
247
|
|
248
248
|
|
249
|
-
【必要なタグのみ抽出したXMLファイル】抽出するタグ名→title,genre,price
|
249
|
+
【必要なタグのみ抽出したXMLファイル】抽出するタグ名 → title,genre,price
|
250
250
|
|
251
251
|
```XML
|
252
252
|
|
2
実行環境追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -242,7 +242,7 @@
|
|
242
242
|
|
243
243
|
②保存したXMLファイルの中には、不要な項目(タグ)があるので、PowerShellを使い必要なタグのみ抽出。(別名で保存)
|
244
244
|
|
245
|
-
(*プログラム作成済
|
245
|
+
(*プログラム作成済)
|
246
246
|
|
247
247
|
|
248
248
|
|
1
詳細追加。
test
CHANGED
File without changes
|
test
CHANGED
@@ -4,235 +4,323 @@
|
|
4
4
|
|
5
5
|
①PowerShellを使用し、SharePoint Online上のリストを、「XMLファイル」でローカルに保存する。
|
6
6
|
|
7
|
+
(*プログラム作成済)
|
8
|
+
|
9
|
+
|
10
|
+
|
11
|
+
【保存したXMLファイル】
|
12
|
+
|
13
|
+
```XML
|
14
|
+
|
15
|
+
<?xml version= "1.0"?>
|
16
|
+
|
17
|
+
<catalog>
|
18
|
+
|
19
|
+
|
20
|
+
|
21
|
+
<book id= "bk101">
|
22
|
+
|
23
|
+
<author>Gambardella, Matthew</author>
|
24
|
+
|
25
|
+
<title>XML Developer's Guide</title>
|
26
|
+
|
27
|
+
<genre>Computer</genre>
|
28
|
+
|
29
|
+
<price>44.95</price>
|
30
|
+
|
31
|
+
<publish_date>2000-10-01</publish_date>
|
32
|
+
|
33
|
+
<description>An in-depth look at creating applicationswith XML.</description>
|
34
|
+
|
35
|
+
</book>
|
36
|
+
|
37
|
+
|
38
|
+
|
39
|
+
<book id= "bk102">
|
40
|
+
|
41
|
+
<author>Ralls, Kim</author>
|
42
|
+
|
43
|
+
<title>Midnight Rain</title>
|
44
|
+
|
45
|
+
<genre>Fantasy</genre>
|
46
|
+
|
47
|
+
<price>5.95</price>
|
48
|
+
|
49
|
+
<publish_date>2000-12-16</publish_date>
|
50
|
+
|
51
|
+
<description>A former architect battles corporate zombies, an evil sorceress, and her own childhood to become queen of the world.</description>
|
52
|
+
|
53
|
+
</book>
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
<book id= "bk103">
|
58
|
+
|
59
|
+
<author>Corets, Eva</author>
|
60
|
+
|
61
|
+
<title>Maeve Ascendant</title>
|
62
|
+
|
63
|
+
<genre>Fantasy</genre>
|
64
|
+
|
65
|
+
<price>5.95</price>
|
66
|
+
|
67
|
+
<publish_date>2000-11-17</publish_date>
|
68
|
+
|
69
|
+
<description>After the collapse of a nanotechnology society in England, the young survivors lay the foundation for a new society.</description>
|
70
|
+
|
71
|
+
</book>
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
<book id= "bk104">
|
76
|
+
|
77
|
+
<author>Corets, Eva</author>
|
78
|
+
|
79
|
+
<title>Oberon's Legacy</title>
|
80
|
+
|
81
|
+
<genre>Fantasy</genre>
|
82
|
+
|
83
|
+
<price>5.95</price>
|
84
|
+
|
85
|
+
<publish_date>2001-03-10</publish_date>
|
86
|
+
|
87
|
+
<description>In post-apocalypse England, the mysterious agent known only as Oberon helps to create a new life for the inhabitants of London. Sequel to Maeve Ascendant.</description>
|
88
|
+
|
89
|
+
</book>
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
<book id= "bk105">
|
94
|
+
|
95
|
+
<author>Corets, Eva</author>
|
96
|
+
|
97
|
+
<title>The Sundered Grail</title>
|
98
|
+
|
99
|
+
<genre>Fantasy</genre>
|
100
|
+
|
101
|
+
<price>5.95</price>
|
102
|
+
|
103
|
+
<publish_date>2001-09-10</publish_date>
|
104
|
+
|
105
|
+
<description>The two daughters of Maeve, half-sisters, battle one another for control of England. Sequel to Oberon's Legacy.</description>
|
106
|
+
|
107
|
+
</book>
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
<book id= "bk106">
|
112
|
+
|
113
|
+
<author>Randall, Cynthia</author>
|
114
|
+
|
115
|
+
<title>Lover Birds</title>
|
116
|
+
|
117
|
+
<genre>Romance</genre>
|
118
|
+
|
119
|
+
<price>4.95</price>
|
120
|
+
|
121
|
+
<publish_date>2000-09-02</publish_date>
|
122
|
+
|
123
|
+
<description>When Carla meets Paul at an ornithology conference, tempers fly as feathers get ruffled.</description>
|
124
|
+
|
125
|
+
</book>
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
<book id= "bk107">
|
130
|
+
|
131
|
+
<author>Thurman, Paula</author>
|
132
|
+
|
133
|
+
<title>Splish Splash</title>
|
134
|
+
|
135
|
+
<genre>Romance</genre>
|
136
|
+
|
137
|
+
<price>4.95</price>
|
138
|
+
|
139
|
+
<publish_date>2000-11-02</publish_date>
|
140
|
+
|
141
|
+
<description>A deep sea diver finds true love twenty thousand leagues beneath the sea.</description>
|
142
|
+
|
143
|
+
</book>
|
144
|
+
|
145
|
+
|
146
|
+
|
147
|
+
<book id= "bk108">
|
148
|
+
|
149
|
+
<author>Knorr, Stefan</author>
|
150
|
+
|
151
|
+
<title>Creepy Crawlies</title>
|
152
|
+
|
153
|
+
<genre>Horror</genre>
|
154
|
+
|
155
|
+
<price>4.95</price>
|
156
|
+
|
157
|
+
<publish_date>2000-12-06</publish_date>
|
158
|
+
|
159
|
+
<description>An anthology of horror stories about roaches, centipedes, scorpions and other insects.</description>
|
160
|
+
|
161
|
+
</book>
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
<book id= "bk109">
|
166
|
+
|
167
|
+
<author>Kress, Peter</author>
|
168
|
+
|
169
|
+
<title>Paradox Lost</title>
|
170
|
+
|
171
|
+
<genre>Science Fiction</genre>
|
172
|
+
|
173
|
+
<price>6.95</price>
|
174
|
+
|
175
|
+
<publish_date>2000-11-02</publish_date>
|
176
|
+
|
177
|
+
<description>After an inadvertant trip through a Heisenberg Uncertainty Device, James Salway discovers the problems of being quantum.</description>
|
178
|
+
|
179
|
+
</book>
|
180
|
+
|
181
|
+
|
182
|
+
|
183
|
+
<book id= "bk110">
|
184
|
+
|
185
|
+
<author>O'Brien, Tim</author>
|
186
|
+
|
187
|
+
<title>Microsoft .NET: The Programming Bible</title>
|
188
|
+
|
189
|
+
<genre>Computer</genre>
|
190
|
+
|
191
|
+
<price>36.95</price>
|
192
|
+
|
193
|
+
<publish_date>2000-12-09</publish_date>
|
194
|
+
|
195
|
+
<description>Microsoft's .NET initiative is explored in detail in this deep programmer's reference.</description>
|
196
|
+
|
197
|
+
</book>
|
198
|
+
|
199
|
+
|
200
|
+
|
201
|
+
<book id= "bk111">
|
202
|
+
|
203
|
+
<author>O'Brien, Tim</author>
|
204
|
+
|
205
|
+
<title>MSXML3: A Comprehensive Guide</title>
|
206
|
+
|
207
|
+
<genre>Computer</genre>
|
208
|
+
|
209
|
+
<price>36.95</price>
|
210
|
+
|
211
|
+
<publish_date>2000-12-01</publish_date>
|
212
|
+
|
213
|
+
<description>The Microsoft MSXML3 parser is covered in detail, with attention to XML DOM interfaces, XSLT processing, SAX and more.</description>
|
214
|
+
|
215
|
+
</book>
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
<book id= "bk112">
|
220
|
+
|
221
|
+
<author>Galos, Mike</author>
|
222
|
+
|
223
|
+
<title>Visual Studio 7: A Comprehensive Guide</title>
|
224
|
+
|
225
|
+
<genre>Computer</genre>
|
226
|
+
|
227
|
+
<price>49.95</price>
|
228
|
+
|
229
|
+
<publish_date>2001-04-16</publish_date>
|
230
|
+
|
231
|
+
<description>Microsoft Visual Studio 7 is explored in depth, looking at how Visual Basic, Visual C++, C#, and ASP+ are integrated into a comprehensive development environment.</description>
|
232
|
+
|
233
|
+
</book>
|
234
|
+
|
235
|
+
</catalog>
|
236
|
+
|
237
|
+
```
|
238
|
+
|
239
|
+
|
240
|
+
|
241
|
+
↓
|
242
|
+
|
243
|
+
②保存したXMLファイルの中には、不要な項目(タグ)があるので、PowerShellを使い必要なタグのみ抽出。(別名で保存)
|
244
|
+
|
7
245
|
(*プログラム作成済。)
|
8
246
|
|
9
247
|
|
10
248
|
|
11
|
-
【
|
249
|
+
【必要なタグのみ抽出したXMLファイル】抽出するタグ名→title,genre,price
|
12
250
|
|
13
251
|
```XML
|
14
252
|
|
15
|
-
<
|
16
|
-
|
17
|
-
<
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
<description>In post-apocalypse England, the mysterious agent known only as Oberon helps to create a new life for the inhabitants of London. Sequel to Maeve Ascendant.</description>
|
88
|
-
|
89
|
-
</book>
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
<book id= "bk105">
|
94
|
-
|
95
|
-
<author>Corets, Eva</author>
|
96
|
-
|
97
|
-
<title>The Sundered Grail</title>
|
98
|
-
|
99
|
-
<genre>Fantasy</genre>
|
100
|
-
|
101
|
-
<price>5.95</price>
|
102
|
-
|
103
|
-
<publish_date>2001-09-10</publish_date>
|
104
|
-
|
105
|
-
<description>The two daughters of Maeve, half-sisters, battle one another for control of England. Sequel to Oberon's Legacy.</description>
|
106
|
-
|
107
|
-
</book>
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
<book id= "bk106">
|
112
|
-
|
113
|
-
<author>Randall, Cynthia</author>
|
114
|
-
|
115
|
-
<title>Lover Birds</title>
|
116
|
-
|
117
|
-
<genre>Romance</genre>
|
118
|
-
|
119
|
-
<price>4.95</price>
|
120
|
-
|
121
|
-
<publish_date>2000-09-02</publish_date>
|
122
|
-
|
123
|
-
<description>When Carla meets Paul at an ornithology conference, tempers fly as feathers get ruffled.</description>
|
124
|
-
|
125
|
-
</book>
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
<book id= "bk107">
|
130
|
-
|
131
|
-
<author>Thurman, Paula</author>
|
132
|
-
|
133
|
-
<title>Splish Splash</title>
|
134
|
-
|
135
|
-
<genre>Romance</genre>
|
136
|
-
|
137
|
-
<price>4.95</price>
|
138
|
-
|
139
|
-
<publish_date>2000-11-02</publish_date>
|
140
|
-
|
141
|
-
<description>A deep sea diver finds true love twenty thousand leagues beneath the sea.</description>
|
142
|
-
|
143
|
-
</book>
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
<book id= "bk108">
|
148
|
-
|
149
|
-
<author>Knorr, Stefan</author>
|
150
|
-
|
151
|
-
<title>Creepy Crawlies</title>
|
152
|
-
|
153
|
-
<genre>Horror</genre>
|
154
|
-
|
155
|
-
<price>4.95</price>
|
156
|
-
|
157
|
-
<publish_date>2000-12-06</publish_date>
|
158
|
-
|
159
|
-
<description>An anthology of horror stories about roaches, centipedes, scorpions and other insects.</description>
|
160
|
-
|
161
|
-
</book>
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
<book id= "bk109">
|
166
|
-
|
167
|
-
<author>Kress, Peter</author>
|
168
|
-
|
169
|
-
<title>Paradox Lost</title>
|
170
|
-
|
171
|
-
<genre>Science Fiction</genre>
|
172
|
-
|
173
|
-
<price>6.95</price>
|
174
|
-
|
175
|
-
<publish_date>2000-11-02</publish_date>
|
176
|
-
|
177
|
-
<description>After an inadvertant trip through a Heisenberg Uncertainty Device, James Salway discovers the problems of being quantum.</description>
|
178
|
-
|
179
|
-
</book>
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
<book id= "bk110">
|
184
|
-
|
185
|
-
<author>O'Brien, Tim</author>
|
186
|
-
|
187
|
-
<title>Microsoft .NET: The Programming Bible</title>
|
188
|
-
|
189
|
-
<genre>Computer</genre>
|
190
|
-
|
191
|
-
<price>36.95</price>
|
192
|
-
|
193
|
-
<publish_date>2000-12-09</publish_date>
|
194
|
-
|
195
|
-
<description>Microsoft's .NET initiative is explored in detail in this deep programmer's reference.</description>
|
196
|
-
|
197
|
-
</book>
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
<book id= "bk111">
|
202
|
-
|
203
|
-
<author>O'Brien, Tim</author>
|
204
|
-
|
205
|
-
<title>MSXML3: A Comprehensive Guide</title>
|
206
|
-
|
207
|
-
<genre>Computer</genre>
|
208
|
-
|
209
|
-
<price>36.95</price>
|
210
|
-
|
211
|
-
<publish_date>2000-12-01</publish_date>
|
212
|
-
|
213
|
-
<description>The Microsoft MSXML3 parser is covered in detail, with attention to XML DOM interfaces, XSLT processing, SAX and more.</description>
|
214
|
-
|
215
|
-
</book>
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
<book id= "bk112">
|
220
|
-
|
221
|
-
<author>Galos, Mike</author>
|
222
|
-
|
223
|
-
<title>Visual Studio 7: A Comprehensive Guide</title>
|
224
|
-
|
225
|
-
<genre>Computer</genre>
|
226
|
-
|
227
|
-
<price>49.95</price>
|
228
|
-
|
229
|
-
<publish_date>2001-04-16</publish_date>
|
230
|
-
|
231
|
-
<description>Microsoft Visual Studio 7 is explored in depth, looking at how Visual Basic, Visual C++, C#, and ASP+ are integrated into a comprehensive development environment.</description>
|
232
|
-
|
233
|
-
</book>
|
234
|
-
|
235
|
-
</catalog>
|
253
|
+
<title>XML Developer's Guide</title>
|
254
|
+
|
255
|
+
<genre>Computer</genre>
|
256
|
+
|
257
|
+
<price>44.95</price>
|
258
|
+
|
259
|
+
<title>Midnight Rain</title>
|
260
|
+
|
261
|
+
<genre>Fantasy</genre>
|
262
|
+
|
263
|
+
<price>5.95</price>
|
264
|
+
|
265
|
+
<title>Maeve Ascendant</title>
|
266
|
+
|
267
|
+
<genre>Fantasy</genre>
|
268
|
+
|
269
|
+
<price>5.95</price>
|
270
|
+
|
271
|
+
<title>Oberon's Legacy</title>
|
272
|
+
|
273
|
+
<genre>Fantasy</genre>
|
274
|
+
|
275
|
+
<price>5.95</price>
|
276
|
+
|
277
|
+
<title>The Sundered Grail</title>
|
278
|
+
|
279
|
+
<genre>Fantasy</genre>
|
280
|
+
|
281
|
+
<price>5.95</price>
|
282
|
+
|
283
|
+
<title>Lover Birds</title>
|
284
|
+
|
285
|
+
<genre>Romance</genre>
|
286
|
+
|
287
|
+
<price>4.95</price>
|
288
|
+
|
289
|
+
<title>Splish Splash</title>
|
290
|
+
|
291
|
+
<genre>Romance</genre>
|
292
|
+
|
293
|
+
<price>4.95</price>
|
294
|
+
|
295
|
+
<title>Creepy Crawlies</title>
|
296
|
+
|
297
|
+
<genre>Horror</genre>
|
298
|
+
|
299
|
+
<price>4.95</price>
|
300
|
+
|
301
|
+
<title>Paradox Lost</title>
|
302
|
+
|
303
|
+
<genre>Science Fiction</genre>
|
304
|
+
|
305
|
+
<price>6.95</price>
|
306
|
+
|
307
|
+
<title>Microsoft .NET: The Programming Bible</title>
|
308
|
+
|
309
|
+
<genre>Computer</genre>
|
310
|
+
|
311
|
+
<price>36.95</price>
|
312
|
+
|
313
|
+
<title>MSXML3: A Comprehensive Guide</title>
|
314
|
+
|
315
|
+
<genre>Computer</genre>
|
316
|
+
|
317
|
+
<price>36.95</price>
|
318
|
+
|
319
|
+
<title>Visual Studio 7: A Comprehensive Guide</title>
|
320
|
+
|
321
|
+
<genre>Computer</genre>
|
322
|
+
|
323
|
+
<price>49.95</price>
|
236
324
|
|
237
325
|
```
|
238
326
|
|
@@ -240,232 +328,144 @@
|
|
240
328
|
|
241
329
|
↓
|
242
330
|
|
243
|
-
|
331
|
+
③必要なタグのみ抽出したXMLファイルを開くと、必要な項目(タグ)のみ抽出されてはいるが、見づらいので
|
332
|
+
|
244
|
-
|
333
|
+
1アイテム毎にタグでくくり、見やすくしたい。
|
334
|
+
|
245
|
-
(*プログラム作成
|
335
|
+
**(*プログラム作成中。不明点)**
|
246
|
-
|
247
|
-
|
248
|
-
|
336
|
+
|
337
|
+
|
338
|
+
|
249
|
-
【
|
339
|
+
【この様なXMLファイルにしたい】
|
250
340
|
|
251
341
|
```XML
|
252
342
|
|
253
|
-
|
254
|
-
|
255
|
-
<
|
256
|
-
|
257
|
-
<pri
|
258
|
-
|
259
|
-
<
|
260
|
-
|
261
|
-
<
|
262
|
-
|
263
|
-
<
|
264
|
-
|
265
|
-
<
|
266
|
-
|
267
|
-
<
|
268
|
-
|
269
|
-
<
|
270
|
-
|
271
|
-
<
|
272
|
-
|
273
|
-
<
|
274
|
-
|
275
|
-
<
|
276
|
-
|
277
|
-
<title>
|
278
|
-
|
279
|
-
<genre>Fantasy</genre>
|
280
|
-
|
281
|
-
<price>5.95</price>
|
282
|
-
|
283
|
-
<
|
284
|
-
|
285
|
-
<
|
286
|
-
|
287
|
-
<
|
288
|
-
|
289
|
-
<
|
290
|
-
|
291
|
-
<
|
292
|
-
|
293
|
-
<
|
294
|
-
|
295
|
-
<t
|
296
|
-
|
297
|
-
<
|
298
|
-
|
299
|
-
<
|
300
|
-
|
301
|
-
<
|
302
|
-
|
303
|
-
<
|
304
|
-
|
305
|
-
<
|
306
|
-
|
307
|
-
<title>
|
308
|
-
|
309
|
-
<genre>
|
310
|
-
|
311
|
-
<price>
|
312
|
-
|
313
|
-
<
|
314
|
-
|
315
|
-
<
|
316
|
-
|
317
|
-
<
|
318
|
-
|
319
|
-
<
|
320
|
-
|
321
|
-
<
|
322
|
-
|
323
|
-
<
|
343
|
+
|
344
|
+
|
345
|
+
<data>
|
346
|
+
|
347
|
+
<title>XML Developer's Guide</title>
|
348
|
+
|
349
|
+
<genre>Computer</genre>
|
350
|
+
|
351
|
+
<price>44.95</price>
|
352
|
+
|
353
|
+
</data>
|
354
|
+
|
355
|
+
<data>
|
356
|
+
|
357
|
+
<title>Midnight Rain</title>
|
358
|
+
|
359
|
+
<genre>Fantasy</genre>
|
360
|
+
|
361
|
+
<price>5.95</price>
|
362
|
+
|
363
|
+
</data>
|
364
|
+
|
365
|
+
<data>
|
366
|
+
|
367
|
+
<title>Maeve Ascendant</title>
|
368
|
+
|
369
|
+
<genre>Fantasy</genre>
|
370
|
+
|
371
|
+
<price>5.95</price>
|
372
|
+
|
373
|
+
</data>
|
374
|
+
|
375
|
+
<data>
|
376
|
+
|
377
|
+
<title>Oberon's Legacy</title>
|
378
|
+
|
379
|
+
<genre>Fantasy</genre>
|
380
|
+
|
381
|
+
<price>5.95</price>
|
382
|
+
|
383
|
+
</data>
|
384
|
+
|
385
|
+
<data>
|
386
|
+
|
387
|
+
<title>The Sundered Grail</title>
|
388
|
+
|
389
|
+
<genre>Fantasy</genre>
|
390
|
+
|
391
|
+
<price>5.95</price>
|
392
|
+
|
393
|
+
</data>
|
394
|
+
|
395
|
+
<data>
|
396
|
+
|
397
|
+
<title>Lover Birds</title>
|
398
|
+
|
399
|
+
<genre>Romance</genre>
|
400
|
+
|
401
|
+
<price>4.95</price>
|
402
|
+
|
403
|
+
</data>
|
404
|
+
|
405
|
+
<data>
|
406
|
+
|
407
|
+
<title>Splish Splash</title>
|
408
|
+
|
409
|
+
<genre>Romance</genre>
|
410
|
+
|
411
|
+
<price>4.95</price>
|
412
|
+
|
413
|
+
</data>
|
414
|
+
|
415
|
+
<data>
|
416
|
+
|
417
|
+
<title>Creepy Crawlies</title>
|
418
|
+
|
419
|
+
<genre>Horror</genre>
|
420
|
+
|
421
|
+
<price>4.95</price>
|
422
|
+
|
423
|
+
</data>
|
424
|
+
|
425
|
+
<data>
|
426
|
+
|
427
|
+
<title>Paradox Lost</title>
|
428
|
+
|
429
|
+
<genre>Science Fiction</genre>
|
430
|
+
|
431
|
+
<price>6.95</price>
|
432
|
+
|
433
|
+
</data>
|
434
|
+
|
435
|
+
<data>
|
436
|
+
|
437
|
+
<title>Microsoft .NET: The Programming Bible</title>
|
438
|
+
|
439
|
+
<genre>Computer</genre>
|
440
|
+
|
441
|
+
<price>36.95</price>
|
442
|
+
|
443
|
+
</data>
|
444
|
+
|
445
|
+
<data>
|
446
|
+
|
447
|
+
<title>MSXML3: A Comprehensive Guide</title>
|
448
|
+
|
449
|
+
<genre>Computer</genre>
|
450
|
+
|
451
|
+
<price>36.95</price>
|
452
|
+
|
453
|
+
</data>
|
454
|
+
|
455
|
+
<data>
|
456
|
+
|
457
|
+
<title>Visual Studio 7: A Comprehensive Guide</title>
|
458
|
+
|
459
|
+
<genre>Computer</genre>
|
460
|
+
|
461
|
+
<price>49.95</price>
|
462
|
+
|
463
|
+
</data>
|
324
464
|
|
325
465
|
```
|
326
466
|
|
327
467
|
|
328
468
|
|
329
|
-
↓
|
330
|
-
|
331
|
-
③必要なタグのみ抽出したXMLファイルを開くと、必要な項目(タグ)のみ抽出されてはいるが、見づらいので
|
332
|
-
|
333
|
-
1アイテム毎にタグでくくり、見やすくしたい。
|
334
|
-
|
335
|
-
**(*プログラム作成中。不明点)**
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
【この様なXMLファイルにしたい】
|
340
|
-
|
341
|
-
```XML
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
<data>
|
346
|
-
|
347
|
-
<title>XML Developer's Guide</title>
|
348
|
-
|
349
|
-
<genre>Computer</genre>
|
350
|
-
|
351
|
-
<price>44.95</price>
|
352
|
-
|
353
|
-
</data>
|
354
|
-
|
355
|
-
<data>
|
356
|
-
|
357
|
-
<title>Midnight Rain</title>
|
358
|
-
|
359
|
-
<genre>Fantasy</genre>
|
360
|
-
|
361
|
-
<price>5.95</price>
|
362
|
-
|
363
|
-
</data>
|
364
|
-
|
365
|
-
<data>
|
366
|
-
|
367
|
-
<title>Maeve Ascendant</title>
|
368
|
-
|
369
|
-
<genre>Fantasy</genre>
|
370
|
-
|
371
|
-
<price>5.95</price>
|
372
|
-
|
373
|
-
</data>
|
374
|
-
|
375
|
-
<data>
|
376
|
-
|
377
|
-
<title>Oberon's Legacy</title>
|
378
|
-
|
379
|
-
<genre>Fantasy</genre>
|
380
|
-
|
381
|
-
<price>5.95</price>
|
382
|
-
|
383
|
-
</data>
|
384
|
-
|
385
|
-
<data>
|
386
|
-
|
387
|
-
<title>The Sundered Grail</title>
|
388
|
-
|
389
|
-
<genre>Fantasy</genre>
|
390
|
-
|
391
|
-
<price>5.95</price>
|
392
|
-
|
393
|
-
</data>
|
394
|
-
|
395
|
-
<data>
|
396
|
-
|
397
|
-
<title>Lover Birds</title>
|
398
|
-
|
399
|
-
<genre>Romance</genre>
|
400
|
-
|
401
|
-
<price>4.95</price>
|
402
|
-
|
403
|
-
</data>
|
404
|
-
|
405
|
-
<data>
|
406
|
-
|
407
|
-
<title>Splish Splash</title>
|
408
|
-
|
409
|
-
<genre>Romance</genre>
|
410
|
-
|
411
|
-
<price>4.95</price>
|
412
|
-
|
413
|
-
</data>
|
414
|
-
|
415
|
-
<data>
|
416
|
-
|
417
|
-
<title>Creepy Crawlies</title>
|
418
|
-
|
419
|
-
<genre>Horror</genre>
|
420
|
-
|
421
|
-
<price>4.95</price>
|
422
|
-
|
423
|
-
</data>
|
424
|
-
|
425
|
-
<data>
|
426
|
-
|
427
|
-
<title>Paradox Lost</title>
|
428
|
-
|
429
|
-
<genre>Science Fiction</genre>
|
430
|
-
|
431
|
-
<price>6.95</price>
|
432
|
-
|
433
|
-
</data>
|
434
|
-
|
435
|
-
<data>
|
436
|
-
|
437
|
-
<title>Microsoft .NET: The Programming Bible</title>
|
438
|
-
|
439
|
-
<genre>Computer</genre>
|
440
|
-
|
441
|
-
<price>36.95</price>
|
442
|
-
|
443
|
-
</data>
|
444
|
-
|
445
|
-
<data>
|
446
|
-
|
447
|
-
<title>MSXML3: A Comprehensive Guide</title>
|
448
|
-
|
449
|
-
<genre>Computer</genre>
|
450
|
-
|
451
|
-
<price>36.95</price>
|
452
|
-
|
453
|
-
</data>
|
454
|
-
|
455
|
-
<data>
|
456
|
-
|
457
|
-
<title>Visual Studio 7: A Comprehensive Guide</title>
|
458
|
-
|
459
|
-
<genre>Computer</genre>
|
460
|
-
|
461
|
-
<price>49.95</price>
|
462
|
-
|
463
|
-
</data>
|
464
|
-
|
465
|
-
```
|
466
|
-
|
467
|
-
|
468
|
-
|
469
469
|
|
470
470
|
|
471
471
|
|