csv datasource gives error 'Failed to convert parameter value from a Object[] to a String'

4 posts, 0 answers
  1. Richard
    Richard avatar
    2 posts
    Member since:
    Mar 2018

    Posted 07 Mar 2018 Link to this post


    Currently i am working with the Telerik standalone report designer to generate a report. The report consists of a crosstab table which is populated by a stored procedure. One of the parameters for the stored procedure is a column name (string) which the user should be able to choose from a list of options.

    What i am trying to do is populate the list of column names (strings) of which the user can choose from with a csv datasource. The list is actually a TextBox for which the DataSource is set. The column names are shown, but when the Preview button is clicked on the report gives an error:

    "An error has occurred while processing Table 'table1':

    Failed to convert parameter value from a Object[] to a String.


    Object must implement IConvertible."

    Because i want to set everything in the designer itself and do not want to use c# code how can i do this?



  2. Muhammad
    Muhammad avatar
    27 posts
    Member since:
    Oct 2017

    Posted 09 Mar 2018 in reply to Richard Link to this post

    Hello Richard,

    Can you provide screenshot of the designer where you're using the fields and the what is the datatype of the column you want to display ? I'm not sure about this but isn't there any option that you could convert your column to string in the query ?
    Most of the time I follow the same approach as this is quite faster way to fix things.
  3. Richard
    Richard avatar
    2 posts
    Member since:
    Mar 2018

    Posted 09 Mar 2018 in reply to Muhammad Link to this post

    Hi Muhammad,

    One of the ReportParameters is OrderByClause. This is a string (TextBox) and suppose to display the list of strings retrieved from the csv datasource. I have created a CSV datasource using the second tab 'Enter CSV as text' and entered: Column1, Column2, Column3 etc. In the properties of the OrderByClause i have set the following value: AvailableValues.ValueMember = Fields.Column1.

    The string is displayed in the OrderByClause textbox (it has been turned into a dropdownlist) with the strings Column1, Column2 and Column3. However, when i select one of them and click Preview the error message appears.


  4. Wije
    Wije avatar
    1 posts
    Member since:
    Feb 2019

    Posted 24 May 2019 Link to this post

    Hi Richard, 

    if you are selecting multiple values from the list or drop-down.

    check your data source -->  parameters --> values.

    You may have set your data source parameter like this 

    = Parameters.SalesParameter.Value

    You might wanna join the multiple values like this.

    =Join(",", Parameters.SalesParameter.Value)



Back to Top