Can't get demo working ...


Author
Message
Peter Spinato
Peter Spinato
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)
Group: Forum Members
Posts: 1, Visits: 1

Support,

Below are my .aspx and the .cs file - I run the demo app to draw an eclipse but the screen just shows a box with an x in it.  Any help is apprecaited,

-Peter

 

ASPX file

---------------------------------------------------------------------------------------------------------------------------

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="TheView.aspx.cs" Inherits="TheView" %>

<%@ Register assembly="Nevron.Diagram.WebForm, Version=9.7.23.12, Culture=neutral, PublicKeyToken=95bcc3d41b0512e9" namespace="Nevron.Diagram.WebForm" tagprefix="ndwc" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head runat="server">

<title>Untitled Page</title>

</head>

<body>

<form id="form1" runat="server">

<div>

<ndwc:NDrawingView ID="NDrawingView1" runat="server" Width="416px" Height="336px">

</ndwc:NDrawingView>

</div>

</form>

</body>

</html>

 

CS file

-----------------------------------------------------------------------------------------------------------------------------------

using System;

using System.Collections;

using System.Configuration;

using System.Data;

using System.Linq;

using System.Web;

using System.Web.Security;

using System.Web.UI;

using System.Web.UI.HtmlControls;

using System.Web.UI.WebControls;

using System.Web.UI.WebControls.WebParts;

using System.Xml.Linq;

using System.Drawing;

using Nevron.GraphicsCore;

using Nevron.Diagram;

using Nevron.Diagram.WebForm;

using Nevron.Diagram.Shapes;

public partial class TheView : System.Web.UI.Page

{

protected void Page_Load(object sender, EventArgs e)

{

if (NDrawingView1.RequiresInitialization)

{

NDrawingView1.ViewLayout = CanvasLayout.Fit;

NDrawingView1.DocumentPadding = new Nevron.Diagram.NMargins(10);

NDrawingView1.Document.HistoryService.Stop();

NDrawingView1.Document.BeginInit();

NDrawingView1.Document.Bounds = new NRectangleF(0, 0, 420, 320);

NStandardFrameStyle fs = (NDrawingView1.Document.BackgroundStyle.FrameStyle as NStandardFrameStyle);

fs.InnerBorderWidth = new NLength(0);

NBasicShapesFactory factory = new NBasicShapesFactory(NDrawingView1.Document);

NEllipseShape ellipse = factory.CreateShape((int)BasicShapes.Ellipse) as NEllipseShape;

ellipse.Name = "myEllipse";

ellipse.Width = 250f;

ellipse.Height = 250f;

ellipse.Center = new NPointF(200, 200);

ellipse.Style.FillStyle = new NGradientFillStyle(GradientStyle.Horizontal, GradientVariant.Variant1, Color.Navy, Color.White);

NDrawingView1.Document.ActiveLayer.AddChild(ellipse);

NDrawingView1.Document.EndInit();

}

}

}

 

 


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search