Welcome to Mediasparkles

News : Flash

My friend Edwin Wong from the Flash Player team has created a web service example that does not use the WebServiceConnector component. Instead, it uses the WebServiceClasses available from Window > Other Panels > Common Libraries > Classes and dynamically establishes a connection to the web service by calling new WebService(). In Flash MX 2004 Professional, the easiest way to connect to a web service is to use the WebServiceConnector component like I did in the Fullasagoog example. Another way is to use Flash Remoting which I did here. Edwin's method is the third and probably hardest way to connect to a web service in Flash because it is not heavily documented. What little documentation is there lives in the Help panel under

Using Components > Components Dictionary > Web service classes

and

Using Flash > Data Integration > Data Binding > Working with data binding and web services at runtime

As the Help files state, "this WebService API is not the same as the WebServiceConnector component API."

Edwin's example sheds some more light on the WebService API. A WebService object is instantiated with

ws = new WebService(wsdlURI [, logObject]);

After that, methods or properties as defined by the WSDL can be accessed like so:

ws.someMethodFromWSDL();
ws.someParameterFromWSDL = "someValue";


The WSDL for the TemperatureService, for example, defines a getTemp() method. This method can be accessed directly via the instance of the WebService class as in

ws.getTemp(zipcode);


The advantage of ditching the WebServiceConnector component for the WebService class is a savings of 44K!

 posted by Vera Fleischer (10/18/2003 11:17:13 PM);




The Dura brothers are now the Central brothers, did you know that? I didn't until yesterday. Daniel and Josh were in a *top secret* meeting last night in the Macromedia boardroom with Kevin Lynch and Mike Chambers. How do I know all of this? Thanks to the kevincam. I was in the Central Dev Chat, and Kevin was broadcasting a cam feed live from the "late night pizza brainstorm." What were they brainstorming about? I have no idea. The audio wasn't on. But I'm sure we will find out eventually.

I saved the chat transcript. Email me if you're interested in seeing it. I also have a couple of cam screenshots from the *top secret* meeting. Don't expect them to reveal too much, but some of the speculatory comments from the chatroom sure were amusing.

 posted by Vera Fleischer (10/17/2003 06:53:09 AM);




Today I played with some of the timeline effects available for download at flashextensibility.com. I especially liked Keith Peters' Checkerboard effect. It takes the selected object(s) on the stage, measures their dimensions and then applies a mask to the object(s) which grows by one square per frame. The number of frames the effect spans depends on the number of columns and rows you specify when you first apply the effect. Here is an example of one object (a bitmap) with the Checkerboard effect applied on 10 rows and 10 columns:









One unfortunate thing about effects though is that they are only random at author time and not at runtime. At the time the effect is applied, it is completely random which square is going to be uncovered first, which one comes next, and so forth. But once the effect symbol has been created at author time, the effect will always look the same at runtime. Only if you created the same effect with ActionScript would it be random at runtime and look different every time the .swf is viewed.

An aside: When I first downloaded the effect, I noticed that it came in .mxp format, which means I had to install it through the Extension Manager. I was disappointed by the .mxp format because I was hoping to look at the .jsfl and .xml files to see the code. But even though the .mxp file keeps the source files tucked away, there is another way to access them. After installing the effect, go to
C:\Documents and Settings\{username}\Local Settings\Application Data\Macromedia\Flash MX 2004\en\Configuration\Effects

On Mac, that would be
{username}:Library:Application Support:Macromedia:Flash MX 2004:en:Configuration:Effects

You will find checkerboard.jsfl and checkerboard.xml there. I knew Keith wasn't going to let down those who want to learn.

 posted by Vera Fleischer (10/15/2003 06:48:11 PM);




Want to add another app to your Central portfolio? Download Mike Lyda's FiRe. FiRe is a Find and Replace app (get it?) that uses LCService connections. (I actually don't know what LCService connections are, but you might.) Mike said it took him a while to figure out how to create an application that runs in Central, so go benefit from his legwork!

 posted by Vera Fleischer (10/14/2003 07:31:23 AM);




Should Central apps be considered RIA's? Yes, no, maybe so? Please post your thoughts in the comments because I'd really like to know.

 posted by Vera Fleischer (10/13/2003 10:00:32 PM);




Check out CentralMX.com, the first community blog centered around Central. Go now! I think good things are going to come out of this site. Right now it's very much focused on the Central Dev Chat, but I'm sure that will change as other apps start sprouting.

 posted by Vera Fleischer (10/13/2003 09:57:32 PM);