---
title: "Select i DropDownList"
type: "forum-thread"
url: "https://www.webforum.nu/amne/dotnet/20235-select-i-dropdownlist"
topic: ".NET"
topic_url: "https://www.webforum.nu/amne/dotnet"
author: "Vide"
published: "2001-06-12T18:40:00.000Z"
updated: "2001-06-13T06:26:00.000Z"
replies: 2
views: 371
page: 1
pages: 1
language: "sv-SE"
site: "webForum — webforum.nu"
rights: "Upphovsrätten till varje inlägg tillhör dess författare."
attribution: "Citera som: webForum, https://www.webforum.nu/amne/dotnet/20235-select-i-dropdownlist"
---

# Select i DropDownList

## #1 — Vide, 2001-06-12T18:40Z

Hejsan,

Hur bestämmer jag vilket item som skall vara selected i en DropDownList?

Jag laddar själva listan såhär, och vill i samma kod bestämma att index tre(3) skall vara selected...

```
		ArrayList AgeValues = new ArrayList();
		
		AgeValues.Add("-12");
		AgeValues.Add("13-18");
		AgeValues.Add("19-29");
		AgeValues.Add("30-45");
		AgeValues.Add("46-65");
		AgeValues.Add("65+");
		
		Age.DataSource = AgeValues;
		Age.DataBind();
```

Permalänk: https://www.webforum.nu/p/20235

## #2 — Grynet, 2001-06-13T06:23Z

Age.SelectedIndex = 3;

Permalänk: https://www.webforum.nu/p/348946

## #3 — Vide, 2001-06-13T06:26Z

Tackar så mycket... :)

Permalänk: https://www.webforum.nu/p/348947

---

Tråden på webben: https://www.webforum.nu/amne/dotnet/20235-select-i-dropdownlist
