OberonPlace.com Forums  

Go Back   OberonPlace.com Forums > Corel User Forums > CorelDRAW > Macros/Add-ons

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 10-12-2010, 08:15
shark shark is offline
Senior Member
 
Join Date: Aug 2010
Location: Russia, Belgorod
Posts: 146
Default ListBox table

Good day
I have a macro to export all objects on the page. Before exporting I would like to display form with list of all shapes, next to the column width/height, the estimated size of the file and empty column for result. How correctly to fill properties of ListBox ? Columns and values.

Code:
dim sr as ShapeRange
dim s as Shape
dim cnt&
dim Dimens$, EstSize$, Res$
    Set sr = ActiveSelectionRange
    for cnt = 1 to sr.Count
        set s = sr(cnt)
        Dimens$ = GetWidth_Height(s) '0000x0000mm
        EstSize$ = Get_EstimatedSize(s, 300, cCMYK) '0000Mb
        Res$ = ""

        'fill fields of ListBox
        ... Dimens$, EstSize$, Res$

    next cnt
Reply With Quote
  #2  
Old 10-12-2010, 09:57
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default

Hi.
It would be a wide list but you can just add it to the list:

Code:
myForm.myListBox.AddItem "Dimension: " & Dimens & ", Est. Size: " & EstSize & ", Res: " & Res
-John
Reply With Quote
  #3  
Old 10-12-2010, 15:27
shark shark is offline
Senior Member
 
Join Date: Aug 2010
Location: Russia, Belgorod
Posts: 146
Default Still in difficulties

Hi.
Thank you. I thought that it necessary to fill each column separately.
And whether the data in each row are separated by a delimiter ? And how i can get the value from, say, 3rd row, 2nd column ?
I've never used before ListBox with multiple columns
Reply With Quote
  #4  
Old 10-12-2010, 15:43
runflacruiser's Avatar
runflacruiser runflacruiser is offline
Senior Member
 
Join Date: Jun 2009
Location: Pigeon Forge, TN USA
Posts: 811
Default

Hi.
You can put the shapes static id at the end of your list box string and access the shape with the vba.mid function. I'm assuming you are only trying the access the shape it references.
Or use the list box index.

Also see this post which might have some similar useful info: dynamic form buttons
-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
How can i .additem in listbox? Kursad CorelDRAW/Corel DESIGNER VBA 1 16-07-2009 03:08
Listbox Control with images ? hschneider CorelDRAW/Corel DESIGNER VBA 4 18-03-2008 07:28
ListBox with ColumnHeads fadimas CorelDRAW/Corel DESIGNER VBA 0 20-03-2007 04:43
shape-names in listbox Seelenquell Code Critique 5 14-02-2006 13:12
Index table fadimas CorelDRAW/Corel DESIGNER VBA 2 25-01-2005 01:58


All times are GMT -5. The time now is 17:02.


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