User Guide
Table Of Contents
- Contents
- About Flash Remoting
- Getting Started
- Using Flash Remoting ActionScript
- Using the RemotingConnector component (Flash Professional only)
- Using Flash Remoting Data in ActionScript
- About Flash Remoting and data types
- Understanding Action Message Format
- Converting from ActionScript to application server data types
- Converting from application server data types to ActionScript
- ColdFusion to ActionScript data conversion issues
- About working with objects
- About working with RecordSet objects
- About working with XML
- The NetConnection Debugger
- Using Flash Remoting with ColdFusion MX
- Using Flash Remoting for Java
- About Flash Remoting for Java
- Calling Java classes or JavaBeans from ActionScript
- Calling Enterprise JavaBeans (EJBs) from Flash
- Calling servlets and JSPs from Flash
- Calling JMX MBeans from Flash (JRun only)
- Calling server-side ActionScript from Flash (JRun only)
- Handling function results in ActionScript
- Using Flash Remoting with JRun security
- Passing XML objects between Flash and Java
- Viewing Flash Remoting log entries
- Using Flash Remoting for Microsoft .NET
- Flash Remoting for Microsoft .NET
- Calling ASP.NET pages from Flash
- Making an ASP.NET page available to Flash Remoting
- Getting a reference to an ASPX-based service in ActionScript
- Invoking ASPX pages in ActionScript
- Using the Flash Remoting custom server control in ASPX pages
- Using the Flash Remoting namespace in code-behind files
- Using ASP.NET state management with Flash Remoting
- Using ASP.NET exception handling
- Using ADO.NET objects with Flash Remoting
- Displaying a RecordSet object in Flash with ActionScript
- Calling web services from Flash
- Calling ASP.NET assemblies from Flash
- Viewing Flash Remoting log entries
- Using NetServices and Connection Classes
- Index

Using the NetConnection Debugger in ActionScript 95
Using the Netdebug.initialize() method
The
NetDebug.initialize() method initializes debug support for Flash Remoting. You must
call this method prior to creating a connection or using any debugging operations, and typically
before any ActionScript is executed in the SWF file. This method returns the Boolean value
true
if it initializes debug support successfully. Otherwise, it returns a value of
false. The following
statements, for example, initialize debug support for Flash Remoting before creating a connection
to a remote service. The example connects to the CustomerData service used by the
CustomerInfoExampleAPI sample application:
import mx.remoting.Service;
import mx.services.Log;
import mx.remoting.debug.NetDebug;
function CustomerDisplayForm() {
NetDebug.initialize();
super();
var custService:Service = new Service(
"http://examples.macromedia.com/flashservices/gateway/",
new Log(Log.DEBUG,"CustomerDisplayApp"),
"petmarket.api.catalogservice",
null,
null);
}
CustomerDisplayForm();
For more information on the NetDebug.initialize() method, see the NetDebug class in the
Flash Remoting ActionScript Dictionary in Help. For information about the
CustomerInfoExampleAPI sample application, see “Using the Flash Remoting ActionScript API
in the CustomerInfoExampleAPI application” on page 47.
Using the NetDebug.trace() method
The
NetDebug.trace() method displays a trace message in the NetConnection Debugger. For
example, the following
NetDebug.trace() method displays a trace message with the text “I just
created myService.” in the NetConnection Debugger:
NetDebug.trace("I just created myService.");
The argument to the NetDebug.trace() method is not limited to a string. It can be a Flash
object. For example, you can use the
NetDebug.trace() method to report the values of multiple
variables, as in the following code:
NetDebug.trace({arg1value:arg1, arg2value:arg2});
Using connection-specific debugging methods
If your application uses multiple connections, you can use the debugging-related methods of each
Connection object to debug the individual connections.
The
setDebugId() method creates an ID that is displayed in the NetConnection Debugger
output for events associated with the specific Connection object; for example:
gatewayConnection.setDebugId("Gateway Connection");