Condition Edit Action

J

jakelake

Hi - I am trying to use the EditCommand Column in a datagrid in such a
way as to display the column's edit command ONLY when the user who
entered the row is the one viewing the datagrid. I created a function
to check for this event. I just can't figure out what the conditional
logic for this is and I'm not sure where I'd be wiring at. (ItemBOund?)

Thanks for any help in advance!!

jake
 
J

jakelake

Elton -

Thanks for the where part. Have any idea about the how? (i.e logic
side)

Thanks,

jake
 
E

Elton Wang

Hi Jake,

The logic is like following:

if itemType = Header/Pager/Footer/Separator then
return
else
editBtn = e.item.cell[btnColIndex].control[0] // and
cast to button object
data = e.item.cell[dataColIndex].text
// or more data
if function(data) = true then
editBtn.visible = true
else
editBtn.visible = false
fi
fi

HTH

Elton Wang
(e-mail address removed)
 

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,768
Messages
2,569,574
Members
45,048
Latest member
verona

Latest Threads

Top