[CLOSED] Question about directmethod (another one)

  1. #1

    [CLOSED] Question about directmethod (another one)


    Is it possible to have a directmethod returning a value from the code behind to the javascript call?

    I want to have a textarea updated by a database but I want to achive that with a directmethod.
    Last edited by Daniil; Jun 14, 2012 at 12:21 PM. Reason: [CLOSED]
  2. #2
    Yes, it is possible, just read result in success handler, see examples in
    Vladimir Shcheglov
    Sr. Developer
  3. #3

    It did the tricks here the solution:

    In VB code behind

       <DirectMethod(ShowMask:=True, SuccessFn:="RefreshCommentJS")> Public Function RefreshComment(ByVal ChartToDraw As String) As String
            Return ChartToDraw
        End Function
    Client side:

    var RefreshCommentJS = function ( result )
        Ext.Msg.alert( 'Return:', result );

Similar Threads

  1. [CLOSED] DirectMethod's problem
    By softmachine2011 in forum 2.x Premium Help
    Replies: 1
    Last Post: Jun 06, 2012, 4:56 PM
  2. Replies: 1
    Last Post: Sep 13, 2011, 6:19 PM
  3. [CLOSED] directmethod and onload
    By Pablo_Azevedo in forum 1.x Premium Help
    Replies: 1
    Last Post: Jun 21, 2011, 1:08 PM
  4. [CLOSED] MultiCombo and DirectMethod
    By craig2005 in forum 1.x Premium Help
    Replies: 3
    Last Post: Mar 31, 2011, 2:30 PM
  5. Replies: 1
    Last Post: Mar 01, 2011, 12:37 PM

Posting Permissions