Free Support Forum - aspose.com

Reg: Worksheet.Range

Hi,

This is Balaji RJ.

I am facing difficulty in migrating existing VB.NET code which is using MS Excel to Aspose Excel.

1. WorkSheet.Range(“spreadsheet_id”);

2.Dim appChartWorkSheetRange As Excel.Range
appChartWorkSheetRange = appChartWorkSheetRange.Find("*", , , Excel.XlLookAt.xlWhole, Excel.XlSearchOrder.xlByColumns, Excel.XlSearchDirection.xlNext, False)

Not able to find the equalant in Aspose. The above uses Ms.Excel

help!!!

  1. Please use Worksheets.GetRangeByName method.

    2. Please try Cells.FindString method.

Hi,

Thanks for that suggestion. But now i got to search for a token inside a particular range.

I have the MS Excel code as follows

appChartWorkSheet is worksheet(1) of the Excel.application
searchRange Ecel.Range

string range = “$A$1:$G$43"
searchRange = appChartWorkSheet.Range(range)
resultRange = searchRange.Find(”_", , , Excel.XlLookAt.xlWhole, Excel.XlSearchOrder.xlByColumns, Excel.XlSearchDirection.xlNext, False, , )

I tried with Aspose.Excel.

I did created a range object using,
SearchRange = appChartWorkSheet.Cells.CreateRange(A, 1, G , 43)

Suggest me to move forward as equalant to MS Excel as above.

-Balaji RJ