![]() |
|
|
|
#1
|
||||
|
||||
|
Martin What you are asking sounds doable but would take more time than I have available at the moment. Macropod raised the question of inline vs floating shapes which would need to be answered but the basic (aircode) approach I would use is to loop the graphics and apply the heading 1 style at that point to work out the previous heading 1 number. You could also use a counter to keep track of how many graphics have already been found and reset that when the heading number increases. My initial musings are Code:
Sub ExportPicts()
Dim aShp As InlineShape, i As Integer, sPath As String, sName As String
Dim iCounter As Integer
sPath = ActiveDocument.Path & Application.PathSeparator
For Each aShp In ActiveDocument.InlineShapes
iCounter = iCounter + 1
aShp.Range.Paragraphs(1).Style = "Heading 1"
i = aShp.Range.Paragraphs(1).Range.ListFormat.ListString - 1
aShp.Range.Paragraphs(1).Style = "Normal"
Debug.Print i, iCounter
'not sure on the code to export inlineshape
Next aShp
End Sub
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| XML Schema Parent Child Extraction | ChrisOK | Excel Programming | 0 | 11-16-2017 08:22 AM |
| Log file extraction | xendistar | Excel | 0 | 09-01-2016 02:08 PM |
Data extraction from a cell!
|
JTevez | Excel | 2 | 10-14-2015 11:56 PM |
Bibliography creation and automatic extraction
|
styxsailor | Word | 3 | 11-30-2012 02:42 PM |
Email Extraction
|
dpad | Outlook | 1 | 08-17-2010 06:01 PM |