Questions tagged [dataitem]

53 questions
56
votes
12 answers

Using '<%# Eval("item") %>'; Handling Null Value and showing 0 against

If dataitem is Null I want to show 0 How can I accomplish this?
Muhammad Akhtar
  • 51,913
  • 37
  • 138
  • 191
9
votes
3 answers

ASP.NET / DataItem of DataList is null after Postback

After postback (click on a button) in my ASP.NET form, all the DataItem of my form are null. Why? What should I do to retrieve the content of the DataList even after postback? protected void buttonAddRecord_Click(object sender, EventArgs e) { …
user356178
7
votes
2 answers

ASP.Net - Getting data from RepeaterItem

I'm pretty new to ASP.Net and I'm not sure I'm going about this the right way. I have a Repeater which is bound to a list of "Image" objects. Within each RepeaterItem is a checkbox and I have a button OnClick event, which I want to display some…
Ant P
  • 24,820
  • 5
  • 68
  • 105
6
votes
1 answer

Databinding on Custom Control with ITemplate

this is a sample code of my custom server control : [Designer(typeof(ContainerControlDesigner))] [ToolboxData("<{0}:BlocArrondi runat=server>")] public class BlocArrondi : WebControl { …
Jni
  • 172
  • 2
  • 13
4
votes
1 answer

How to read the value from a TreeItem / DataItem using Windows Application Driver / C#?

I am having trouble accessing the text within a DataItem. Is there a way to get the text ["Repair Exceptions(0)" etc] for each node in the TreeItem using windows application driver? xml
Demodave
  • 6,242
  • 6
  • 43
  • 58
4
votes
1 answer

In DataList ItemdataBound event, how to access by column name instead of by ItemArray index

In the following code, strUsername is always returning as an empty string "" (and so are other columns). However if I use ItemArray and access it by passing the column index, it works fine. How to access by column name instead of index? protected…
Michael
  • 41
  • 1
  • 1
  • 3
4
votes
2 answers

ASP.Net repeater item.DataItem is null

Within a webpage, upon loading, I fill a dataset with two table with a relation between those tables and then load the data into a repeater with a nested repeater. This can also occur after the user clicks on a button. The data gets loaded from a…
mattgcon
  • 4,768
  • 19
  • 69
  • 117
4
votes
2 answers

DataItem on Repeater.Items is always null

I am setting the DataSource of my repeater to a List (MyProducts is a simple class, consisting of only get/setters). After this and DataBind(), I can see in debugging mode that DataItem of each Repeater.Items is null. When making a postback and…
Certs
  • 85
  • 1
  • 1
  • 9
4
votes
1 answer

asp.net Repeater - get Reference to current Item

I am using Asp.net 4.5, C#. I have a reapter that has some DataSource Bind to it: ... …
Programer
  • 1,005
  • 3
  • 22
  • 46
3
votes
3 answers

Accessing the data or dataItem used to bind a gridview

I have a gridview for which I programmatically set the datasource and databind it to a collection of objects. For each row that is created I then use different methods in the fields to extract the relevant information from the object like this…
Teletha
  • 603
  • 1
  • 11
  • 21
3
votes
2 answers

Get DataItem when updating GridView

How can I get the underlying DataItem from a GridView row that is in edit mode and the user clicks on "Update"? I have an editable GridView. I've added a CustomValidator to the Edit view of one of the columns. When the user clicks on Update I run…
dtc
  • 10,136
  • 16
  • 78
  • 104
3
votes
1 answer

Get DataItem in DataTemplate

Is there a way to get the actual DataItem of a DataTemplate. More specifically, I have a custom button which I use in a datatemplate: I use this in a listview to…
flamebaud
  • 978
  • 1
  • 9
  • 26
2
votes
1 answer

Android DataItem Not syncing with emulator wearable

I have been googling for 5 straight days and still can't find the solution to my problem so I desperately publish my question in the hope that somebody can help me. I've been trying to send a DataItem to an emulator wearable through the WearableAPI.…
2
votes
1 answer

OnDataChanged is never called

I am trying the dataitem APi and here is my code mGoogleApiClient = new GoogleApiClient.Builder(this) .addConnectionCallbacks(new GoogleApiClient.ConnectionCallbacks() { @Override public void…
UndoTheUndo
  • 43
  • 10
1
vote
3 answers

How to get the value of a textbox on RadGrid ItemCommand event handler when using a Custom Command?

I'm using RadGrid Form Templates as below;
The Light
  • 26,341
  • 62
  • 176
  • 258
1
2 3 4