running a funstion from template column of datagrid

G

Guest

Hi,
I have put a datagrid on a aspx page named "PriceCheck".
I have added an templatecolumn and put a label to hat column.
The code as the custom binding expression of this labels text property is as
follows:

ctype(Page,PriceCheck).isinstock(Container.dataitem("unitsinstock"))

But when i run the project i get an error like: "Type PriceCheck is not
defined"..

I have written this code accourding to a sample code from a book. What's
wrong with thi sode? Why isn't ctype working?
Thanx for your attention..
meral guven
turkey
 
K

Karl Seguin

Perhaps PriceCheck is in a different namespace than the user control? You
must therefore either @Import the namespace or use the full name, which
would likely be PROJECT_NAME.PriceCheck

Karl
 

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
474,436
Messages
2,571,696
Members
48,796
Latest member
Greg L.
Top