Unable to set the number of rows in a Multiline TextBox

Hello,

I am trying to set the html attribute "rows" to a multiline textbox but this is not working. Here is the sample code i am using. Can you please advise ? Thanks.

@{
    IDictionary<string, object> htmlAttributes = new Dictionary<string, object>() { { "rows", "5" } };
}

@(Html.EJS().TextBoxFor(model => model.AdditionalFields[i].Value)
                                                                        .Placeholder(@Model.AdditionalFields[i].Label)
                                                                        .FloatLabelType(Syncfusion.EJ2.Inputs.FloatLabelType.Auto)
                                                                        .Multiline()
                                                                        .HtmlAttributes(htmlAttributes)
                                                                        .Autocomplete("off")
                                                                        .Render()
                                                             )




1 Reply 1 reply marked as answer

SN Sevvandhi Nagulan Syncfusion Team September 25, 2020 04:50 PM UTC

Hi Support, 



Greetings from Syncfusion support. 


We checked the shared code snippet. We would like to inform you that, the provided code example is working as expected in our end and rows added to the textbox component. Please refer to the below code and screenshot, 

@{ 
    IDictionary<string, object> htmlAttributes = new Dictionary<string, object>() { { "rows", "5" } }; 
} 
@(Html.EJS().TextBoxFor(model => model.value).Placeholder("Enter value").FloatLabelType(Syncfusion.EJ2.Inputs.FloatLabelType.Auto).Multiline(true).HtmlAttributes(htmlAttributes).Render()) 
 

Screenshot: 

 


If we misunderstood your requirement, kindly share the more details about your requirement. 


Regards, 
Sevvandhi N 


Marked as answer
Loader.
Up arrow icon