Good morning,
I'm using "SfDataGrid", I would like to know if it was possible to use two rows within a row, as you can see in the photo, without wrapping (I made the example using Excel, to make you understand what I wanted to achieve)
Hi Daniele,
Your requirement for 'Merging Cells' can be achieved based
on index, content, and range. You can refer to our online user guide
documentation below.
UG link: Merge Cells in WPF
DataGrid control | Syncfusion
We hope this helps. Please let us know if you need any
further assistance.
Regards,
Gokul S
HI,
Thanks for your answer, I checked, but the solution you provided is not good for me, I'll explain, the program starts, and then receives data from the mysql database via a "WEB API ASP.NET Core" server, you have to put the data just received in place of the examples, in a specific column and row, so I would need a row that contains two rows, and have the possibility of inserting a certain piece of data into a certain cell, I don't know if I have Well explained, I'll give you another example
I apologize if I wrote in the cells in Italian, but it was more convenient for me.
Translation:
ORA -> Time
CODICE MEZZO -> Vehicle Code
TIPO MEZZO -> Medium type
DISTANZA -> Distance
STAZIONAMENTO DESTINAZIONE -> Destination parking
CONVENZIONE -> Convention
PARTENZA DA (LOCALITA' - VIA) -> Departure from (Location - Street)
DESTINAZIONE (LOCALITA' - VIA) -> Destination (Location - Street)
Serv (idk)
FREQUENZA -> Frequency
TELEFONO -> Telephone
Hi Daniele,
We have analyzed your query and understood your requirement. You need to merge two rows for a specific cell. We have prepared a sample for merging in cases where there are empty cells in the row. We have merged the rows below with the empty cell.
We have provided a sample for your reference. Please review the sample and let us know if we have misunderstood your requirement. If so, please provide details about your requirement. This will be helpful in proceeding further.
UG Link : https://help.syncfusion.com/wpf/datagrid/merge-cells#merging-cells-based-on-the-content
Image Reference:
It's perfect!
Thank you so much!
Hi Daniele,
Glad that your issue is resolved!! We are closing this ticket now. Please reopen this ticket or open a new ticket if you need any assistance.
Hi,
I just resumed the project, which was assigned this question, but I noticed that the solution is only half right, after the two rows are joined I need them to behave like a single row, so if I use
SelectionUnit="Row" |
I need it to select the new row, and not count them as two separate rows
See current
It must be like this
Hi Daniele,
Thank you for reaching out to us. We understand your requirement. However, the Syncfusion WPF SfDataGrid does not currently support considering merged rows as a single row when the SelectionUnit is set to Row or Any. Therefore, it is not possible to select merged rows as a single row or count them as one.
Thank you for your understanding and cooperation.
Best Regards,
Gokul S
I see, in this case I can send the text to a second line in the cell, and split the cell into two by one line? Example below
Hi Dainele,
Based on the information you provided, we are a bit unclear about your requirement. However, we suspect that you intend to merge the cells when entering the same text for adjacent cells, but the cells were not merged and were treated as having different text. For your information, cell merging can be achieved based on index, content, and range. You can refer to our online user guide documentation for more details.
UG link: Merge Cells in WPF
DataGrid control | Syncfusion
Additionally, we have implemented the behavior you expected and attached a sample and an output video for your reference. Please review the sample, and if we have misunderstood the issue or if our implementation differs from yours, kindly share the relevant video and code snippets. If possible, try replicating the issue using our sample, or share a sample where the issue has been reproduced.
If you are experiencing a new issue, please provide video references showing the issue. This will help us offer a more accurate solution.
We have provided the online user guide documentation for merge cell limitations. Please refer to the link below.
UG Link: Merge Cells in WPF DataGrid control | Syncfusion
Thank you for your understanding and cooperation. Please revert us back if you need any further assistance. We are always happy to assist you.
Best Regards,
Gokul S