Cannot create an object of type 'System.String[]' from its representation 'String[] Array'

Discussion in 'ASP .Net' started by Hessam, Aug 8, 2003.

  1. Hessam

    Hessam Guest

    I am designing a .net custom control in 7.1 and my control exposes an
    array of strings which are supposed to be the items to show. To do this have
    declared a private string[ ] variable and a public property which returns
    string[] options = new string[1];

    public string[] Options




    return options;




    options = value;



    It works fine in the disigner and I can add items to the list using the string collection editor and see the changes in real-time. But when I
    run the App, I recieve this error:

    Cannot create an object of type 'System.String[]' from its string
    representation 'String[] Array' for the 'Options' property.

    Even with other types of collections (objects, etc.), I receive this error.
    What should I do.
    Hessam, Aug 8, 2003
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.