Flash Remoting & ColdFusion example

As part of our development process at work, we extensively use a bug tracking application I built about 1.5 years ago. Commonly, our QA team will rake through a site during and after the development process, entering bugs into this application in a different browser window. Additionally, if a client encounters an error on their site, they can create a ‘ticket’ and view the status of tickets created in the past, again, all in a dedicated browser window. I thought it would be cool to be able to incorporate our bug tracking application into other applications, letting QA, development, and clients view and create tickets from their own site, which means either taking code from the bug tracking application and porting into each of our clients sites (written in Java, ColdFusion, ColdFusion MX, ASP, PHP…) *or* use Flash to call the bug tracking application remotely. So today and yesterday I spent some time working with Flash, specifically I used:

— Flash MX to parse an XML packet that came from …
— a web service built using .NET through …
ColdFusion MX remoting

Pretty fun.. some questions (for anyone reading):
— how does one effectively debug Flash applications?
— what books would you recommend for a programmer learning to utilize Flash, specifically Actionscripting?

And finally, here’s my code, most of which is pieced together from various tutorials or components I found online (minus the sensitive usernames/passwords/hostnames):

#include “NetServices.as”
#include “NetDebug.as”

// a utility function used to pad string s with repeating instances of character c
// on the right, until it is n characters long altogether
function padr(s, n, c) {
var nLen = s.length;
for (var i=nLen; i 11627
// 10/23/2002 10:32:00 AM
//
// 2
// 4
// Low
// New
// First
ticketid = new XML();
ticketid = elementList[0];
datecreated = new XML();
datecreated = elementList[1];
title = new XML();
title = elementList[2];
sLabel = padr(ticketid.firstChild.nodeValue, 10, ” “);
sLabel += “\t” + padr(datecreated.firstChild.nodeValue, 25, ” “);
sLabel += “\t” + padr(title.firstChild.nodeValue, 55, ” ” );
lbBugs.addItem(sLabel);
}

}

lbBugs.setRowCount(18);
lbBugs.setWidth(560); // note: setSize would wipe out setRowCount

// set this style on all components in movie
globalStyleFormat.textFont = “Verdana”;
globalStyleFormat.textSize = 11;
globalStyleFormat.applyChanges();

// apply a monospace font to the listbox for an attempt at controlling column spacing
var monospaceStyle = new FStyleFormat( {textFont:”Courier”, textSize:9} );
monospaceStyle.addListener(lbBugs);

// format for pushbuttons only
// add listener to this when each pushbutton is attached
var centerFontStyle = new FStyleFormat( {textAlign:”center”} );

if (init == null)
{
init = true;

// set the default gateway URL (this is used only in authoring)
NetServices.setDefaultGatewayUrl(“http://localhost:8500/flashservices/gateway”);

// connect to the gateway
gateway_conn = NetServices.createGatewayConnection();

// get a reference to a service
myService = gateway_conn.getService(“http://yourHost/soap/tracker.asmx?WSDL”, this);
}

dataLoad();

stop();

ADA requirements

I’m working on a small consulting project for a local chemical company that wants to make sure that they meet ADA requirements. Looks like there are a ton of resources on the web regarding accessibility, here are a few I need to read more on:

Practical accessibility: Core concepts [from Dartmouth]

Section 508 Web Standards & WCAG Priority 1 Checkpoints [JimThatcher.com]

AT&T Website Development Accessibility Guidelines

Accessiblog