We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Insert cells... shift down or right

Hi, is it possible to replicate this option in Excel...?


i.e. insert a range of cells and push the existing cells down like this...

Insert Cells... Shift cells down


Thanks,
Mark


5 Replies

AV Abirami Varadharajan Syncfusion Team April 21, 2016 12:58 PM UTC

Hi Mark,

Thank you for contacting syncfusion support.

Yes, it is possible to insert rows in between the existing cells using InsertRow method . We have shared a sample for your reference which can be downloaded from the following link.

Code Example:

Worksheet.InsertRow(int iRowIndex, int iRowCount, ExcelInsertOptions insertOptions);

Sample Link: http://www.syncfusion.com/downloads/support/directtrac/general/ze/InsertCells-298069843.zip

Kindly try this sample and you can also refer the below UG documentation link, to know more about ExcelInsertOptions.

UG Documentation link http://help.syncfusion.com/cr/cref_files/windowsforms/xlsio/Syncfusion.XlsIO.Base~Syncfusion.XlsIO.ExcelInsertOptions.html

Please let us know if you have any concerns.

Regards,
Abirami.


MA Mark April 21, 2016 09:38 PM UTC

Thanks, but that method inserts an entire row, not a range.

See my original post for an example.

Mark


AV Abirami Varadharajan Syncfusion Team April 22, 2016 12:48 PM UTC

Hi Mark, 
 
Currently, there is no direct method to insert cells. But your requirement can be achieved through a workaround, we have created a custom method Insertcells to insert cells in between the existing cells and you can move them right or down. The sample illustrating this behaviour can be downloaded from the following link. 
 
 
Please let us know if you have any concerns. 
 
Regards, 
Abirami. 



MA Mark April 25, 2016 11:40 PM UTC

OK, thanks.


AV Abirami Varadharajan Syncfusion Team April 26, 2016 06:53 AM UTC

Hi Mark, 
 
Thank you for updating us. 
 
Please let us know if you need any further assistance on this. 
 
Regards, 
Abirami. 
 


Loader.
Live Chat Icon For mobile
Up arrow icon