Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Sep 15, 2010, 06:45 PM   #1
obelixander
macrumors newbie
 
Join Date: Sep 2010
Help to convert MS Word VBA to Applescript

I have the following procedure written in VBA for Word which I need to use in Word 2008 for Mac. Please bear with me as I've had a very basic first stab and know very little about Apple Script.

Sub descriptionRelativeMacro()

If Selection.Type = wdSelectionNormal Then

ActiveDocument.Indexes.MarkEntry Range:=Selection.Range, _

Entry:="D:" & Selection.Range.Text & "/" & Time() & "/-PPP/R/"

End If

End Sub

I've started to try and write that in Apple Script by writing this:

if selection type of selection is selection normal then mark for index active document range text object of selection ¬
entry "D:" & content of text object of selection & "/" & (current date) & "/-PPP/R/"
end if

but I get the following error message:

"Expected “then”, etc. but found identifier."

Can you help?

Many thanks.
obelixander is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

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
Can't get EndNote to integrate with MS Word Boris A Mac Applications and Mac App Store 5 Sep 30, 2012 01:20 PM
Ms Word 2010 to Pages converter? Dr Kevorkian94 Mac Applications and Mac App Store 12 Sep 21, 2011 03:23 PM
Convert MS Word formatting to Pages Reddkryten iPad 5 Jul 9, 2010 03:24 AM
Need someone's help to convert one .Pages file to .doc afinefrenzy Mac Basics and Help 3 May 11, 2010 11:16 PM
Pages/MS Word converting to web based document carlosbutler Mac Applications and Mac App Store 2 Apr 10, 2009 05:16 PM


All times are GMT -5. The time now is 12:04 PM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

Privacy / DMCA contact / Affiliate and FTC Disclosure
Copyright 2002-2013, MacRumors.com, LLC