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 13-01-2011, 18:47
knowbodynow knowbodynow is offline
Senior Member
 
Join Date: Mar 2006
Location: Hatsukaichi near Hiroshima
Posts: 434
Default Find the layer of the activeshape

I'm forgetting VBA. How can I find what layer the active shape is on, or shape one when multiple shapes are selected across layers. Thanks.
Reply With Quote
  #2  
Old 13-01-2011, 19:19
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default

Hi.
This should do it.

Code:
Sub getLayer()
    MsgBox ActiveShape.Layer.Name
End Sub

Sub getLayer2()

    Dim l As Layer
    Set l = ActiveShape.Layer
    MsgBox l.Name
End Sub
-John
Reply With Quote
  #3  
Old 21-01-2011, 23:46
knowbodynow knowbodynow is offline
Senior Member
 
Join Date: Mar 2006
Location: Hatsukaichi near Hiroshima
Posts: 434
Default

Doh! Thanks, John

Chris
Reply With Quote
  #4  
Old 22-01-2011, 08:17
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default

Quote:
Originally Posted by knowbodynow View Post
Doh! Thanks, John
Quote:
Originally Posted by knowbodynow View Post
I'm forgetting VBA.
No problem. This happens to me with other languages...lol.
It's hard to stay fresh on everything if you don't use it constantly.
-John
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
Shaperange to Layer ebu CorelDRAW/Corel DESIGNER VBA 2 19-01-2008 04:44
Copy Layer Mike83 Corel Photo-Paint VBA 0 09-02-2006 08:41
Layer Name in CorelDraw 7.0 Jab CorelDRAW CS 2 28-10-2005 00:05
1 color by layer 835 General 2 09-08-2005 03:41
Layer Script Hernán New product ideas 0 18-04-2004 18:10


All times are GMT -5. The time now is 10:36.


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