VectorDraw.Drawing.WebScript
12.0.1
dotnet add package VectorDraw.Drawing.WebScript --version 12.0.1
NuGet\Install-Package VectorDraw.Drawing.WebScript -Version 12.0.1
<PackageReference Include="VectorDraw.Drawing.WebScript" Version="12.0.1" />
<PackageVersion Include="VectorDraw.Drawing.WebScript" Version="12.0.1" />
<PackageReference Include="VectorDraw.Drawing.WebScript" />
paket add VectorDraw.Drawing.WebScript --version 12.0.1
#r "nuget: VectorDraw.Drawing.WebScript, 12.0.1"
#:package VectorDraw.Drawing.WebScript@12.0.1
#addin nuget:?package=VectorDraw.Drawing.WebScript&version=12.0.1
#tool nuget:?package=VectorDraw.Drawing.WebScript&version=12.0.1
Web Control
A vector 3D graphics library that is designed to not only open CAD drawings but also display generic vector objects on any platform that supports the HTML 5 standard, such as Windows, Android, IOS and Linux.
About
VectorDraw web library can be executed in every major web browser (Chrome, Firefox, Safari, Opera, Dolphin, Boat and more) that support the use of canvas and Javascript, without any installation. This means that you can show your work from many formats like DXF, DWG, DGN, SKP (Google's Sketchup), IFC ,OBJ , PLY VDML and more, on almost every Computer, Tablet, Smartphone or Laptop out there. VectorDraw web library is written exclusively in Javascript and runs on the client side, also it contains an object model similar to that of DXF and .Net VectorDraw Framework components.
How to Use
This package will create a subfolder Scripts to the output folder that will contain the VectorDraw web library.
The key of this web control is the .vds format that we have created. The user must convert his drawings into vds format using vdfCAD or our VectorDraw Developers Framework library(nuget package VectorDraw.Drawing.Framework.Net-4.x). VDS files must be uploaded to a server and then the web control(inserted in a webpage) is capable into downloading this file to the client's machine and display it. Using javascript the developer of the website will be capable into getting the file in a DXF like form. Layers , Layouts , Entities , colors , geometrical properties of the entities etc... all are there at the disposal of the developer. It is a project that is evolving very quickly depending the requirements and needs of our clients.
Licensing
VectorDraw web library is a component that is included in the Vectordraw Developers Framework and no additional license is required other than the purchase of the LicVals that have to do with the URL locations that the control will be used in.
Samples
Check our samples here : https://www.vdraw.com/javascript-examples/vectordraw-javascript-samples/
Example of a simple html page with a canvas and a vdrawObject:
<!DOCTYPE html>
<html>
<head>
<script src="../webControl/vdWebControl.js"></script>
<script type="text/javascript">
var vdcanvas; // keep the vdcanvas control global for quick access inside the functions since it is the only one in the this page
function vdrawInitPageLoad() {//Intiallize theweb control inside this function.It must be called inside onload event of this page
vdcanvas = vdmanager.AttachCanvas("canvas"); //create a new web control andattch it to the canvas elemement
//intialize the event handlers for the web control events to be able to print any info or errors to the info label and to add some entities to the model space after opening the document
vdcanvas.vdAfterOpenDocument = _vdAfterOpenDocument;
vdcanvas.vdprogress = _progress;
vdcanvas.vdPrompt = _onprompt;
vdcanvas.vdError = _vdError;
vdcanvas.New();// Select a new document with basic settings to start with and with no entities in it's model space
////Instead you can try to select an exisiting document
//vdcanvas.SelectDocument("./mydocument.vds");//select an existing document relative to the page path. You can also select a document from a url path
}
this.printInfo = function (text) {
info.innerHTML = ":" + (text ? text : "");
}
function _vdError(sender, ErrCategoryId, statusId, info) {
var msg = "";
if (ErrCategoryId == vdConst.Err_LoadFile) msg += "Error Loading file. ";
msg += "Error status code = " + statusId.toString() + ". ";
if (info != undefined) msg += info;
printInfo(msg);
}
function _onprompt(sender, msg) {
printInfo(msg);
}
function _progress(evt) {
if (evt.percent < 0) printInfo(evt.Info);
else if (evt.percent >= 100) printInfo('');
else printInfo(evt.Info + " " + evt.percent.toString() + "%");
}
function _vdAfterOpenDocument() {
var document = vdcanvas.GetDocument();
//add some lines to the document
var line1 = vdcanvas.AddLine([0, 0, 0], [5, 0, 0]);
var line2 = vdcanvas.AddLine([0, 5, 0], [5, 5, 0]);
//print the number of entities in the model space to the info label
var nItems = document.Model.Entities.Items.length; //this should be 2 since we added 2 lines to the model space
printInfo('Document model contains ' + nItems + ' Entities');
vdcanvas.zoomExtents();//first set the view to extents to make sure the lines are visible then zoom in to see the effect of zooming
vdcanvas.zoomScale(vdcanvas.canvas.width * 0.5, vdcanvas.canvas.height * 0.5, 2);
}
</script>
</head>
<body onload="vdrawInitPageLoad()">
<div>
<label id="info">:</label>
</div>
<div>
<canvas id="canvas" width="1000" height="700"> </canvas>
</div>
</body>
</html>
Links
- Homepage
- Examples - Downloads
- Documentation
- Release Notes
- Support
- License
- FAQ
- Feedback & Contributing & Support (support@vdraw.com)
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 12.0.1 | 104 | 3/11/2026 |
| 11.5.20 | 162 | 1/15/2026 |
| 11.5.3 | 272 | 12/24/2025 |
| 11.5.2 | 321 | 11/26/2025 |
| 11.5.1 | 338 | 10/16/2025 |
| 11.4.21 | 297 | 9/26/2025 |
| 11.4.20 | 475 | 9/17/2025 |
| 11.4.5 | 414 | 8/28/2025 |
| 11.4.4 | 396 | 7/1/2025 |
| 11.4.3 | 401 | 6/2/2025 |
| 11.4.2 | 474 | 5/12/2025 |
| 11.4.1 | 410 | 3/18/2025 |
| 11.3.20 | 380 | 2/18/2025 |
| 11.3.7 | 392 | 2/5/2025 |
| 11.3.6 | 362 | 1/29/2025 |
| 11.3.5 | 358 | 1/22/2025 |
| 11.3.4 | 351 | 1/8/2025 |
| 11.3.3 | 356 | 12/10/2024 |
| 11.3.2 | 361 | 11/28/2024 |
| 11.3.1 | 365 | 11/5/2024 |