How to disable copying from GRID

Hello,

I’ve got a question about an OverviewGRID option at a form. Is the’re a possibility to disable copying from GRID?

I found the option to ControlAllowEdit, but I can still copy data from GRID to EXCEL.

Maybe it isn’t possible, maybe I forgot something?

Grtz

Geert

You can override the task method on the form to do this. But this will not allow you to copy any thing in that form.

some thing like this

#task;

if (_taskId == #taskCopy)
{
ret = 1;
}
else
{
ret = super(_taskId);
}

Kranthi,

Thank you for a quick respons. I only got one question about the task method. At the moment the method is:

public int task(int _taskId)
{
#Task

int ret = 0;

if (_taskId == #taskNew && this.dataSource().id() != smmBusRelTable_ds.id())
{
this.openRelatedForm(this.dataSource(), true);
}
else
{
ret = super(_taskId);
}

return ret;
}

Youre feedback says it should be something like this:

#task;

if(_takId == #taskCopy)

{

ret = 1’

}

Else

{

ret = super(_taskId);

}

When I changed the method it gave me the following error:

Variable _taskId isn’t registred. Do you know what’s wrong?

In your existing method, add the below code after the if condition and before else

else if(_taskId == #taskCopy)
{
ret = 1;
}