C spreadsheet 相關操作

2021-07-04 21:30:18 字數 1113 閱讀 6013

axmicrosoft.office.interop.owc11.axspreadsheet spreadsheet = new axmicrosoft.office.interop.owc11.axspreadsheet();

int startrow = int.parse(this.spreadsheet.selection.row.tostring());     //選取範圍的開始行

int startcolumn = int.parse(this.spreadsheet.selection.column.tostring());    //選取範圍的開始列

int rowcount = this.spreadsheet.selection.rows.count;         //選取範圍包含的行數

int columncount = this.spreadsheet.selection.columns.count;        //選取範圍包含的列數

string selection[i][j] = this.axxlsorder.selection.get_item(i+1, j+1).text.tostring(); //選取範圍的某個值 多行多列

int mergedrowcount = this.spreadsheet.selection.get_item(1, 1).mergearea.rows.count;  //第乙個單元格合併的行數

int mergedcolcount = this.spreadsheet.selection.get_item(1, 1).mergearea.columns.count;  //第乙個單元格合併的列數

spreadsheet.get_range(this.spreadsheet.cells[1, 1]).select();     //選中第乙個單元格

spreadsheet.get_range(this.spreadsheet.cells[startrow, startcolumn], spreadsheet.cells[endrow, endcolumn]).select();   //選中乙個區域

spreadsheet.get_range(this.spreadsheet.cells[1, 1]).paste();     //將剪貼簿中的資料貼上到第乙個單元格

jquery radio,select相關操作

1.獲取選中值,三種方法都可以 input radio checked val input type radio checked val input name rd checked val 2.設定第乙個radio為選中值 input radio first attr checked checked...

mysql相關操作 MySQL之記錄相關操作

一 介紹 mysql資料操作 dml 在mysql管理軟體中,可以通過sql語句中的dml語言來實現資料的操作,包括 使用insert實現資料的插入 update實現資料的更新 使用delete實現資料的刪除 使用select查詢資料以及。本節內容包括 插入資料 更新資料 刪除資料 查詢資料 二 插...

excel 相關簡便操作 之 vlookup 操作

準備工作 提取excel括號前的值 left b2,find b2 1 提取excel括號中的值 trim right substitute substitute b2,rept 10 rept 10 20 下圖表a中取length 從表a到表b,有乙個 值複製 的動作 使用vlookup 下圖表c...