Jump to content
Software FX Community

Hiding the Data Editor command


User (Legacy)

Recommended Posts

Posted

I'd like to give the client most toolbar functionality, but I don't want

them to have access to the data editor.

I've tried

this.chart.Commands[(int)SoftwareFX.ChartFX.CommandID.DataEditor].Enabled =

false;

But it still shows up enabled in the toolbar and context menu.

Posted

Pre-defined commands can not be "Disabled" as they are enabled/disabled

based on other properties.

You can disable data editing by doing:

chart.Style &= ~ChartStyle.Editable;

This will, however, not hide the Data Editor command, it will just make the

Data Editor Read-Only

To get rid of this command (if this is what you want) you need to remove it

from both the toolbar and the right-click menu as follows:

chart1.Commands[(int)CommandID.ContextMenuBack].RemoveSubCommand(1);

chart1.ToolBarObj.RemoveAt(18);

--

FP

Software FX, Inc.

Posted

"SoftwareFX Support" <support@softwarefx.com> wrote in message

news:zT607gtrDHA.1560@WEBSERVER1...

> Pre-defined commands can not be "Disabled" as they are enabled/disabled

> based on other properties.

>

> You can disable data editing by doing:

>

> chart.Style &= ~ChartStyle.Editable;

>

> This will, however, not hide the Data Editor command, it will just make

the

> Data Editor Read-Only

>

> To get rid of this command (if this is what you want) you need to remove

it

> from both the toolbar and the right-click menu as follows:

>

> chart1.Commands[(int)CommandID.ContextMenuBack].RemoveSubCommand(1);

>

> chart1.ToolBarObj.RemoveAt(18);

>

>

> --

> FP

> Software FX, Inc.

>

>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...