Jump to content

Copy field to Office App


This topic is 6268 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I'm trying to export a couple of fields into Powerpoint, but I cannot get the applescript correct. Running a native applescript will allow me to put something into Powerpoint, but I can't get a field to export and then show up in Powerpoint.

I've tried writing a calculated script, but I always seem to get an error 2741, so I must have something wrong.

Here is the calculated script I'm using any help would be appreciated.

"tell application "Microsoft PowerPoint"

activate

set this_presentation to make new presentation

set this_slide to make new slide at the beginning of this_presentation ¬

with properties {layout:slide layout title slide}

set the title_text to text range of text frame of shape 1 of this_slide

set the subtitle_text to text range of text frame of shape 2 of this_slide

set content of the title_text to "" & Event_Select::Title & ""

set content of the subtitle_text to "" & Event_Select::Description & ""

end tell"

jon

Link to comment
Share on other sites

You're giving FileMaker instructions to Powerpoint. That really cannot be expected to work. Try something like this. And don't use the calculated applescript, use native applescript

copy cell "Event_Select::Description" of current record to Description

copy cell "Event_Select::Title" of current record to Title

tell application "Microsoft PowerPoint"

activate

set this_presentation to make new presentation

set this_slide to make new slide at the beginning of this_presentation ¬

with properties {layout:slide layout title slide}

set the title_text to text range of text frame of shape 1 of this_slide

set the subtitle_text to text range of text frame of shape 2 of this_slide

set content of the title_text to Description

set content of the subtitle_text to Title

end tell

Edited by Guest
Link to comment
Share on other sites

  • 2 months later...

I came back to the forum to see if there were any more attempts at what I was doing here, and realized that I had actually posted something, so I thought I would update to what I found out. I ended up using a calculated applescript to do this, check it out...(I think I was missing the "¶" the first time.

"tell application "Microsoft PowerPoint"¶

activate¶

set this_slide to make new slide at the end of the active presentation ¦

with properties {layout:slide layout title slide}¶

set the title_text to text range of text frame of shape 1 of this_slide ¶

set the subtitle_text to text range of text frame of shape 2 of this_slide ¶

set content of the title_text to "" & Event_Select::Title & "" ¶

set content of the subtitle_text to "" & Event_Select::Attendee & "" ¶

set content of the subtitle_text to "" & Event_Select::Description & "" ¶

set font name of font of title_text to "Optima"¶

set font name of font of subtitle_text to "Optima"¶

set font size of font of title_text to 24.0¶

set font size of font of subtitle_text to 18.0¶

end tell"

Link to comment
Share on other sites

This topic is 6268 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.