OberonPlace.com Forums  

Go Back   OberonPlace.com Forums > Developer Forums > VBA > CorelDRAW/Corel DESIGNER VBA

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 06-09-2013, 14:21
nic nic is offline
Member
 
Join Date: May 2009
Posts: 90
Default Setting Drawing Origin in VBA

Hi I have been trying to set the origin of a document being created in Draw X6 using the VBA commands

DrawingOriginX = 0
DrawingOriginY = 0

but this dosent seem to be doing anything

Is there a way of setting the rulers origin in VBA or saving a default setting so that new docs use a particular origin?

Thanks
nic
Reply With Quote
  #2  
Old 11-10-2013, 21:23
Alex's Avatar
Alex Alex is offline
Administrator
 
Join Date: Nov 2002
Posts: 1,940
Blog Entries: 4
Default

Can you post the actual code you are using? From what you showed, it looks like you are setting two regular variables to zeros.
Reply With Quote
  #3  
Old 30-10-2013, 08:04
nic nic is offline
Member
 
Join Date: May 2009
Posts: 90
Default Origin

Hi Alex
sorry for the delay in replying. I managed to lose my GMS file upgrading to Win8 so no longer have the original but have just tried to recreate it and seem to have made some progress although still not understanding how the origin is calculated.

On a page 100mm square I thought Coreldraw X6 would by default use the bottom left corner of a page as the origin so that the commands -


Code:
ActiveDocument.DrawingOriginX = 0
ActiveDocument.DrawingOriginY = 0
would set the origin to the bottom left corner of the page, and

Code:
ActiveDocument.Unit = cdrMillimeter 'Set Corel to work in Millimeters
ActiveDocument.DrawingOriginX = 50
ActiveDocument.DrawingOriginY = 50
would set the origin to the centre, BUT on testing it xy=0 sets the drawing origin to the centre and xy=50 sets the origin to the top right.

Can now make it work but dont understand why it works that way.

Any help appreciated,
nic
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Draw 12 Setting guides exactly knowbodynow CorelDRAW/Corel DESIGNER VBA 2 04-11-2009 22:18
Crops marks Setting in Corel Draw X3 ubrbilly General 1 17-04-2009 08:06
Change Import setting Wynprice General 4 07-10-2007 11:52
Setting Printable Layers knowbodynow CorelDRAW/Corel DESIGNER VBA 2 13-04-2006 08:38
Setting Outline Color AC CorelDRAW/Corel DESIGNER VBA 1 18-03-2003 18:33


All times are GMT -5. The time now is 11:06.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
Copyright © 2011, Oberonplace.com