473,480 Members | 1,807 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

How to delete an XML element SOS URGENT

How can io delete this element in my AdRotator.xml file with VB.NET

I try a lot of things but I don'T have a good result.. Please help me

<Advertisements>

<Ad>

<ImageUrl>http://localhost/UQCN/Images/sample-ad.gif</ImageUrl>

<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx?AD=4</NavigateUrl>

<AlternateText>Test!</AlternateText>

<Keyword>Wrox</Keyword>

<Impressions>1</Impressions>

</Ad>

--------------------------------------------this is the element I want to
delete------------------------------------

<Ad>

<ImageUrl>http://localhost/UQCN/Images/sample-ad2.gif</ImageUrl>

<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx?AD=5</NavigateUrl>

<AlternateText>Test 2</AlternateText>

<Keyword>Wrox2</Keyword>

<Impressions>5</Impressions>

</Ad>

----------------------------------------------------------------------------
------------------------------------------------------

<Ad>

<ImageUrl>http://localhost/UQCN/Images/Aptitudes.jpg</ImageUrl>

<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx?AD=6</NavigateUrl>

<AlternateText>tytvytv</AlternateText>

<Keyword>1</Keyword>

<Impressions>1</Impressions>

</Ad>

</Advertisements>
Nov 12 '05 #1
1 3427
Call the XmlNode.RemoveChild function.

http://msdn.microsoft.com/library/default.asp?
url=/library/en-
us/cpref/html/frlrfsystemxmlxmlnodeclassremovechildtopic.as
p

Sonu
My Blog: http://weblogs.asp.net/sonukapoor/

-----Original Message-----
How can io delete this element in my AdRotator.xml file with VB.NET
I try a lot of things but I don'T have a good result.. Please help me
<Advertisements>

<Ad>

<ImageUrl>http://localhost/UQCN/Images/sample- ad.gif</ImageUrl>
<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx? AD=4</NavigateUrl>
<AlternateText>Test!</AlternateText>

<Keyword>Wrox</Keyword>

<Impressions>1</Impressions>

</Ad>

--------------------------------------------this is the element I want todelete------------------------------------

<Ad>

<ImageUrl>http://localhost/UQCN/Images/sample- ad2.gif</ImageUrl>
<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx? AD=5</NavigateUrl>
<AlternateText>Test 2</AlternateText>

<Keyword>Wrox2</Keyword>

<Impressions>5</Impressions>

</Ad>

---------------------------------------------------------- ------------------------------------------------------------------------

<Ad>

<ImageUrl>http://localhost/UQCN/Images/Aptitudes.jpg</Imag eUrl>
<NavigateUrl>/UQCN/WebModules/AdsManager/PassThrough.aspx? AD=6</NavigateUrl>
<AlternateText>tytvytv</AlternateText>

<Keyword>1</Keyword>

<Impressions>1</Impressions>

</Ad>

</Advertisements>
.

Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
2388
by: Timothy Madden | last post by:
Hello I have a linked list of object of a class. I thought it would be nice to have the destructor delete the whole list when I delete just the first element. I don't want to recursivly destroy...
1
2335
by: nasirmajor | last post by:
dear all, Please any urgent help regarding following code. i have the following code ================================================================= public void Delete(Object sender,...
6
6400
by: flash | last post by:
write a program that manipulates arrays of integers. The main program should call three functions: Insert, Delete, and Search. The Insert function should call a function Sort that sorts the array. ...
7
4319
by: JH Programmer | last post by:
Hi, is there any ways that allow us to delete an element in between? say int_val: 1 int_val: 2 int_val: 3
29
2215
by: =?Utf-8?B?R2Vvcmdl?= | last post by:
Hello everyone, I remembered delete is implemented through operator overloading, but I am not quite clear. Could anyone recommend some links about how delete is implemented so that I can...
11
4051
by: Ed Dror | last post by:
Hi there, I'm using ASP.NET 2.0 and SQL Server 2005 with VS 2005 Pro. I have a Price page (my website require login) with GridView with the following columns PriceID, Amount, Approved,...
2
5315
by: Michael | last post by:
It seems that a gridview allows us to delete only a single row at a time. How to extend this functionality to select multiple rows and delete all of the selected rows in a single stroke? just like...
3
4396
by: Lance Wynn | last post by:
Hello, I am receiving this error when trying to instantiate a webservice component. I have 2 development machines, both are XP sp2 with VS 2008 installed. On one machine, the code works fine. On...
5
2617
by: Fred Chateau | last post by:
I am currently using an Object element of type "application/x-mplayer2" to create a media player in ASP.NET 3.5, and was wondering if there is a better way to instantiate WMP in a browser. I'm...
0
7049
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6912
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
6744
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5348
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3000
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
2989
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1304
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
565
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
188
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.