Note that there are some explanatory texts on larger screens.

plurals
  1. POAMF ActionResult for asp.net mvc
    primarykey
    data
    text
    <p>I'm building a mvc application which will communicate with flash via AMF, anybody knows if there is any <strong>AMF ActionResult</strong> available on the web ?</p> <p><strong>EDIT</strong>:</p> <p>using @mizi_sk answer (but without using IExternalizable) I did this ActionResult:</p> <pre><code>public class AmfResult : ActionResult { private readonly object _o; public AmfResult(object o) { _o = o; } public override void ExecuteResult(ControllerContext context) { context.HttpContext.Response.ContentType = "application/x-amf"; using (var ms = new MemoryStream()) { // write object var writer = new AMFWriter(ms); writer.WriteData(FluorineFx.ObjectEncoding.AMF3, _o); context.HttpContext.Response.BinaryWrite(ms.ToArray()); } } } </code></pre> <p>but the response handler on the flash side doesn't get hit.</p> <p>in <a href="http://www.charlesproxy.com/" rel="nofollow">Charles</a> at the Response->Amf tab I see this error:</p> <blockquote> <p>Failed to parse data (com.xk72.amf.AMFException: Unsupported AMF3 packet type 17 at 1)</p> </blockquote> <p>this is the raw tab:</p> <pre><code> HTTP/1.1 200 OK Server: ASP.NET Development Server/10.0.0.0 Date: Mon, 14 May 2012 15:22:58 GMT X-AspNet-Version: 4.0.30319 X-AspNetMvc-Version: 3.0 Cache-Control: private Content-Type:application/x-amf Content-Length: 52 Connection: Close 3/bingo.model.TestRequest param1coins name </code></pre> <p>and the Hex tab:</p> <pre><code>00000000 11 0a 33 2f 62 69 6e 67 6f 2e 6d 6f 64 65 6c 2e 3/bingo.model. 00000010 54 65 73 74 52 65 71 75 65 73 74 0d 70 61 72 61 TestRequest para 00000020 6d 31 0b 63 6f 69 6e 73 09 6e 61 6d 65 01 04 00 m1 coins name 00000030 06 05 6a 6f jo </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload