Which event is triggered when the node is deleted from a diagram using delete button?
Is there any event that gets triggered when a node is deleted from diagram using delete button or any property of the node that gets updated ?
SIGN IN To post a reply.
10 Replies
AR
Aravind Ravi
Syncfusion Team
February 27, 2020 01:45 PM UTC
Hi Mounika,
Currently, In blazor we does not have support for the “CollectionChange” event. We will validate your requirement and update you with more details on March 2nd 2020.
Regards
Aravind Ravi
AR
Aravind Ravi
Syncfusion Team
March 3, 2020 03:56 AM UTC
Hi Mounika,
Sorry for the delay.
We are still checking with our team internally, we will update the further details at the earliest.
Regards
Aravind Ravi
SK
Suganthi Karuppannan
Syncfusion Team
March 4, 2020 12:06 PM UTC
Hi Mounika,
As of now, we don’t have support for the “collectionChange” event. Please confirm us whether your requirement is to get the information of the event after the node or connector added/removed in the diagram. If this is your requirement, we will consider this as feature.
Note: By using this event arguments we could not able to cancel the event, it will return only which node or connector is added/removed from the diagram.
Regards,
Suganthi K.
MO
Mounika
March 4, 2020 12:32 PM UTC
Hi Suganthi,
When I add/delete Node in the Nodecollection,if some event(collectionchanged) is triggered,then from the args i want to know which node is added/deleted and i have the update the properties of that node in this event and if possible i have to cancel the event.
MO
Mounika
March 4, 2020 12:38 PM UTC
Hi Aravind,
I also wanted to know if there is a possibility to have some constraints to stop these keyboard functionalities delete/cntrl + c/cntrl + v.
So I could use these constraints and customize the functionality on delete /add of nodes (In case if it is not possible to cancel the event)
SG
Shyam G
Syncfusion Team
March 5, 2020 04:07 PM UTC
Hi Mounika,
|
Query |
Response |
|
When I add/delete Node in the Nodecollection,if some event(collectionchanged) is triggered,then from the args i want to know which node is added/deleted and i have the update the properties of that node in this event and if possible i have to cancel the event. |
We have logged “CollectionChange event support in the blazor” as a feature. You can track the status of the feature from the below link.
Feedback link: https://www.syncfusion.com/feedback/12547/collectionchange-event-support-in-the-blazor
Note: As mentioned earlier, by using this event arguments we could not able to cancel the event, it will return only which node or connector is added/removed from the diagram. |
|
I also wanted to know if there is a possibility to have some constraints to stop these keyboard functionalities delete/cntrl + c/cntrl + v.
So I could use these constraints and customize the functionality on delete /add of nodes (In case if it is not possible to cancel the event)
|
We have command manager to disable the keyboard functionality. Please let us know whether you need a sample for it? |
Regards,
Shyam G
MO
Mounika
March 6, 2020 07:00 AM UTC
Hi Shyam,
Thank you.I need the sample code to disable the keyboard functionality that would help me.
SG
Shyam G
Syncfusion Team
March 9, 2020 11:08 AM UTC
Hi Mounika,
We can use CommandManager to disable/override the keyboard functionalities in our diagram control. We have created a sample in which we have overridden the copy(ctrl+c) and paste(ctrl+v) clipboard commands. Please refer to a code example and the sample below.
Code example:
|
<EjsDiagram Width="1000px" Height="700px" id="diagram" @ref="@diagram" Nodes="@NodeCollection" Connectors="@connectors">
@*Define events to handle command manager*@
<DiagramEvents OnCommandExecuted="@CommandExecute"></DiagramEvents>
@*Define command manager*@
<DiagramCommandManager Commands="@Commands">
</DiagramCommandManager>
</EjsDiagram>
//Define commands
List<DiagramCommand> Commands = new List<DiagramCommand>(){
//command Name should differ from the default value such as Copy, Paste
new DiagramCommand(){Name="copy1", Gesture= new DiagramKeyGesture(){ KeyModifiers = KeyModifiers.Control,Key= Keys.C} },
new DiagramCommand(){Name="paste2", Gesture= new DiagramKeyGesture(){ KeyModifiers = KeyModifiers.Control,Key= Keys.V} }
};
//Here you can override the clipboard command
public void CommandExecute(ICommandExecuteEventArgs args)
{
if (args.Gesture.KeyModifiers == KeyModifiers.Control && args.Gesture.Key == Keys.C)
{
// Do your own customization
}
if (args.Gesture.KeyModifiers == KeyModifiers.Control && args.Gesture.Key == Keys.V)
{
}
} |
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/CommandManagerSample-2032558523
Regards,
Shyam G
MO
Mounika
March 10, 2020 07:09 AM UTC
Thanks Shyam.
SG
Shyam G
Syncfusion Team
March 10, 2020 07:24 AM UTC
Hi Mounika,
Thanks for your update.
Regards,
Shyam G
SIGN IN To post a reply.
- 10 Replies
- 4 Participants
-
MO Mounika
- Feb 26, 2020 03:00 PM UTC
- Mar 10, 2020 07:24 AM UTC