Datalist - how (if) to use a sub variable or session variable in the footer?

  • Thread starter Thread starter KathyB
  • Start date Start date
K

KathyB

Hi, sorry to be greedy with all my posts lately, but can you tell I'm
doing new things this week?

I've just done my first datalist (a simple one), that give me one
column of records. I would like to put the total count of the rows
into the control's footer. I couldn't find any references for doing
this and ended up trying several things, one of which was assigning a
variable within the sub creating the datalist control, and when that
didn't work (referencing varCount), I tried setting a Session variable
(Boards)...the number is correct. However the following doesn't
produce the number, just the "boards" text...any ideas?

<%# Session("Boards") + " boards total" %>

Thanks again for ALL the help...it is TRULY appreciated by a new
user!!!

Kathy
 
on item created, test if it is an item you want to count,
add it to a variable in viewstate then, put it in the
footer.
 
Back
Top