473,386 Members | 1,835 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Footer Dropdwonlist Issue

I'm using a footer in my datagrid as an "add" row. I've read the current
postings and their links but am still having trouble adding the default of
"(select)" to the drropdownlist controls. I've tried:

mydddefectcodesF.Items.Insert(0, New ListItem("(please select)", ""))

mydddefectcodesF.Items.Insert(0, "Select One")
mydddefectcodesF.Items.FindByText("Select One").Value = 0
mydddefectcodesF.SelectedIndex = 0

in the Item created area, but no luck. I'm binding the dropdownlist via:

<FooterTemplate>
<asp:DropDownList id="dddefectcodesF" CssClass="gridtext" width="150"
DataSource="<%# BindDefectCodes() %>" DataTextField="DefectCode"
DataValueField="DefectCode_ID" runat="server" />
</FooterTemplate>

Public Function BindDefectCodes()

Dim objConn As SqlConnection = New SqlConnection(ConnectString)
Dim cmdDefectCodes As SqlCommand = New SqlCommand("SELECT DefectCode_ID,
DefectCode from view_DefectCodes", objConn)
cmdDefectCodes.CommandType = CommandType.Text
objConn.Open()
Return cmdDefectCodes.ExecuteReader(CommandBehavior.Close Connection)

End Function

thanx!

Nov 19 '05 #1
0 752

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

Similar topics

4
by: Jez | last post by:
I'm ashamed that I need to ask this question. I've been using PHP for almost a year now, and have used HTML extensively in the last few years. Often, when I create a new site, I use include() to...
1
by: Will Buntin | last post by:
I am trying to design my site without tables, using CSS for positioning and am having limited success. My main issue is I have a three column layout and my footer needs to run across the page,...
1
by: Frankie via AccessMonster.com | last post by:
Hello, I have the following issue: On a report footer based on a query, grouped by (Type being "in" and "out"), with totals by in group footer and report footer, I want to add a calculated...
3
by: ruca | last post by:
Can I add dinamicaly (in my code) a header and a footer for each time I want to print a web page from my web application? NOTE: The print command made for my is a click in a button that I have in...
9
by: tshad | last post by:
How do I find (and set) a couple of labels in the Footer after a DataGrid is filled? I have a bunch of DataGrids that get displayed nested inside a DataList. The datagrid looks like: ...
2
by: Nicholas | last post by:
Here is the issue: 1. I would like to create an ASP.Net/C# control to append a dynamic header and footer to **every** web page (depending on the page the content of each will vary). I can...
26
by: pamelafluente | last post by:
Hi , I have a DIV element in a page with a lot of other stuff (the page can scroll several times) absolutely positioned: <div id="MyDIV" <br<brFooter </div> Just after the page load, I...
3
by: Sven C. Koehler | last post by:
Hello, the html below displays a box (#container) with a #footer and an #image inside. Is there any way how I could get rid of declaring max-width and max-height for the #image? The #image...
11
by: Michael7 | last post by:
Hi everyone, Me again, been a while since I've been here, but I'm back again needing help with a simple thing. I've searched for help on creating a footer, but all the help I've found, was...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.