C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Remove single item from an Array


Posted Date: 12 Oct 2008      Total Responses: 2

Posted By: balaji T       Member Level: Silver     Points: 1


Hi all,,
i want to remove the single item from an array,How to do it...

for example,

ar[0] = 1;
ar[1] = 2;
ar[2] = 3;
ar[3] = 4;
ar[4] = 5;
ar[5] = 6;

here ,i want to delete the element 3,which is ar[2] = 3. how can i do it ?




Responses

Author: Dharmaraj    12 Oct 2008Member Level: DiamondRating:     Points: 3
Hi,
For removing an element from a specified location, you can use the RemoveAt(indexvalue). When you give the index. The values in the position will get removed automatically.
Regards,
Dharma



Author: Bindu Bujji    12 Oct 2008Member Level: GoldRating:     Points: 2
You have to use RemoveAt(index). Here index is the index value of the array which starts with zero.

Bindu


Post Reply
You must Sign In to post a response.
Next : Text Editor for text box
Previous : Sys is undefined
Return to Discussion Forum
Post New Message
Category: ASP.NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

audio conferencing services

Contact Us    Privacy Policy    Terms Of Use