Welcome to LEAD Support Forum Login | Register | Faq  

    LEAD Support Forum
  Resource to find answers and post technical questions about LEAD products.
Search    
   

c# - loading VECTORPOLYLINE
Started by Smoke at 08-15-2008 3:59. Topic has 9 replies.

Print Search « Previous Thread Next Thread »
  08-15-2008, 3:59
Smoke is not online. Last active: 8/13/2008 10:25:33 AM Smoke

Top 200 Posts
Joined on 03-23-2008
Posts 15
c# - loading VECTORPOLYLINE

Attachment: TestLoadingVector.zip
Reply Quote
Hi,
I have problems how to load VECTORPOLYLINE from c#. It works for me for all types of objects, except VECTORPOLYLINE. In this case I'm still receiving "AccessViolationException". I don't have any clue why, because VECTORPOLYLINE structure is pretty simple.
I attach my testing project with my testing file. I would very appreciate if you could point me what I'm doing wrong. I use LeadTools v15.

Thanks in advance for your help.

Smoke
   Report 
  08-18-2008, 16:32
jigar is not online. Last active: 12/12/2008 5:08:42 PM jigar



Top 10 Posts
Joined on 08-22-2007
Posts 480
Re: c# - loading VECTORPOLYLINE
Reply Quote
I'm getting the same error.  I'm still debugging it to figure out what is going on.

LEADTOOLS Technical Support
   Report 
  08-20-2008, 18:02
jigar is not online. Last active: 12/12/2008 5:08:42 PM jigar



Top 10 Posts
Joined on 08-22-2007
Posts 480
Re: c# - loading VECTORPOLYLINE
Reply Quote
After trying a lot of things, I've come to the conclusion that it has to do with the VECTORPEN structure.  The VECTORPEN struct is nested; it has a union inside it.  In C# a union is treated as a struct with the explicit layout flag, but that still doesn't work.  I use P/Invoke utility to generate the C# struct for it and that didn't work either.  I'll confirm it with another struct that has a union in it and then maybe I can report it to the engineers.

LEADTOOLS Technical Support
   Report 
  08-21-2008, 10:36
Smoke is not online. Last active: 8/13/2008 10:25:33 AM Smoke

Top 200 Posts
Joined on 03-23-2008
Posts 15
Re: c# - loading VECTORPOLYLINE
Reply Quote
Thanks for your effort. Please, let me know when you will find the problem.

Thanks,

Smoke
   Report 
  08-26-2008, 3:02
Smoke is not online. Last active: 8/13/2008 10:25:33 AM Smoke

Top 200 Posts
Joined on 03-23-2008
Posts 15
Re: c# - loading VECTORPOLYLINE

Attachment: TestLoadingVector2.zip
Reply Quote
Hi,

attached is my second test case: first attempt to load the file failed but the second attempt to load the same file is ok. Maybe there is a problem with an initialization of some internal structures?

Thanks,

Smoke
   Report 
  09-03-2008, 12:19
jigar is not online. Last active: 12/12/2008 5:08:42 PM jigar



Top 10 Posts
Joined on 08-22-2007
Posts 480
Re: c# - loading VECTORPOLYLINE
Reply Quote
I'm getting something different.  On the first LoadFile() call it succeeds, but on the second one I get System.ExecutionEngineException.  I'm doing a windows update to make sure I have all the fixes.  I'm running WinXP SP2, .NET 3.5 SP1, and VS2008 SP1.

LEADTOOLS Technical Support
   Report 
  09-08-2008, 10:50
Smoke is not online. Last active: 8/13/2008 10:25:33 AM Smoke

Top 200 Posts
Joined on 03-23-2008
Posts 15
Re: c# - loading VECTORPOLYLINE
Reply Quote
I'm running Vista SP1, VS 2008 SP1.

Do you have any advice for me, how to solve the issue? Or a workaround?

Thanks,

Smoke
   Report 
  09-08-2008, 17:10
jigar is not online. Last active: 12/12/2008 5:08:42 PM jigar



Top 10 Posts
Joined on 08-22-2007
Posts 480
Re: c# - loading VECTORPOLYLINE
Reply Quote
I'm going to send this over to the engineers and see if they know of a solution.  I've tried many different things but still no luck.

LEADTOOLS Technical Support
   Report 
  09-09-2008, 10:29
Smoke is not online. Last active: 8/13/2008 10:25:33 AM Smoke

Top 200 Posts
Joined on 03-23-2008
Posts 15
Re: c# - loading VECTORPOLYLINE
Reply Quote
Thanks.

We have bought license for LeadTools last week and integrated to our C# application. It is unpleasant for us that our application sometimes crashed.

Smoke
   Report 
  09-12-2008, 14:52
jigar is not online. Last active: 12/12/2008 5:08:42 PM jigar



Top 10 Posts
Joined on 08-22-2007
Posts 480
Re: c# - loading VECTORPOLYLINE
Reply Quote
Yeah, I'm working on it in my free time also to see if something comes up.

LEADTOOLS Technical Support
   Report 
Post
LEAD Support Fo... » Developer » Vector » c# - loading VECTORPOLYLINE

Powered by Community Server, by Telligent Systems