Yeni Başlayan Arkadaşlarımıza Yardımcı Olucağını Duşünüyorum ...
Önemli Not: Form Ekranındakı Sildiğim Yerler Kendi Sitemde Paylaştığım İçin Burda Reklam Olmaması Amacıyla Ekranda Kapatma Gereği Duydum
Kod:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Collections;
namespace WindowsFormsApplication10
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
ArrayList ar = new ArrayList();
private **** button1_Click(object sender, EventArgs e)
{
try
{
ar.Add(textBox1.Text);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
private **** button2_Click(object sender, EventArgs e)
{
listBox1.Items.Clear();
foreach (string sayı in ar)
{
listBox1.Items.Add(sayı);
}
}
private **** button5_Click(object sender, EventArgs e)
{
try
{
label5.Text = ar.Capacity.ToString();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
private **** button4_Click(object sender, EventArgs e)
{
try
{
ar.RemoveAt(int.Parse(textBox4.Text));
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
private **** button6_Click(object sender, EventArgs e)
{
try
{
bool sonc = ar.Contains(textBox5.Text);
if (sonc == true)
{
MessageBox.Show("Sayı Bulundu: " + textBox5.Text);
}
else
{
MessageBox.Show(textBox5.Text+ " Sayısı Bulunamadı");
}
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
private **** button7_Click(object sender, EventArgs e)
{
ar.Reverse();
listBox1.Items.Clear();
foreach (var i in ar)
{
listBox1.Items.Add(i);
}
}
private **** linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
System.Diagnostics.Process.Start("www.turkhackteam.org");
}
}
}