Solved

How to draw an ARC using iTextSharp

Posted on 2010-09-08
1
1,804 Views
Last Modified: 2013-11-18
Hi there,
I have been producing my own pdf documents using VB.NET and iTextSharp.  So far it has all been going ok but I can't seem to be able to draw an arc.  No matter what I try it always seems to end up being a straight line.

Can someone please help me.

I have tried many different combinations of values.  The line that is generated moves but is still a straight line.

I'm trying to draw half of an ellipse.

Dim FileStream as new IO.FileStream("C:\test.pdf", IO.FileMode.Create)
Dim doc As new Document
Dim writer As iTextSharp.text.pdf.PdfWriter = pdf.PdfWriter.GetInstance(doc, FileStream)
Dim cb As PdfContentByte = writer.DirectContent

doc.SetPageSize(PageSize.A4)

cb.Arc(100, 100, 100, 200, 135, 180)
cb.Stroke()

FileStream.Close()
FileStream.Dispose()

Open in new window

0
Comment
Question by:SoLost
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 5

Accepted Solution

by:
SoLost earned 0 total points
ID: 33633591
Don't worry.  After all that I found the "CurveTo" method that does what I want.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Magento, checking core files for credit card skimming 2 79
Find lists of unemployed workers to call on the phone 3 105
Affiliate marketing 3 126
WP WooCom Prob 7 90
E-commerce is quite a gambling world, and you should never entrust your business to a lucky chance. In order to outrun your competitors in a race to attract as many customers as possible, you need to have a well thought-out strategy under your belt.…
Every business owner understands the significance of online customer reviews and the impact it can have on sales and revenues. With technology advancing at such a rapid pace, getting online reviews has never been easier, especially when many regions…
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question