Using null for parameterized "newInstance(Object [])" method in Object[].

I have a really serious problem. I am creating instances of specific classes by using reflection techniques. I am reading a flat file, finding class from its name and creating it by using its parameterized constructor. Example:
line 1: Dummy("A",Dummy2("B"),12,,"C");
I create an instance of Dummy with parameters "A", an instance of Dummy2 object with value "B", 12 (I use here Integer as wrapper), null (There is no wrapper for null :( ) and "C".
I find constructor by using findConstructors() and looking their parameter counts, creating an object array with given values and calling:
constructorIFoundBefore.newInstance(objectArrayIPrepared);
But!!!
Because I use null directly, I got this message:
java.lang.IllegalArgumentException: argument type mismatch
     at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
     at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
     at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
     at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
     at reader.parser.ObjectCreator.createObjectFromObjectItem(ObjectCreator.java:192)
     at reader.parser.ObjectCreator.createObjectFromParseItem(ObjectCreator.java:112)
     at reader.parser.ObjectCreator.createObject(ObjectCreator.java:78)
     at reader.analyzer.FileAnalyzer.analyzeAndCreateObjects(FileAnalyzer.java:95)
     at reader.ReverseReader.main(ReverseReader.java:43)
I will be very glad if you help me.
Thanks a lot!
Gokcer

I said something wrong. Sorry. While invoking a method (or a constructor) we need an object array which are equivalent to parameters. For example to call a method or constructor for class A;
class A {
int age;
String name;
public A(int age, String name){
this.age = age;
this.name = name;
public set(int age, String name){
this.age = age;
this.name = name;
we use in any place
A a1 = new A(12,"Gokcer");
A a2 = new A(15,null);
To achieve this by using reflection techniques, we must find constructor with two parameters of class A. At this point "BetterMethodFinder" will give great help.
After finding right constructor, we must create an object array to tell the constructor parameters (age and name). At this point we need an object array which stores our parameters. Code must be like this.
Object []params = new Object[2]; // we have two parameters.
params[0] = new Integer(12); // we can't use params[0]=12
// because 12 is not an object. (It is a
// primitive type)
params[1] = "Gokcer";
Now create the new object.
A a1;
a1 = constructorWeFound.newInstance(params);
While creating param[], we could also use:
Object []params = new Object[2] {new Integer(12),"Gokcer"};
While creating a2, we can use "null" directly for second parameter.
params = new Object[2] = {new Integer(15), null};
or
Object []params = new Object[2];
params[0] = new Integer(15);params[1] = null;
Thanks again everyone who replied me.
My sincerely...

Similar Messages

  • How to use SPEL for Dynamic View Objects?

    Hi Gurus,
    In Benefits Self Service particularly in the Designate Beneficiaries page, we have a requirement to set the row for Self designation as Read Only. What this means for any plan that you're eligible and that requires beneficiary designation, you are not allowed to designate yourself. Unfortunately this is an intended functionality and the only way to achieve our requirement is thru Personalization. I was able to accomplish this successfuly thru the SPEL functionality. However the view object corresponding to each plan that requires beneficiary designation is somewhat dynamic. For example, Plan A corresponds to BeneficiaryPeopleVO1, Plan B corresponds to BeneficiaryPeopleVO2, Plan C corresponds to BeneficiaryPeopleVO3, etc. The Personalization Page only allows me to use the SPEL for only one view object at a time. So if an employee is eligible for 3 plans that require beneficiary designation and my SPEL points to BeneficiaryPeopleVO1, it will only set the Read Only in Plan A. Plan B and Plan C would still allow self designation. Is there a way I could use the SPEL to work for all View Objects?
    Thanks,
    Ronaldo

    jeanluca wrote:
    I've seen things like this in scripting languages, so I was wondering if things like this are possible in java. Here is an not working example:
    Is something like this possible ?AFAIK, it is only possible in a very limited way as noted above and is nearly always not recommended and definitely not necessary. The variable name has little importance, but OTOH the object reference has great importance. Instead learn about arrays, Lists, and Maps.

  • How to use %  Symbol for parameters in conditions in Discoverer

    Hi All,
    Actually I should add four parameters in that
    two param's should be given %(means to select all) as default value.
    ie as we use LIKE '%' in Query.
    the problem is when I enter a value for a parameter, it should result me for that particular value,
    and if I need all, I should enter % symbol,
    so for this Iam confused How to use this,
    even I tried with some options, it is not getting satisfactory results.
    will any one please help me in reaching this.
    Thank's in Advance
    Edited by: user10271105 on Sep 17, 2008 3:37 AM

    Hi,
    You can create a parameter and give % as the default value. If you set the condition to use LIKE then when the default value is used for the parameter then the query contains LIKE '%' and everything is selected.
    If you are using a List of Values with your parameter then you must add the '%' to your list of values so that the user can select this value.
    However, this method will not work if some of the values in your database contain percent characters, because the condition LIKE 'ABC%DEF' will return ABCXYZDEF as well as ABC%DEF.
    Unfortunately the like escape syntax is not available in Discoverer so you have to invent an value that the user can enter for all, e.g. ALL and set this as the default for the parameter.
    Then use a condition similar to:
    item LIKE :param OR item = DECODE(:param,'*ALL*', item)
    Rod West

  • Using event for communicating two object ?

    hi,
    i have two kinds of object, an producer and a consummator, i want to make them communicating with event.
    when the producer have information to send, it wrapped within an event an send it to the consummator, do you have some documentation how to do
    that, or samples
    thanks for your help

    If you are using your own event types you ould use the listener pattern. make an interface class that defines the listener type:
    public interface MyEventListener {
    public void handleEvent(MyEventType evt);
    then make the receiving class implement this inteface.
    now make the send class have methods for adding listeners:
    public class Sender {
    public void addListener(MyEventListener l) {
    //add to listener list
    public void sendEvent(MyEvent evt) {
    //loop thought listener list calling handleEvent(evt);
    }

  • Using ecat for uploading HCM objects for testing

    Hi,
    Can anybody help me out with the steps using ecat to upload the HCM objects for testing.
    I could do tcd recording and download the file.
    Regards,
    Mukta M

    Hi,
    I have been using Oracle Flashback Database for a long time in our test environments. As you already said, I recommend that you create Guaranteed Restore Points rather than rely on db_flashback_retention_target.  If you are planning to use Guaranteed Restore Points only, then you don't need to turn on flashback. If flashback database is not enabled, then the database must be mounted, not open, when creating the first guaranteed restore point (or if all previously created guaranteed restore points have been dropped).
    My Answers:
    1) I don't think so. Flashback database is faster compared to RMAN restore/recover operations.
    2) Create a backup ins not mandatory, but is a good practice.
    3) I created a Nagios plugin that take this work for me, but you can check the v$recovery_file_dest view from time to time.
    4) If you take a backup then I don't see a problem, but take care that flashback database relies not only on flashback log files but also in archive redo log files. I recommend you to delete archivelogs (from RMAN) after you drop the restore point.
    5) Flashback log files are automatically deleted after the Guaranteed restore points are deleted.
    6) Read documentation, make more tests. In 2011 I wrote an article (Brazilian Portuguese) about Flashback Database. Maybe you can take a look ;-)
    Cheers
    Legatti

  • Regarding using ranges for parameters

    Hi all,
              I have a requirement where i have to get the below using ranges.
    Can anyone help me what shuld be done.
    •     For existing program Z_AVAILABILITY, create parameter selection to run by travel dates. Must have ability to run nightly (travel date range: tomorrow’s date to 60 days later) and weekly (travel date range: 61days after of tomorrow to 6 month after of today’s date). 
    eventual i have to use this in select statement.
    Frnds plzz help me its urgent.
    regards,
    satish

    Hi,,
    first declare ranges like this
    ranges:
      r_tdlnr for lfa1-lifnr,              " Forwarding agent number
      r_scacd for lfa1-scacd.              " Standard carrier access code.
    after that assisgn values into it like this 
    move: 'I'  to r_tdlnr-sign,
            'EQ' to r_tdlnr-option,
            t_lfa1-lifnr to r_tdlnr-low.
    and finally write select statement like this..
    select vttk~tknum                    " Shipment number
             vttk~tpbez                    " Transport description
             vttk~tdlnr                    " Forwarding agent number
             vttp~tpnum                    " Shipment line item
             vttp~vbeln                    " Delivery number
            vttp~zseq_num                 " Delivery stage sequence number
        into table t_vttk_vttp
        from vttk inner join vttp
          on vttptknum eq vttktknum
         for all entries in t_lips_vbak    " for all deliveries
       where vttk~tdlnr in r_tdlnr         " with valid forwarding agents
    plzz reward if it is usefull to u...

  • Using sprite for itemRenderer what other method than set data needs override

    I get the following error: 1020 Method Marked override must override another method. Complier marks the error at the start of my set data method:
    code is here:
    http://pastie.org/497786
    any input would be welcome.
    Thanks
    Jed

    I think Natasha said that you don't need the override on your set data() method.  You shouldn't need to implement IFactory either.  I think your code should look like this:
    <?xml version="1.0" encoding="utf-8"?>
    <mx:UIComponent
         xmlns:mx="http://www.adobe.com/2006/mxml"
         width="160"
         height="120"
         implements="mx.controls.listClasses.IListItemRenderer"
         >
         <mx:Style source="QtVideo.css"/>
         <mx:Script>
              <![CDATA[
                   private var repImageSource:String = "";
                   private var movieSource:String = "";
                   private var _data:Object;
                   public function get data():Object
                        return _data;
    setting data
                   public function set data(value:Object):void
                        _data = value;
                        repImageSource = value.representativeImage as String;
                        movieSource = value.source as String;
              ]]>
         </mx:Script>
         <mx:Image
              id="repImage"
              width="160"
              height="120"
              source = ""
              horizontalAlign="center"
              x="0"
              y="0"
              >     
         </mx:Image>
         <mx:Button styleName="playStopStyle"
              id="playBtn"
              x="{repImage.width/2 - 22.5}"
              y="{repImage.height/2 -22.5}"
              />
    </mx:UIComponent >
    Alex Harui
    Flex SDK Developer
    Adobe Systems Inc.
    Blog: http://blogs.adobe.com/aharui

  • String contains class name: how to use it for creating new objects

    Hi All
    I've seen things like this in scripting languages, so I was wondering if things like this are possible in java. Here is an not working example:
    String s = "MyClass" ;
    MyClass mc = new s() ; // or: s mc = new s() ;
    if ( mc instanceof s ) { ..... }
    Is something like this possible ?
    Thnx in advance
    LuCa

    jeanluca wrote:
    I've seen things like this in scripting languages, so I was wondering if things like this are possible in java. Here is an not working example:
    Is something like this possible ?AFAIK, it is only possible in a very limited way as noted above and is nearly always not recommended and definitely not necessary. The variable name has little importance, but OTOH the object reference has great importance. Instead learn about arrays, Lists, and Maps.

  • Why "null" value is impossible in "switch(val) {case null: }"  for enums?

    I'm wondering why Java 5.0 does not allow null values
    as options in switch statement:
    If type E is "enum" then the following language construction is
    not allowed:
    E val;
    switch(val) {
       case A:
         break;
       case B:
           break;
       case null:   // this is not allowed
            break;
    }Can somebody explain me why Java does not support it? I beleave that
    some serious reasons were for that.
    As we know enum types can have "null" values and in case I use nulls
    for my enumerations the code with "switch" statement becomes quite urgly because it is necessary to handle 2 separate execution paths:
    null and not null.
    Thanks

    I really don�t know too much about 1.5, but I can tell you that for 1.4 the switch receives as a parameter an int or anything that can be casted automatically to an int. Therefore you can�t never use null cause int, char, short, byte can�t never take as a value null.

  • I'm using Siebel 7 eBusiness app for doing SRs on Win7, IE8 and I could no longer navigate back and forth. I got navigator.SWE_historyKeys.1378453334294' is null or not an object. Does anyone know how to solve this problem?

    I'm using Siebel 7 eBusiness app for doing SRs on Win7, IE8 and I could no longer navigate back and forth. I got navigator.SWE_historyKeys.1378453334294' is null or not an object. Does anyone know how to solve this problem?

    Looks like you have to upgrade to at least 7.8.2.16.
    See the Release Notes of 7.8.2.16 and search for "SWE_historyKeys".
    Maintenance Release Guide, Siebel CRM version 7.8 (Doc ID 560646.1)

  • Dump - Access using NULL object reference is not possible!!!

    Hi,
    I'm using the BCS class for sending HTM format email so i use the below code for that its working,
    DATA: gr_document      TYPE REF TO cl_document_bcs,
    gr_document = cl_document_bcs=>create_document(
                          i_type    = 'HTM'
                           i_text    = t_html
                           i_importance = '5'
                           i_subject = gc_subject ).
    Next task is to send the image so i'm creating an another object to the same class, below code
    *Image from MIME
    DATA: o_mr_api         TYPE REF TO if_mr_api.
    DATA is_folder TYPE boole_d.
    DATA l_img1 TYPE xstring.
    DATA l_img2 TYPE xstring.
    DATA l_loio TYPE skwf_io.
    DATA: lo_document   TYPE REF TO cl_document_bcs.
    IF o_mr_api IS INITIAL.
       o_mr_api = cl_mime_repository_api=>if_mr_api~get_api( ).
    ENDIF.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/tick.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img1
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/Delete.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img2
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    *Convert XSTRING to ITAB
    DATA :lt_hex1 TYPE solix_tab,
           lt_hex2 TYPE solix_tab,
           ls_hex LIKE LINE OF lt_hex1,
           lv_img1_size TYPE sood-objlen,
           lv_img2_size TYPE sood-objlen.
    CLEAR : lt_hex1, lt_hex2, ls_hex, lv_img1_size, lv_img2_size.
    WHILE l_img1 IS NOT INITIAL.
       ls_hex-line = l_img1.
       APPEND ls_hex TO lt_hex1.
       SHIFT l_img1 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    WHILE l_img2 IS NOT INITIAL.
       ls_hex-line = l_img2.
       APPEND ls_hex TO lt_hex2.
       SHIFT l_img2 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    *Findthe Size of the image
    DESCRIBE TABLE lt_hex1 LINES lv_img1_size.
    DESCRIBE TABLE lt_hex2 LINES lv_img2_size.
    lv_img1_size = lv_img1_size * 255.
    lv_img2_size = lv_img2_size * 255.
    *Attach Images
    clear: lo_document.
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img1'                " Attachment Title
         i_attachment_size     =  lv_img1_size           " Size of Document Content
         i_att_content_hex     =  lt_hex1  " Content (Binary)
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img2'                " Attachment Title
         i_attachment_size     =  lv_img2_size           " Size of Document Content
         i_att_content_hex     =  lt_hex2  " Content (Binary)
    but it throws the dump " Access using NULL object reference is not possible"  when i tries to access for method add_attachment...
    Thanks,
    Siva

    Yes there is commit work after that, Below code
          gr_document = cl_document_bcs=>create_document(
                           i_type    = 'HTM'
                            i_text    = t_html
                            i_importance = '5'
                            i_subject = gc_subject ).
    *Image from MIME
    DATA: o_mr_api         TYPE REF TO if_mr_api.
    DATA is_folder TYPE boole_d.
    DATA l_img1 TYPE xstring.
    DATA l_img2 TYPE xstring.
    DATA l_loio TYPE skwf_io.
    DATA: lo_document   TYPE REF TO cl_document_bcs.
    IF o_mr_api IS INITIAL.
       o_mr_api = cl_mime_repository_api=>if_mr_api~get_api( ).
    ENDIF.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/tick.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img1
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    CALL METHOD o_mr_api->get
       EXPORTING
         i_url              = '/SAP/PUBLIC/ZDEMO/Delete.png'
       IMPORTING
         e_is_folder        = is_folder
         e_content          = l_img2
         e_loio             = l_loio
       EXCEPTIONS
         parameter_missing  = 1
         error_occured      = 2
         not_found          = 3
         permission_failure = 4
         OTHERS             = 5.
    *Convert XSTRING to ITAB
    DATA :lt_hex1 TYPE solix_tab,
           lt_hex2 TYPE solix_tab,
           ls_hex LIKE LINE OF lt_hex1,
           lv_img1_size TYPE sood-objlen,
           lv_img2_size TYPE sood-objlen.
    CLEAR : lt_hex1, lt_hex2, ls_hex, lv_img1_size, lv_img2_size.
    WHILE l_img1 IS NOT INITIAL.
       ls_hex-line = l_img1.
       APPEND ls_hex TO lt_hex1.
       SHIFT l_img1 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    WHILE l_img2 IS NOT INITIAL.
       ls_hex-line = l_img2.
       APPEND ls_hex TO lt_hex2.
       SHIFT l_img2 LEFT BY 255 PLACES IN BYTE MODE.
    ENDWHILE.
    *Findthe Size of the image
    DESCRIBE TABLE lt_hex1 LINES lv_img1_size.
    DESCRIBE TABLE lt_hex2 LINES lv_img2_size.
    lv_img1_size = lv_img1_size * 255.
    lv_img2_size = lv_img2_size * 255.
    *Attach Images
    create object lo_document type cl_document_bcs.
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img1'                " Attachment Title
         i_attachment_size     =  lv_img1_size           " Size of Document Content
         i_att_content_hex     =  lt_hex1  " Content (Binary)
    lo_document->add_attachment(
       EXPORTING
         i_attachment_type     =  'png'                  " Document Class for Attachment
         i_attachment_subject  =  'img2'                " Attachment Title
         i_attachment_size     =  lv_img2_size           " Size of Document Content
         i_att_content_hex     =  lt_hex2  " Content (Binary)
           "Add document to send request
           CALL METHOD gr_send_request->set_document( gr_document ).
           TRY.
             CALL METHOD gr_send_request->SET_SEND_IMMEDIATELY
               EXPORTING
                 I_SEND_IMMEDIATELY = 'X'.
    *    CATCH CX_SEND_REQ_BCS INTO BCS_EXCEPTION .
    **Catch exception here
           ENDTRY.
           DATA: LO_SENDER TYPE REF TO IF_SENDER_BCS VALUE IS INITIAL.
           TRY.
             LO_SENDER = CL_SAPUSER_BCS=>CREATE( SY-UNAME ). "sender is the logged in user
    * Set sender to send request
             gr_send_request->SET_SENDER(
             EXPORTING
             I_SENDER = LO_SENDER ).
    *    CATCH CX_ADDRESS_BCS.
    ****Catch exception here
           ENDTRY.
           "Send email
           CALL METHOD gr_send_request->send(
             EXPORTING
               i_with_error_screen = 'X'
             RECEIVING
               result              = gv_sent_to_all ).
           IF gv_sent_to_all = 'X'.
             WRITE 'Email sent!'.
           ENDIF.
           "Commit to send email
           COMMIT WORK.
           "Exception handling
         CATCH cx_bcs INTO gr_bcs_exception.
           WRITE:
             'Error!',
             'Error type:',
             gr_bcs_exception->error_type.
       ENDTRY.

  • RFC to HTTP Interface - Access using NULL object reference is not possible

    Hi All,
    I am working on a Interface RFC to HTTP where in I am sending the data to a third party system.
    Using PI 7.3 and Adapter type XI to send this data.
    I am getitng an error Short dump occured when executing message in qRFC queue <Queuename>: Date/time 02.12.2011 08:44:57, user XXXXX, runtime error: Access using NULL object reference is not possible.
    <SAP:Code area="INTERNAL">QRFC_SYSTEM_DUMP</SAP:Code>
    I am entering the parameters such as target host,service number,path correctly with addrseing type as URL.
    The message is failing in the call adapter step with the above error.
    There are no messages stuck in SMQ2 as well.
    Now on the other if I use the  adapter type HTTP_AAE the messages is getting successfully delivered with the same parameters mentioned above.But as we know it is a plain adapter and will not have the SOAP envelope.
    We would want to send the data using the XI adapter.
    Any idea as why this issue is happening?
    Helpful answers will be rewarded points.
    Thanks & Regards,
    RK

    Hi,
    please go through below threads,
    Error for all the interfaces
    Access via NULL object reference not possible., error key: RFC_ERROR_SYSTEM
    hope it will help you
    regards,
    ganesh

  • Using a Variable in SSIS - Error - "Command text was not set for the command object.".

    Hi All,
    I am using a OLE DB Source in my dataflow component and want to select SQL Query from the master table  I have created variables v_Archivequery
    String packageLevel (to store the query).
    <Variable Name="V_Archivequery" DataType="String">
         SELECT a.*, b.BBxKey as Archive_BBxKey, b.RowChecksum as Archive_RowChecksum
         FROM dbo.ImportBBxFbcci a LEFT OUTER JOIN Archive.dbo.ArchiveBBxFbcci b
         ON (SUBSTRING(a.Col001,1,4) + SUBSTRING(a.Col002,1,10)) = b.BBxKey
         Where (b.LatestVersion = 1 OR b.LatestVersion IS NULL)
        </Variable>
    I am assigning this query to the v_Archivequery variable, "SELECT a.*, b.BBxKey as Archive_BBxKey, b.RowChecksum as Archive_RowChecksum
    FROM dbo.ImportBBxFbcci a LEFT OUTER JOIN Archive.dbo.ArchiveBBxFbcci b
     ON (SUBSTRING(a.Col001,1,4) + SUBSTRING(a.Col002,1,10)) = b.BBxKey
    Where (b.LatestVersion = 1 OR b.LatestVersion IS NULL)"
    Now in the OLE Db source, I have selected as Sql Command from Variable, and I am getting the variable, v_Archivequery .
    But when I am generating the package and when running I am getting bewlo errror
     Error at Data Flow Task [OLE DB Source [1]]: An OLE DB error has occurred. Error code: 0x80040E0C.
    An OLE DB record is available.  Source: "Microsoft SQL Native Client"  Hresult: 0x80040E0C  Description: "Command text was not set for the command object.".
    Can Someone guide me whr am going wrong?
    Please let me know where am going wrong?
    Thanks in advance.
    Thankx & regards, Vipin jha MCP

    What happens if you hit Preview button in OLE DB Source Editor? Also you can use the same query by selecting SQL Command option and test.
    Could you try set the Delay Validation = True at Package and re-run ?
    If set the query in variable expression (not in value), then Set Evaluate As Expression = True.
    -Vaibhav Chaudhari

  • Using NULL in Condition Object

    Is there are way to use the value NULL in the Condition object. For example, the following does not work because I really need "U_PLS_SysU IS NULL" for my query to work:
    conditions = new SAPbouiCOM.Conditions();
    condition = conditions.Add();
    condition.Alias = "U_PLS_SysU";
    condition.Operation = SAPbouiCOM.BoConditionOperation.co_EQUAL;
    condition.CondVal = "NULL";
    This statement gets interpreted literally of course and does not return the correct rows. Is there a workaround?
    Thanks

    It´s just a guess, but... have you tried something like an SQL injection?
    Some trick like:
    conditions = new SAPbouiCOM.Conditions();
    condition = conditions.Add();
    condition.Alias = "U_PLS_SysU";
    condition.Operation = SAPbouiCOM.BoConditionOperation.co_EQUAL;
    condition.CondVal = "   '' OR U_PLS_SysU IS NULL";
    //There are 2 single quotes begore OR word
    If it was well designed it shouldn´t work, but you never know...
    Regards,
    Ibai Peñ

  • Can a web service be used as the datasource for a View Object?

    Has anyone used a web service as the datasource for a View Object?
    I am trying to do the same thing as "Publishing BC4J Components as a Web Service" example, except I want to recreate the View Objects on the client so that I can iterate through them and display them on a web page.
    I probably have two choices:
    1. Use the web service as the datasource.
    2. Use a file as the datasource with no data and then populate the View Objects from the XML from the Web Service.
    Please advise.
    Thank you.
    Richard Catlin
    SAIC

    You can adapt the examples provided in the BC4J Toy Store demo for how to build a programmatically-populated view object to create a view object that fetches its data from a web service.
    The methods that you need to override are the same for any kind of programmatically-populated view object.

Maybe you are looking for