- Home
- Forum
- Angular - EJ 2
- Unable to print diagram's SVG nodes (i.e. NodeModels with shape: NativeModel)
Unable to print diagram's SVG nodes (i.e. NodeModels with shape: NativeModel)
Hello Syncfusion Team,
I'm using Syncfusion's diagram control ("@syncfusion/ej2-angular-diagrams": "^17.2.47") in my Angular app.
I have a diagram with the following content on it.
- Connectors (ConnectorModel)
- Text (NodeModel with shape: TextModel, style: TextStyleModel)
- Basic Shapes (NodeModel with shape: BasicShapeModel, style: ShapeStyleModel)
- Native/SVG (NodeModel with shape: NativeModel)
When I print this diagram (using the DiagramComponent's print() method), only #1, #2 and #3 above get printed. The native/SVG content however does not get printed.
Is this a known issue? If so, any workarounds?
SIGN IN To post a reply.
5 Replies
SG
Shyam G
Syncfusion Team
October 10, 2019 03:55 AM UTC
Hi Mithun,
We don’t have built-in support to export HTML/Native node. We can export native or HTML node to image format using webkit rendering engine. We have created an angular sample in which we have created a HTML nodes and established a connection with connectors. Also, we have placed convertToImage button in angular sample. When you click on button, we send an base64 data from client side to server side.
In the server side, we convert base64data to image using webkit converter and sent base64data to client side and downloaded an image in client side. Please refer to an sample and video below.
Angular Client side sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/HTMLNodesample-1469179444
Server side sample: https://www.syncfusion.com/downloads/support/directtrac/general/7z/webkitsample-1385031527
Regards,
Shyam G
MI
Mithun
October 10, 2019 02:15 PM UTC
Thank you. Trying this out now.
SG
Shyam G
Syncfusion Team
October 11, 2019 04:02 AM UTC
Hi Mithun,
Thanks for your update. We will wait to hear from you.
Regards,
Shyam G
MI
Mithun
October 14, 2019 08:31 AM UTC
I was able to test out the attached angular + server-side samples and it works. I'll now start implementing these in my own project.
I saw that the server-side sample was compiled as a .NET Framework project. Do you happen to know if it can be converted as a .NET Core project (I'd prefer this since it can run on linux)?
SG
Shyam G
Syncfusion Team
October 15, 2019 12:29 PM UTC
Hi Mithun,
We have created a server side sample in .NET core and it is available in the below link for download.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/WebkitASPNetCore-238183061
Regards,
Shyam G
SIGN IN To post a reply.
- 5 Replies
- 2 Participants
-
MI Mithun
- Oct 9, 2019 11:05 AM UTC
- Oct 15, 2019 12:29 PM UTC