Questions tagged [boundfield]

107 questions
0
votes
1 answer

set visible = false to a asp:BoundField

i have a gridview width a boundfield: i want set the visible parameter of this by a condition in page_load method. is possible? thanks
Luca Romagnoli
  • 12,145
  • 30
  • 95
  • 157
0
votes
1 answer

Modify Boundfield in Gridview depending on current date

I have a gridview and one of the bound fields contains a date (CureExpires), I am looking to have this date replaced with the word "Expired" if the date is older than the current date and time. How would I accomplish this? Example of how it would…
techora
  • 619
  • 3
  • 18
  • 38
0
votes
1 answer

Displaying Gridview values outside the grid on rowcommand event without using index of column

I have a grid in which all columns are boundfield and one template field, which is a link button. On clicking the link button, I need to display the grid column values in to a panel which has textboxes, checkbox etc. I am using a Row_Command event…
asn
  • 11
  • 1
  • 1
0
votes
2 answers

How to use a jquery inside a boundfield?

I'm using the below jQuery to add a "read more" option to a text so it only shows the first 200 characters and allows user to click on read more to view the remaining part of the text Add Read More Link (from DevCurry.com)
Fati
  • 57
  • 1
  • 7
0
votes
1 answer

Add 'onchange' Property To DetailsView Boundfield

I'm designing a page with forms for editing fields in a database. At first I was using FormView controls, but for various reasons I've changed them for DetailsView controls instead. These are so much quicker to code and the code is much tidier,…
Philip Stratford
  • 4,513
  • 4
  • 45
  • 71
0
votes
3 answers

gridview column boundfield error

Inside GridView, then inside columns I have a bound field This displays a list of columns of the companys name (which is fine) however the headerText, is a…
John
  • 3,965
  • 21
  • 77
  • 163
0
votes
2 answers

Value from Gridview is always empty

I have a gridview with boundfields inside the grid. I'm trying to get the values of the boundfields when OnRowUpdating is fired. But when I try to read the new values the result is always empty. This is the instruction I'm using : protected void…
Camilla
  • 949
  • 2
  • 14
  • 26
0
votes
3 answers

How to set readonly property in BoundFiled Cell in true?

I do it like this: if (e.Row.Cells[3].Text != null && e.Row.Cells[3].Text != " " && e.Row.Cells[3].Text != "") { e.Row.Cells[3].Attributes.Add("readonly", "true"); } But it doesn't work. I need to set readonly property in…
user1848942
  • 355
  • 1
  • 5
  • 21
0
votes
1 answer

ASP Gridview MaxLength

I have a gridview using , I would like to only show the first 20 characters in the Commemnt column when the gridview gets populated. Is there way to accomplish this in VB? Thank you.
g_shockTan
  • 325
  • 2
  • 8
  • 15
0
votes
1 answer

Can I replace an asp:GridView value with an image?

I have an asp:GridView which includes many BoundField's. One of the fields, called 'status' shows a value of either 1, 2 or 3 (which is got from a column in the database, obviously). Is there a way I can replace these numbers with images…
Patrick Keane
  • 663
  • 3
  • 19
  • 41
0
votes
1 answer

Does using Labels in TemplateField in Gridview cause performance issues?

Is there a significance performance issue with changing Gridview *BoundFields* into TemplateFields with Labels? (please see code excerpts below) I'm planning to implement the change above due to a lot of requirement changes with the gridview…
niki b
  • 989
  • 3
  • 10
  • 30
0
votes
1 answer

string.replace databound column in Gridview

Im currently pulling a string comment from a DB into a gridview to display to the user. Throughout the string i have placed
s where i want linebreaks, but am wondering how to replace the
s with "Environment.Newline"s. the column is simply…
AA11oAKas
  • 809
  • 1
  • 11
  • 23
0
votes
2 answers

format databound field according to the value- ASP

I have a data bound field say "Role" The values in the database for its corresponding field contains 1,2,3. I need to know whether i can format that databound field according to the value for eg: if 1 is the value, it should show "Admin". if 2 is…
Sin
  • 1,836
  • 2
  • 17
  • 24
0
votes
2 answers

Hidden field in detailsview - aspnet membership userID

I have a little detailsview where i can add some data to my DB. The detailsview's code:
amman
  • 142
  • 4
  • 12
0
votes
1 answer

Issue with stored procedure, field or property not found?

I'm trying to inner join asp_Users & asp_Membership tables so that i can retrieve the CreateDate field from asp_Membership in a BoundField of a GridView i have. I have tried the following which seems to make sense to me but it keeps throwing the…
Exalt
  • 53
  • 4