What is wrong with this code line?

  • Thread starter Thread starter Shapper
  • Start date Start date
S

Shapper

Hello,

I have a BoundColumn in a datagrid. The DataField must be created using
the Session("culture") value. Shoudn't this work?

<asp:BoundColumn DataField='<% "title_" & Session("culture")
%>'></asp:BoundColumn>

What is wrong?

Thanks,
Miguel
 
BoundColumn is used to show data from data source. It should be

<asp:BoundColumn DataField="Data_Source_Field_Name"></asp:BoundColumn>

HTH

Elton Wang
 
Yes I know.

But the field name in my case changes with culture.

So, for example, when culture is en-GB I want to use the field
title_en-GB

Cheers,
Miguel
 
Back
Top