More on variable URLs

M

MattB

Sorry to keep beating this to death, but I still can't get it to work and
have not been able to find an example of what I want to do.

I want to make a template/url column in a datagrid use a different template
depending on the contents of the data the grid is bound to.

In my codebehind (vb) I have a loop going through the dataset. It populates
two variables with the two kinds of templates I want to use. I think that
part works OK.

Now I'm just having trouble referring to those variables in my html, so I
think I'm close.

I have this the html where the in the datagrid section which is where I'm
trying to access variables I declare and populate in the codebehind. How
should I refer to these:

<%# DataBinder.Eval(Container, lcVar1, lcVar2) %>

I'm getting a "Variable is not declared" errors. I've tried a more
fully-qualified name, but that didn't work either. This seems a lot like a
newbie error, so I'm hoping for a nice simple (forehead slapping) thing.
TIA!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,023
Latest member
websitedesig25

Latest Threads

Top