Dynamic parameter list in a webservice MXML request

Hello,
I'd like to dynamically generate the request parameter of a
web service like that :
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
layout="absolute">
<mx:WebService id="pegasus"
wsdl="
http://myservice?wsdl"
useProxy="false"
load="headers();">
<mx:operation name=" myOperation
">
<mx:request>
<arg0>
<parameter1>{parameter1Input.text}</parameter1>
<parameter2>{parameter2Input.text}</parameter2>
<listParameter3>
<element1>????</element1>
<element1>????</element1>
<element1>????</element1>
<element1>????</element1>
</listParameter3>
</arg0>
</mx:request>
</mx:operation>
</mx:WebService>
So I'd like to know how to generate the list, with an unknown
number of elements, from a datagrid for example.
I tried to generate a XML from a variable like that :
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
layout="absolute">
<mx:WebService id="pegasus"
wsdl="
http://myservice?wsdl"
useProxy="false">
<mx:operation
name="myOperation">
<mx:request>
<arg0>
<parameter1>{parameter1Input.text}</parameter1>
<parameter2>{parameter2Input.text}</parameter2>
<listParameter3>
{myList}
</listParameter3>
</arg0>
</mx:request>
</mx:operation>
</mx:WebService>
<mx:Script>
<![CDATA[
public var myList:XML;
public function essai():XML {
// call this function before send
// populate myList from formulary
]]>
</mx:Script>
But it didn't work, can you help me ?

This current problem with the forum makes code almost
impossible to read. Hope they fix it soon.
You can build the request object in AS code. Use mxml to
declare the webservice. Then in a function do something like this
example:
//Sets up and invokes werservice call
private function getEmployees():Void
var sOperationName:String = "getList";
//Put the operation name in a var
var oRequest:Object = employeeWS[sOperationName].request;
//get a reference to the operations request object
oRequest.deptId = dept.selectedItem.data; //put the deptId
Name/Value pair in the request
var call = employeeWS[sOperationName].send(); /Invoke the
call
Tracy

Similar Messages

  • Report Viewer Dynamic Parameter List not showing a complete list of values

    Hi, I have installed the crystal report runtime 13.0.1.220 for framework 4.0 in a 64-bit windows 7 professional server.
    I have an aplication that opens crystal reports using the crystal report viewer control for visual studio 2010, also version 13.0.1.220.
    ISSUE: The report opens fine, but it does not shows all the available values in the dynamic parameter list.
    I have tried setting the MaxRowsetRecords registry key to diferent values but it does not work.
    I do not have any crystal report stand alone version installed in my server.
    Please help me?

    Hi Ludek,
    yes i followed the instructions of the KBase you are mentioning, but it isn't working for me.
    I modified the following keys:
    HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework4.0\Crystal Reports\DatabaseOptions\LOV
    and
    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework4.0\Crystal Reports\DatabaseOptions\LOV
    1) I had to create the LOV key under the DatabaseOptions in both keys.
    2) Inside the LOV keys I created the new string value MaxRowsetRecords and set the value to different values. (Ex: 5000, 10000 and 1000000)
    3) I restarted my server. Still not working.
    4) Then after that i modified the following registry keys: (leaving the first 2 keys modified)
    HKEY_CURRENT_USER\Software\SAP BusinessObjects\Crystal Reports for .NET Framework4.0\Crystal Reports\DatabaseOptions\LOV
    and
    HKEY_CURRENT_USER\Software\SAP BusinessObjects\Crystal Reports for .NET Framework4.0\Crystal Reports Designer Component\DatabaseOptions\LOV
    5) Also had to create the LOV key under the DatabaseOptions in both keys.
    6) Inside the LOV keys I created the new string value MaxRowsetRecords and set the value to different values. (Ex: 5000, 10000 and 1000000)
    7) Restarted my server. still not working
    8)  Then after that i modified the following registry key: (leaving the first 4 keys modified)
    HKEY_CURRENT_USER\Software\SAP BusinessObjects\Crystal Reports for .NET Framework4.0\Crystal Reports Designer Component\ReportView
    Inside this key I created the DWORD PromptingLOVBatchSize and gave it a decimal value of 1000000
    9) Restarted the server. Still not working. For crying out LOUD!!

  • IMPORT from database with dynamic parameter list

    Hi Gurus,
    Iu2019m having problems during import from a cluster table.
    I wanu2019t to do an import with a dynamic parameter list, but I cannot get it to work.
    Sample code ********
    DATA: BEGIN OF st_key,
    report LIKE rsvar-report,
    variant LIKE rsvar-variant,
    END OF st_key.
    DATA dirtab1 LIKE cdir OCCURS 10 WITH HEADER LINE.
    DATA dirtab2 LIKE cdir OCCURS 10 WITH HEADER LINE.
    st_key-report = 'ZPRG'.
    st_key-variant = 'VAR1'.
    IMPORT DIRECTORY INTO dirtab1 FROM DATABASE vari(vb) ID st_key.
    IMPORT DIRECTORY INTO dirtab2 FROM DATABASE vari(va) ID st_key.
    DATA: tmp_var(100)   TYPE c.
    This works - P_BWTAR is a parameter from the selection screen registred in VARI
    I'm getting the content of the field in tmp_var
    IMPORT p_bwtar TO tmp_var FROM DATABASE vari(va) ID st_key.
    This does not work - the parameter P_BWTAR is in the dirtab2-name
    I'm not getting the content
    LOOP AT dirtab2.
        IMPORT dirtab2-name FROM DATABASE vari(va) ID st_key.
      ENDIF.
    ENDLOOP.
    I have tried the syntax IMPORT (dirtab2-name) ........
    but this fails the syntax check.
    Please - if you have any suggestions  :o)
    Best Regards,
    Vibeke

    Dear Vibeke,
    Could you please explain us how you solved the problem because you have the same issue ?
    thanks a lot
    KR
    véronique

  • What is the maximum number of records in a dynamic parameter list of values?

    In Crystal Reports Developer, I am attempting to add a dynamic parameter from a view.  The view has 6773 total records.  The field used for the parameter has 1819 distinct values, none of which are null.
    I have the parameter set to allow multiple values, and I have added
    field is equal to parameter
    in the select expert.
    However, when I refresh the report and tell it to prompt for new parameters, the list of values does not contain all the values, so about half of the records are dropped.
    Is there a way I can guarantee that all 1819 (or an unlimited number) records show up in the List of Values?

    This has been answered. Search forums for the results

  • Dynamic Parameter List questions: Length and Custom Values

    I've got a Crystal Report that I want to use Dynamic Values for.
    Right now... this report is simply a "SELECT stuff  FROM table" SQL query... with a parameter that the report uses to filter.
    I use a "Select DISTINCT value from table" to generate a list of values. I put those values into a txt. I then import the text into a static list. This creates a parameter list that is 11 "pages" long on the parameter screen. I also have "custom" values allowed. This is to allow for "new" values and also allow not needing to browse 11 pages for one or two known values.
    If I turn the parameter into a Dynamic List based on the same Select statement it stops at 5 pages, obviously cutting off half of the possible values.
    Dynamic List also removes the ability to do Custom Values. The filter option wouldn't be a bad alternative BUT it don't work for pages 6+ that aren't there.
    How can I remove the 5 page limit (or whatever it is) for Dynamic values?
    Thanks
    Chris
    Edited by: WernerCD on Aug 4, 2010 4:14 PM

    There is a limit of 1000 records in dynamic parameters. You can change this by adding a registry value:
    registry key : HKEY_CURRENT_USER\SOFTWARE\Business Objects\Suite 11.0\Crystal Reports\DatabaseOptions\LOV
    and then add a key called MaxRowsetRecords and give it a value.
    if you have Crystal 2008 then the above registry folder will say Suite 12.0.

  • Dynamic Parameter List works on desktop but not when run on Crystal Server

    Hi,
    I have a report, and the database command query takes one parameter ({?Year}. There is a second parameter used for a record select which is a dynamic paramenter list (multiple select, required). When running the report from Crystal Reports 2008 on my desktop, it first prompts for a year, and then once that is entered, it will come back with the list (of Companies) to select from. It works very smootly and as desired.
    But when I load this report to Crystal Reports 2008 Server, it will ask for the year (which is a static list), and this is good, but then it comes back with an empty dynamic select list on the next screen.
    Are there any special caveats that I need to be aware of in regards to dynamic lists when running from the CR server?
    Thanks!

    Hi Pat, 
    This should work but a couple of things to check: 
    1)  Are the two parameters linked to the same database?  If the parameters are linked to fields from different tables in different databases then you need to make sure you set the Database Configuration and have the report log on to both databases. 
    2)  Are Crystal Reports and Crystal Server the same version?  I had problems with parameters after we upgraded to 2008.  We had to install the latest service packs for both Crystal 2008 and the Enterprise Server.  Then we installed Crystal 2008 on the same machine the Enterprise Server was on.  Crystal Reports and the Enterprise Server share some common files.  Some of those files were updated for Crystal but not for the Enterprise Server yet.  Once we synched them our reports have run fine. 
    Good luck,
    Brian

  • Limit dynamic parameter list to data added in last month

    I have a crystal reports X1 report that uses a dynamic parameter for users to select. This parameter displays all database entries for the field. The field is called PLANNAME and lists out names that users have entered from the main application screens. I want to limit the display of these plan names to the most recent based on the CREATEDATE which is a field on the table that the Planname is stored.
    Is there a way that Crystal reports can restrict / limit the list of vaules returned and available for report users to select. The list is steadily growing, and now requires the report users to scroll through hundreds of plannames (that is, all the plan names that have been created over the last two years).
    Look forward to any suggestions.
    Regards
    dave

    Just a follow-up on progress ...... which has been a bit slow.
    Have got into the Business View Manager and found the vaious parameter levels PLANNAME DC, PLANNAME_BE, PLANNAME_BV, PLANNAME_DF, and added the following filter to the data_foundation: (note: first part is a View I have created, )
    {CRYSTALVW_EFTPLANDETAIL.PLANNAME} in LastFullMonth.
    I have not been able to add the SQL expression as it errors with reference to the INCORRECT SYNTAX NEAR THE KEYWORD "select"
    SELECT DISTINCT PLANNAME, DATECREATED FROM CRYSTALVW_EFTPLANDETAIL WHERE DATECREATED >= '2009-01-01'
    Note, this works okat in Enterprise manager Query Analyser, but not in the DF data_foundation.
    and the suggestion you made:
    SELECT DISTINCT PLANNAME FROM CRYSTALVW_EFTPLANDETAIL WHERE DATECREATED >= DATEADD('m',-1,GETDATE())
    This produces the same error message - INCORRECT SYNTAX NEAR THE KEYWORD "select"
    and I can not get this to work in Query Analyser - error message is
    Server: Msg 1023, Level 15, State 1, Line 2
    Invalid parameter 1 specified for dateadd.
    I shall continue to work thru this, but would appreciate any helpful hints.
    many thanks
    Dave

  • Dynamic parameter list condition question.

    CR2008
    Let say I have a dynamic parameter based on EmployeeName field in Employee table. How can I limit a parameter drop down list only to employees from one specific department? I do not want to select department first, I want to "hardcode" it somehow. It seems that parameter setup window does not  have any search criteria.
    Thanks,
    Oleg

    Try to put the filter condition in business view manager. Once you publish the report to server by default it generates an LOV in repository. Now open the business view manger and select the LOV and click on the object definition icon to see related business view and data foundation. Now open the data foundation and in the field explorer try to insert a new filter and add the condition like ="department name" and apply this and save the datafoundation. Now right click on the filter edit rights and apply this to all the user groups. Now when you open the report and refresh the report you will be able to see only the list related to the department.
    Regards,
    Raghavendra.G

  • Dynamically add some elements in WebService operation request

    Hi, 
    I have a WebService element defined in my mxml which use to make soap calls. 
    I need to dynamically add some repeating groups for action (dependent on action) in the following example. 
    How can I add this in Action Script section? Can I access the WebService  by id userRequest and specify " 
    userRequest.operations.DoAction.request.DoItemActionRequest.action.requiresAdditionItems.n ameValuePair.name = "SomeName"; 
    userRequest.operations.DoAction.request.DoItemActionRequest.action.requiresAdditionItems.n ameValuePair.name = "SomeValue";  
    <mx:WebService  id="userRequest" wsdl="{Application.application.wsdl}" > 
         <mx:operation name="DoAction" resultFormat="object" 
          fault="faultHandler(event)" 
          result="DoActionHandler(evnt)">
            <mx:request> 
              <DoActionRequest> 
                 <userId>{Application.application.userID}</userId> 
                  <action> 
                     <actionId>{selectedItem.actionId}</actionId> 
                 </action> 
              </DoActionRequest> 
             </mx:request> 
           </mx:operation> 
    </mx:WebService>
    Thanks,
    Amitava

    Hi miguel8312,
    Thanks for your suggestion. I understand the steps you explained for defining, calling and processing the result from a webservice from a MXML body.
    My query is specifically, can I modify the webservice request defination from AS function before making the call?
    In my example, if I need to dynamically add a name value pair for <action> tag (e.g. actionParam ), how do I do that?
    Thanks,
    Amitava

  • Dynamic parameter list values

    Hi all,
    I'm new with Crystal Report, and I have a problem.
    The goal is to create a Price List based on SAP conditions tables.
    So, In my report I have linked table  Axxx KONP KNA1 MAKT  MVKE T179T  TINCT TVSBT.
    All work find except for the customer parameter selection.
    I want create a dynamic list with Customer Number and description (but only those which exist in table Axxx)
    I can create a dynamic list based on KUNAG and KUNWE from table Axxx(master table), but I have only the Number  of customer and no description (because description don't exist in Axxx table)
    I have try to select NAME1 form KNA1 table, but without success.
    I have search in SAP about a table which contain Number, Name1 and Parvw(partner role) but without succes.(table KNVP don't have Name1)
    I have try to create list value from KNA1 but whe have much more customer and the list is > then 1000 occurence(too big!)
    Do someone have an idea to create a dynamic list which take his information from two tables linked ?
    Or another solution to reach the goal...:)
    Thank in advance for your suggestion,
    Regards
    Martine Bombardelli

    Your requirement for me looks like a straight forward task.
    If you need a DP on 2 fields from 2 different tables in SAP using Integration Kit all you need to do is:
    > create a new parameter in the report
    > select 'Dynamic' from the List of Values drop down. Your options in the Parameter window will change for dynamic compared to static.
    > Choose Data Source: New
    > Below 'Value' select table1.Customer number and next to it under 'Description' select the table2.Description and set the further options you require under the Value options.
    Just as an FYI...there is no option to have a custom SQL when working with SAP Intg Kits. Business View Manager is also not helpful.
    So if a dynamic prompt is needed for a Crystal report above are steps it can be achieved, no other option is available today.
    Thanks,
    Madhu

  • Dynamic parameter list?

    id like a method that will be able to have any number of parameters when called ( -> methodName( int a, int b, int c ....) )
    is this possible?

    [http://java.sun.com/j2se/1.5.0/docs/guide/language/varargs.html]

  • How can we use C# to read dynamic parameter's value list from .rpt?

    I'm using Cystal Report 2008. We know starting from CR XI we can create dynamic parameters, the list of items of this kind of parameter are fetching from database. So in general the SQLs to get the list of values for dynamic parameters are stored in the .rpt.
    In Crystal Report Designer, if I preview a report with dynamic parameters, it will first query the database and then show the input dialog with list of values from database for user to choose. My question is can we implement the same thing by our C# code? I'm planning to use C# code to read this dynamic parameter's value list from .rpt and render them on the web page. Then pass back the user selected values to the .rpt to run the report after user make the choice. I didn't find any APIs can do this. Is it possible?
    Thanks in advance!!

    Hi,
    Can you explain a bit in detail, I have similar scenario. I am using the following code but not getting the Column name for dynamic parameter list.
    foreach (ParameterFieldDefinition prm
                              in reportDocument.DataDefinition.ParameterFields)
                    try
                        string vParameterFieldName;                   
                        *vParameterFieldName = prm.ParameterFieldName.ToString();*
    Shakeel

  • CR 2008, all values in parameter list not showing up

    The parameter is not optional, the parameter value exists in the view on SQL server, but at report run-time, only get 5 pages of possible values to select from and user needs to go back farther to get the required report.
    I can get the report to run in full CR version by passing the value into the select expert, but users only get prompt window from the runtime version of CR.
    How can I get ALL the values of the field in the view to show up in parameter list?
    Thanks for any pointers.
    Robert

    Not sure if the help you metion is equivalnet to KB [1218588 - How to increase the number of values in a dynamic parameter list?|http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_bi/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes%7B6163636573733d36393736354636443646363436353344333933393338323636393736354637333631373036453646373436353733354636453735364436323635373233443330333033303331333233313338333533383338%7D.do], but have a look.
    Also, make sure you are on SP3:
    https://smpdl.sap-ag.de/~sapidp/012002523100007123572010E/cr2008_sp3.exe
    Ludek
    Follow us on Twitter http://twitter.com/SAPCRNetSup
    Got Enhancement ideas? Try the [SAP Idea Place|https://ideas.sap.com/community/products_and_solutions/crystalreports]

  • Dynamic Parameter Record Limit

    I am using Crystal 2008 with universes as a data source with BOE XI 3.0 (Edge) Infoview and need to create parameter fields that return greater than 1,000 records.  I have seen suggestions about modifying the local workstation registry, and also found a reference to an earlier version of BOE (SAP Note 1199759) about modifying the LOV batch size for custom sorting.  The latter refers to a Web Intelligence setting, so I'm not sure if it affects parameters in Crystal Reports.
    Which is the correct method to resolve this issue my versions of Crystal and BOE?

    Hi
    we need to make changes for CR so that it fetches more than 1000 records.
    Please refer to 1218588 - How to increase the number of values in a dynamic parameter list and make the necessary registry changes.
    Hope this helps!!
    Regards
    Sourashree

  • Uploading reports that use dynamic parameter values

    Post Author: singhal
    CA Forum: Deployment
    Hi,
    I am having difficulty using Crystal Reports Server XI to deploy reports that were made in Crystal Reports XI.
    When I create a report that uses a dynamic parameter listing, I get the follow error when I try to install it onto the server:
    Failed to read data from report file C:\WINDOWS\Temp\myreport.rpt. Reason: Failed to read parameter object
    But if I were to use a static parameter listing, the server will load up the report just fine.  Can you please tell me what I am doing wrong and I need to do to fix the problem.  As many details as possible would be helpful.
    Thanks,
    Back

    Post Author: TAZ
    CA Forum: Deployment
    Does the issue happen with the built in administrator account? I believe this is a permissions issue and the permissions need to be set in business views.
    Regards,
    Tim

Maybe you are looking for

  • XMLTYPE variable converting to XML (Question)

    Friends, I am stuck on an error and cannot find a way out. Please help. I know it's a long question but a very simple answer to many smart people here. I am just lost and need your help. (I am new to SOA so bear with me) I have a BPEL process which i

  • How to use connection pooling in JDev 10.1.2

    In all the ADF apps I have created, I have always used the defined connection in JDev and deployed the password. I'm now being told I need to stop doing that and start using oc4j connection pool with datasource definition so the passwords won't have

  • Put region in header?

    I have an application. It works fine. I am using 2-level tabs. The parent tabs are right-justified and I would like to put a small region left-justified on the same line. Specifically I want to do a query of a table to get the date of the last update

  • Strange scrollpane behavior

    Hi, I have a A.swf, B.swf and C.swf. B.swf is loaded into A.swf and it has a scrollpane, into which C.swf is loaded. When I test B.swf, everything works fine, but when I run A.swf, into scrollpane (B.swf) is loaded B.swf and into that scrollpane is l

  • Why do my ringtones keep going back to default i have an iphone 5s and it's really annoying me now

    Why do my ringtones keek going back to default they work for a day then go if this is really annoying me so any help would be welcome if anybody else us having this problem