Adobe
Products
Acrobat
Creative Cloud
Creative Suite
Digital Marketing Suite
Digital Publishing Suite
Elements
Photoshop
Touch Apps
Student and Teacher Editions
More products
Solutions
Creative tools for business
Digital marketing
Digital media
Education
Financial services
Government
Web Experience Management
More solutions
Learning Help Downloads Company
Buy
Home use for personal and home office
Education for students, educators, and staff
Business for small and medium businesses
Licensing programs for businesses, schools, and government
Special offers
Search
 
Info Sign in
Welcome,
My cart
My orders My Adobe
My Adobe
My orders
My information
My preferences
My products and services
Sign out
Why sign in? Sign in to manage your account and access trial downloads, product extensions, community areas, and more.
Adobe
Products Sections Buy   Search  
Solutions Company
Help Learning
Sign in Sign out My orders My Adobe
Preorder Estimated Availability Date. Your credit card will not be charged until the product is shipped. Estimated availability date is subject to change. Preorder Estimated Availability Date. Your credit card will not be charged until the product is ready to download. Estimated availability date is subject to change.
Qty:
Purchase requires verification of academic eligibility
Subtotal
Review and Checkout
Adobe Developer Connection / Adobe Connect Developer Center /

Saving data locally in a custom application for Adobe Connect

by Anurag Aggarwal

Anurag Aggarwal

Content

  • Using the file reference API to save data locally
  • Where to go from here

Created

6 December 2010

Page tools

Share on Facebook
Share on Twitter
Share on LinkedIn
Bookmark
Print
Adobe Connect collaboration SWF

Requirements

Prerequisite knowledge

Knowledge of ActionScript 3 and Flex is required to make the most of this article.


Also required

  • Adobe Connect 8 Add-in
  • Adobe Connect Collaboration Builder SDK

User level

Intermediate

Required products

  • Adobe Connect (Download trial)
  • Flash Player 10.1

Sample files

  • SaveLocal.zip

This article describes how to create a custom application for Adobe Connect that saves data locally on the user’s machine. Although Flash Player doesn’t support this functionality by default, it is available when you are using the Adobe Connect Add-in to launch meetings. After reading this article you should be able to write your own application that will save any string to a file on the local machine.

Using the file reference API to save data locally

When running the Adobe Connect Add-In you can use the file reference class to download data from a server to the client machine and to upload data to the server from the client machine. The same class exposes a saveText function, which you can use to save text directly to a file if you are running the add-in.

Because this function is not directly available in Flash Player, you need to use it as a dynamic property in order to compile your application with the Flex compiler; for example:

public var fileRef:FileReference = new FileReference(); fileRef['saveText'](textToSave, defaultFileName= null, defaultExtension=null);

This code will open a file save dialog box that prompts for the location and name of the file to save.

The onApply() function in the sample application checks for the availability of this API and then uses it to save text locally:

public function onApply():void { if (fileRef.hasOwnProperty('saveText')) { try { fileRef['saveText']("Adobe Connect Information..." + ta.text); } catch(e:Error) { trace("Error Message " + e.message); } } }

When the sample application is compiled into an SWF and loaded in Flash Player without the Adobe Connect Add-in, the Button and TextArea are disabled (see Figure 1).

The SWF loaded in Flash Player.
Figure 1. The SWF loaded in Flash Player.

When the sample SWF is loaded in the Adobe Connect Add-in, the Button and TextArea are enabled, and you can use them to save text to the local machine (see Figure 2).

The SWF loaded in Adobe Connect Add-in
Figure 2. The SWF loaded in Adobe Connect Add-in

To test the application, type some text and click Save Text. When the file save dialog box opens, simply specify the destination path for the file where the text will be saved.

Where to go from here

For more information on extending the functionality of Adobe Connect for end users, see the Adobe Connect Developer Center.

More Like This

  • Integrating the Asterisk MeetMe audio conferencing service with Adobe Connect 8
  • Building a multiuser Sudoku contest game using the Adobe Connect Collaboration Builder SDK
  • Creating a custom stamp for Adobe Connect 8
  • Building a multiple-question survey application for Adobe Connect 8
  • Building a multiuser snake and ladder game using the Adobe Connect Collaboration Builder SDK

Products

  • Acrobat
  • Creative Cloud
  • Creative Suite
  • Digital Marketing Suite
  • Digital Publishing Suite
  • Elements
  • Mobile Apps
  • Photoshop
  • Touch Apps
  • Student and Teacher Editions

Solutions

  • Digital marketing
  • Digital media
  • Web Experience Management

Industries

  • Education
  • Financial services
  • Government

Help

  • Product help centers
  • Orders and returns
  • Downloading and installing
  • My Adobe

Learning

  • Adobe Developer Connection
  • Adobe TV
  • Training and certification
  • Forums
  • Design Center

Ways to buy

  • For personal and home office
  • For students, educators, and staff
  • For small and medium businesses
  • For businesses, schools, and government
  • Special offers

Downloads

  • Adobe Reader
  • Adobe Flash Player
  • Adobe AIR
  • Adobe Shockwave Player

Company

  • News room
  • Partner programs
  • Corporate social responsibility
  • Career opportunities
  • Investor Relations
  • Events
  • Legal
  • Security
  • Contact Adobe
Choose your region United States (Change)
Choose your region Close

North America

Europe, Middle East and Africa

Asia Pacific

  • Canada - English
  • Canada - Français
  • Latinoamérica
  • México
  • United States

South America

  • Brasil
  • Africa - English
  • Österreich - Deutsch
  • Belgium - English
  • Belgique - Français
  • België - Nederlands
  • България
  • Hrvatska
  • Česká republika
  • Danmark
  • Eastern Europe - English
  • Eesti
  • Suomi
  • France
  • Deutschland
  • Magyarország
  • Ireland
  • Israel - English
  • ישראל - עברית
  • Italia
  • Latvija
  • Lietuva
  • Luxembourg - Deutsch
  • Luxembourg - English
  • Luxembourg - Français
  • الشرق الأوسط وشمال أفريقيا - اللغة العربية
  • Middle East and North Africa - English
  • Moyen-Orient et Afrique du Nord - Français
  • Nederland
  • Norge
  • Polska
  • Portugal
  • România
  • Россия
  • Srbija
  • Slovensko
  • Slovenija
  • España
  • Sverige
  • Schweiz - Deutsch
  • Suisse - Français
  • Svizzera - Italiano
  • Türkiye
  • Україна
  • United Kingdom
  • Australia
  • 中国
  • 中國香港特別行政區
  • Hong Kong S.A.R. of China
  • India - English
  • 日本
  • 한국
  • New Zealand
  • 台灣

Southeast Asia

  • Includes Indonesia, Malaysia, Philippines, Singapore, Thailand, and Vietnam - English

Copyright © 2012 Adobe Systems Incorporated. All rights reserved.

Terms of Use | Privacy Policy and Cookies (Updated)

Ad Choices

Reviewed by TRUSTe: site privacy statement