"Argument mismatch in property or function argument" on nodes.length

Hi,
However I try to get the length on the nodes property, I always get this error:
  "Argument mismatch in property or function argument"
It happens regardless of which level of the DOM/SOM I try at, even though I can resolve nodes, get values, etc.
An example that would throw the error: 
    var objDataGroup = xfa.resolveNode("$data");      xfa.host.messageBox (objDataGroup.nodes.length);
What am I doing wrong?
Thanks!

Did you try the below..
Try the resolveNode on $record instead of $data.
var objDataGroup = xfa.resolveNode("$record");
xfa.host.messageBox("" + objDataGroup.nodes.length);
Thanks
Srini
Message was edited by: Srini Dhulipalla

Similar Messages

  • Argument mismatch error

    I'm trying a simple click a radio button to select another radio button. I'm getting this error message:
    GeneralError: Operation failed.
    XFAObject.rawValue:2:XFA:form1[0]:page2[0]:assocType[0]:RadioButtonList[0]:click
    Argument mismatch in property or function argument
    Here's my script:
    if (this.rawValue == 1) {
    page2.wklyHours.RadioButtonList.rawValue =
    3;
    else
    page2.wklyHours.RadioButtonList.rawValue
    = 0;}
    Thanks,
    MDawn

    Hi,
    It depends on the bound values for the radio button exclusion group (see Object > Binding palette).
    If the radio button exclusion group does not have a bound value of 0, then it would throw an error. If you are trying to clear the radio button exclusion group you set it a string value of zero length.
    page2.wklyHours.RadioButtonList.rawValue = "";
    Hope that helps,
    Niall

  • Using a variable in a js function argument

    Folks,
    This is very basic, but I still cannot get it...
    I have this js function in an ASP page:function MM_changeProp(objId,x,theProp,theValue) { //v9.0
      var obj = null; with (document){ if (getElementById)
      obj = getElementById(objId); }
      if (obj){
        if (theValue == true || theValue == false)
          eval("obj.style."+theProp+"="+theValue);
        else eval("obj.style."+theProp+"='"+theValue+"'");
    }i don't understand the function, as it was put in automatically by dreamweaver. right now, i am using this onclick event of an image:<div id="apDiv19" onclick="MM_changeProp('apDiv7','','backgroundColor','#FFFF00','DIV')"></div>the #FFFF00 is the color YELLOW. it is being passed to the theValue argument of the js. what i simply want to do is establish a global variable that will house a color string (like #FFFF00), and then use it in the function argument everytime i need the function. something like this:<div id="apDiv19" onclick="MM_changeProp('apDiv7','','backgroundColor',VARIABLE,'DIV')">i do not know how to do two things:
    1) initialize and assign the variable a value, and where to establish it (inside the script tags? in the head? in the body?)
    2) how to use the variable as an argument in the function
    any help greatly appreciated for this novice. thanks!

    ajetrumpet wrote:
    Folks,
    This is very basic, but I still cannot get it...
    I have this js function in an ASP page:This forum is not about ASP nor JavaScript. Please use Google to find an appropriate JavaScript forum.

  • Using variables for function arguments AS2

      Hello,
    I am trying to create a function in AS2.
    After creating the function, I want to use values stored in variables for the function arguments rather than manually typing static values for carrying out the function calculation. Also, I want to use the function to assign a new value to the existing variable.
    I have asked a similar question 2 days ago here and got the answer (thank you), but now I got one more question - How can I create the function to assign a value to the variable while that variable itself is also a function argument?
    For example, I have 6 numeric variables:
    var CoinA:Number = 10;
    var CoinB:Number = 20;
    var CoinC:Number;
    var CoinD:Number = 30;
    var CoinE:Number = 40;
    var CoinF:Number;
    Then I tried to create a function to assign values to variables CoinC and CoinF:
    function CalculationA(FirstCoin, SecondCoin, ThirdCoin):Void {
         FirstCoin = SecondCoin + ThirdCoin;
    CalculationA(CoinC, CoinA, CoinB);
    CalculationA(CoinF, CoinE, CoinF);
    The above code didn't really assign the values 30 and 70 to the variables CoinC and CoinF but instead, values of CoinC and CoinF are undefined.
    Please give me the correct code if there's a correct way of doing this.
    Thank you,

    Here is one way of doing it, by passing a string value of the variable name instead of the actual variable name....
    var CoinA:Number = 10;
    var CoinB:Number = 20;
    var CoinC:Number;
    var CoinD:Number = 30;
    var CoinE:Number = 40;
    var CoinF:Number;
    function CalculationA(FirstCoin, SecondCoin, ThirdCoin):Void {
         this[FirstCoin] = SecondCoin + ThirdCoin;
    CalculationA("CoinC", CoinA, CoinB);
    CalculationA("CoinF", CoinD, CoinE);
    (Note that in your second function call I changed the coins since CoinF (ThirdCoin) is undefined at that point.)

  • Bridge CS4 Bad argument {LiveObject("Thumbnail").property(0)}

    Can anyone assist with resolving this error message? Bad argument {LiveObject("Thumbnail").property(0)}
    It happens after saving a Gallery.
    Using Windows 7 + Dreamweaver CS4
    Thank you

    Hi
    Can you provide more details to reproduce such error?
    e.g.
    1. launch bridge
    2. choose some files, in output mode, choose a template..
    3..etc
    thanks.

  • Error message: 450 [Wrong number of arguments or invalid property assignment]

    Hello Support,
    I have a vbscript which does some database query. i see from the log that script quits with the below error.
    Error message: 450 [Wrong number of arguments or invalid property assignment]
    but when i execute the same query directly on database, it gives me correct result. also i see that not all the time script quits with this error.
    Does anyone have idea how to troubleshoot it?
    -KAKA-

    i see. i know at which line it fails as error handling is done and will be written in the log.
    sQuery_Prod = "select object_text from sto_ov_externalnode where name = '" & NodeId & "'"
    oRecordSet_Prod.Open sQuery_Prod, oConnection, adOpenStatic, adLockOptimistic
    if err.number <> 0 then
    LogWrite ("Unable to run query")
    LogWrite ("Query: [" & sQuery_Prod & "]")
    LogWrite ("Connection string: [" & sConnect & "]")
    LogWrite ("Error message: " & err.number & " [" & err.description & "]")
    wscript.quit(1)
    end if
    and this piece of code write following in the log.
    07.10.2014 16:55:03:Unable to run query
    07.10.2014 16:55:03:Query: [select object_text from sto_ov_externalnode where name = '{B10255CF-F618-45FB-99BC-31A57D747702}']
    07.10.2014 16:55:03:Connection string: [DSN=Script;DRIVER={SQL Native Client};User ID=xxxxxx;Password=yyyyyy]
    07.10.2014 16:55:03:Error message: 450 [Wrong number of arguments or invalid property assignment]
    Where as i can run query "select object_text from sto_ov_externalnode where name = '{B10255CF-F618-45FB-99BC-31A57D747702}'" successfully directly on database.
    also in the next cycle same query will be successfull within script too.
    Does this help in understanding the problem?
    -KAKA-

  • Bypassing function argument without changing default value

    Hi there
    I’m having some problems understanding how I can bypass function arguments without changing its default value. Here are some examples:
     function myFunction ( arg1:Boolean, arg2:String="default string", arg3:Number=3 ):Array
        return new Array (arg1, arg2, arg3);
    trace(myFunction(true, "new string", 5));
    // true,new string,5
    trace(myFunction(true, undefined, 5));
    // true,,5
    trace(myFunction(true, null, 5));
    // true,,5
    trace(myFunction(true));
    // true,default string,3
    trace(myFunction(true, null));
    // true,,3
    My question is: Shouldn't I be able to call a function bypass the second argument (that has a default value), change third argument and on result second argument maintains its default value?
    Example:
    trace(myFunction(true, null, 5));
    // not desired: true,,5
    // desired: true,default string,5
    I know that applying a defult value to the argument allows one to bypass it. But it will always be redefined or to null or to undefined. At the moment I only see one solution.
    function myFunction ( arg1:Boolean, arg2:String="default string", arg3:Number=3 ):Array
         if (!arg2)arg2 = "deafult string";
         return new Array (arg1, arg2, arg3);
    It just seems like too much code repeated
    Regards

    Hi dmennenoh,
    Yup, this was just an example to show that the use of a default value only helps you to bypass the need to simulate a MouseEvent Object for an onRollOver MouseEvent argument. Other than that you can never bypass it without changing its value. You must always apply a null or undefined value and work with that.
    Thanks anyway

  • The 'argumentname' argument passed to the 'Methodename 'function is not of type 'Dto name'

    Hi, there!
    Sr for that question, because it should be pretty easy to answer, but i'm totally new to coldfusion
    and googled for about an hour now. I have a orm DTO.cfc:
    <cfcomponent entityname="testDTO" persistent="true" table="test"  schema="informix" output="false">
        <!---- properties ----> 
    </cfcomponent>
    and have a service Methode in test.cfc
        <!---- Add test---->
        <cffunction name="createTest" returntype="testDTO" access="remote">
            <cfargument name="item" type="testDTO" required="true" />
            <!---- Auto-generated method
              Insert a new record in test---->
            <cfset entitysave(item) />
            <!---- return created item ---->
            <cfreturn item/>
        </cffunction>
    i try to call via the the <cfInvoke>-Tag
    <cfset lieferant = entityNew('test')>
    <cfinvoke
        component="#request.componentbase#.test"
        method="createTest"
        item="#test#"
        returnvariable="test">
    but the error
    'The ITEM argument passed to the createLieferant function is not of type testDTO.'
    appears on function call. I just can't find a way to tell cf that lieferant is of type testDTO.
    When i type the methodes parameter to struct the methode call works well.
    Thanks for your help in advance!
    Florian

    I'm assuming your extract there isn't quite right:
    <cfset lieferant = entityNew('test')>
    <cfinvoke
        component="#request.componentbase#.test"
        method="createTest"
        item="#test#"
        returnvariable="test">
    You're doing item="#test#", surely this should be item="#lieferant#"?
    In which case, you've done  <cfset lieferant = entityNew('test')>, which is of type "test", not "testDTO"?
    If you're still having trouble, remove the item="" attribute from CFINVOKE and use CFINVOKEARGUMENTs instead.

  • New-AzureReservedIP : Cannot validate argument on parameter 'Slot'. The argument "MyIP" does not belong to the set "Staging,Production"

    I am trying to reserve an IP address in Microsoft Azure using simple PowerShell cmdlet:
    $reservedIP = "MyIP"
    $location = "West US"
    New-AzureReservedIP – ReservedIPName $reservedIP –Label $reservedIP –Location $location
    I get an error:
    New-AzureReservedIP : Cannot validate argument on parameter 'Slot'. The argument "MyIP" does not belong to the
    set "Staging,Production" specified by the ValidateSet attribute. Supply an argument that is in the set and then try
    the command again.
    Any help?
    Thanks

    Greetings!
    Please try the references below which elaborates on the usage of the cmdlet:
    New-AzureReservedIP
    https://msdn.microsoft.com/en-us/library/azure/dn690120.aspx
    https://msdn.microsoft.com/en-us/library/azure/dn769136.aspx
    Thank you,
    Arvind

  • Gamma function in formula node

    I am running LabView V.6.1 and try to use the gamma function in a formula node.
    According to the HELP text ''Formula Node and Expression Node Functions'', the syntax for the Gamma funtion is gamma(x), but this leads to the block diagram error ''Formula node: Undefined variable''.
    Other functions (like exp(x), sqrt(x) etc.) work.
    Thanks for helping.

    Hi,
    we ran into this one a little while ago. The help is a little misleading. The Gamma function actually only works with the Expression Nodes, and not the Formula nodes.
    Go to the labview help file, and search for "Differences Between the Parser in the Mathematics VIs and the Formula Node "
    Also refer to the following link for a bit more information :
    http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=50650000000800000020540000&UCATEGORY_0=_49_%24_6_&UCATEGORY_S=0&USEARCHCONTEXT_QUESTION_0=%22Square%22+function+in+formula+node&USEARCHCONTEXT_QUESTION_S=0
    it's a bit long winded, but be patient - the information is in there.
    Hope that helps
    S.
    // it takes almost no time to rate an answer

  • Sin(wt) function in formula node

    How to create a function in formula node and plot it for Vo vs t
    V = Vo * sin(wt)
    with frequency = 50Hz
    Vo = -350 to 350
    Nghtcwrlr
    ********************Kudos are alwayzz Welcome !! ******************

    Why a formula node? Just use plain LabVIEW!!!
    Your specifications seem odd and incomplete. What is the range of t you want? "Vo vs t" only makes sense if V=constant unless you want a 3D or intensity graph: V(Vo, t).
    Please clarify!
    LabVIEW Champion . Do more with less code and in less time .

  • Function arguments

    hi to there .
    is any way to get argument for onFinishTween's function   ?! ( for onComlete event )
    TweenLite.to(MC, 1.5, {alpha:1, tint:color[Math.floor(Math.random()*(color.length))],onComplete:onFinishTween});
              function onFinishTween():void {
                             //trace("The tween has finished! b-) ");
                             //reNew();
    I want to cheack every finieshfunction ;
    thanks a lot

    first, never nest named functions.  second, tweenlite has onCompleteParams property you can use:
    EF( );
    function EF( ) {
         var A:Array=randomize();
         for (var p:int =0; p<A.length; p++) {
              TweenLite.to(globalStage["square"+A[p]], 1.5, {alpha:1, tint:color[Math.floor(Math.random()*(color.length))],onComplete:onFinishTween,onCompleteParams:[p]});
              TweenMax.to(globalStage["square"+A[p]], 1.5, {glowFilter:{color:color[Math.floor(Math.random()*(color.length))], alpha:1, blurX:50, blurY:50}});
      function onFinishTween(p:int):void {
                                  //trace("The tween has finished! b-) ");
                                  /*if (i==A.length) {
                                       EF( );

  • Using a conditional staement as part of a function argument.

    I'm trying to consolidate two calls to a function down to one. I'm trying to do it by passing some sort of conditional expression as an argument equivalent to:
    get_exists_psa_req_id(
    decode(fin_sr_id, NULL,' ',' AND sched_requirement_id = '|| to_char(fin_sr_id))
    If fin_sr_id, is NULL the select statement I'm passing this to gets a blank line. If not then the additional AND phrase gets added.
    I tried that and got a message back saying that you can only use decode in a SQL query.
    What can I use or can I do anything like this?

    Use CASE instead:
    get_exists_psa_req_id (CASE fin_sr_id
    WHEN NULL  THEN ' '
    ELSE   
    Sorry Michaels
    Be care full with CASE and NULL
    Please check following posting NULL is treated differently in CASE then DECODE
    may be you have to use
    CASE  WHEN  fin_sr_id IS NULL
             THEN  ' '
    Re: Null values and Switch CASE - Conflict !!!
    Message was edited by:
    devmiral

  • Problem with function arguments

    I am having a problem with arguments to a function not
    working. In the attached example, the values passed to the function
    are never reflected within the function.
    Can any one tell me what I am doing wrong?
    Thanks,
    David

    hey drzeller,
    i just copied and pasted the original code you attached to
    this thread into flash and kglad is right. there is no problem with
    any of it. i didn't check your values before i altered your code
    originally, i just assumed they were outputting the values you
    posted. if you will copy and paste your original code back into
    flash and check the output window you will see what kglad is
    talking about.
    just so you know, all the advice i've ever seen in this forum
    from kglad has been spot on. definitely use his advice.

  • Passing array as a argument in the Stored Procedure/Function

    Hello Friends,
    I need a help, i Want one stored proedure/Function which take array as a argument and return an array also.
    and the size of array should not be fixed.
    I don't want to use Varray because for this I have to specified its size first.
    I think Associative arry will work( For dynamic size) but I am not able to run it .
    Is Associative arry(Index by Pls_Integer) support JDBC?
    If yes, plz give me some clue. I have found some information of associative array in this url
    http://www.oracle.com/technology/oramag/oracle/07-jan/o17odp.html
    But I am not able to run this package through SQL and also not able to connect it through JDBC.
    Is there any other alternative solution?
    Thanks & Regards,
    manish Kumar

    This is my table structure :
    SQL> desc jobs
    Name Null? Type
    JOB_ID      NOT NULL VARCHAR2(10)
    JOB_TITLE      NOT NULL VARCHAR2(35)
    MIN_SALARY NUMBER(6)
    MAX_SALARY NUMBER(6)
    My Requirement is, User will enter the above field value in the form of array. I need to store these value and after manupulating this I will return that value also.
    Here I am using procedure just for testing purpuse.
    In my case I will take one array argumentlike JOB_ID and after manupulating these data I will return that array value.
    I am also not able to run this example through SQL.
    Can U give me exact code for running this prog.
    create or replace package associative_array as
    -- define an associative array type for each column in the jobs table
    type t_job_id is table of jobs.job_id%type index by pls_integer;
    type t_job_title is table of jobs.job_title%type index by pls_integer;
    type t_min_salary is table of jobs.min_salary%type index by pls_integer;
    type t_max_salary is table of jobs.max_salary%type index by pls_integer;
    -- define the procedure that will perform the array insert
    procedure array_insert (p_job_id in t_job_id,
    p_job_title in t_job_title,
    p_min_salary in t_min_salary,
    p_max_salary in t_max_salary);
    end associative_array;
    create or replace package body associative_array as
    -- implement the procedure that will perform the array insert
    procedure array_insert (p_job_id in t_job_id,
    p_job_title in t_job_title,
    p_min_salary in t_min_salary,
    p_max_salary in t_max_salary) is
    begin
    forall i in p_job_id.first..p_job_id.last
    insert into jobs (job_id,
    job_title,
    min_salary,
    max_salary)
    values (p_job_id(i),
    p_job_title(i),
    p_min_salary(i),
    p_max_salary(i));
    end array_insert;
    end associative_array;
    Regards,
    manish Kumar

Maybe you are looking for