WideStudio/MWT Class Reference

WideStudio/MWT Home
Up to


Class Name

WSCsheet

Specification of methods



Description of WSCsheet::getRowCount method

Form
long getRowCount()
Function
Get all lines. (Includes fixed cells)
Description
Parameters
None
Return value
The number of lines.
Notice
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get a number of cells and show each cell size
  long cols = ss->getColumnCount();
  long rows = ss->getRowCount();
  long col, row;
  for(col = 0; col < cols; col++){
    for(row = 0; row < rows; row++){
      WSCrect rect;
      //Get cell size
      ss->getCellRect(col, row, &rect);
      //Get value
      WSCstring val = ss->getText(col, row);
      printf("cell(%d,%d):  x,y=%d,%d w,h=%d,%d val=%s\n",
             col, row, rect.x, rect.y, rect.width, rect.height, val.getString());
    }
  }
}



Description of WSCsheet::setRowCount method

Form
long setRowCount(long rows)
Function
Set total number of lines. (includes lines of fixed cells)
Description
Parameters
(in)long rows lines
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
#include 
void sample_init(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  // Set a number of cells/lines
  ss->setColumnCount(52);
  ss->setRowCount(102);
  // Set a number of cells/lines for a fixed cell
  ss->setFixedColumnCount(2);
  ss->setFixedRowCount(2);
  //Get a number of cells and show each cell size
  long cols = ss->getColumnCount();
  long rows = ss->getRowCount();
  long col, row;
  for(col = 0; col < cols; col++){
    //Set cell width
    ss->setColumnWidth(100);
  }
  for(row = 0; row < rows; row++){
    //Set cell height
    ss->setRowHeight(25);
  }
}



Description of WSCsheet::getColumnCount method

Form
long getColumnCount()
Function
Get a total number of rows
Description
Parameters
None
Return value
Number of rows
Notice
None
Samples
See getRowCount()



Description of WSCsheet::setColumnCount method

Form
long setColumnCount(long cols)
Function
Set a total number of rows
Description
Parameters
(in)long cols Number of rows
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
See setRowCount()



Description of WSCsheet::getRowHeight method

Form
long getRowHeight(long row)
Function
Get height of a specified line
Description
Parameters
(in)long row line number
Return value
Returns height of a specified line, 0 means an error.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get a number of cells and show each cell size
  long cols = ss->getColumnCount();
  long rows = ss->getRowCount();
  long col, row;
  for(col = 0; col < cols; col++){
    long width;
    //Get cell width
    width = ss->getColumnWidth(col);
    printf("col(%d): width=%d\n", width);
  }
  for(row = 0; row < rows; row++){
    long height;
    //Get cell height
    height = ss->getRowHeight(row);
    printf("row(%d): height=%d\n", height);
  }
}



Description of WSCsheet::setRowHeight method

Form
long setRowHeight(long row,long height)
Function
Set line height
Description
Parameters
(in)long row line number
(in)long height line height
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
See setRowCount()



Description of WSCsheet::getColumnWidth method

Form
long getColumnWidth(long col)
Function
Get row width
Description
Parameters
(in)long col row number
Return value
Returns a specified row width, 0 means an error
Notice
None
Samples
See getRowHeight()



Description of WSCsheet::setColumnWidth method

Form
long setColumnWidth(long col, long width)
Function
Set row width
Description
Parameters
(in)long col row number
(in)long width row width
Return value
Return a specified row width, 0 means and error
Notice
None
Samples
See getRowCount()



Description of WSCsheet::getFixedRowCount method

Form
long getFixedRowCount()
Function
Get a number of fixed lines
Description
Parameters
None
Return value
Number of fixed lines
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get a number of fixed cells and show each cell size
  long cols = ss->getFixedColumnCount();
  long rows = ss->getFixedRowCount();
  long col, row;
  for(col = 0; col < cols; col++){
    long width;
    //Get width
    width = ss->getFixedColumnWidth(col);
    printf("col(%d): width=%d\n", width);
  }
  for(row = 0; row < rows; row++){
    long height;
    //Get height
    height = ss->getFixedRowHeight(row);
    printf("row(%d): height=%d\n", height);
  }
}



Description of WSCsheet::setFixedRowCount method

Form
long setFixedRowCount(long rows)
Function
Set a number of fixed lines
Description
Parameters
(in)long rows fixed line numbers
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
See setRowCount()



Description of WSCsheet::getFixedColumnCount method

Form
long getFixedColumnCount()
Function
Get a number of fixed rows
Description
Parameters
None
Return value
Number of fixed rows
Notice
None
Samples
See getFixedRowCount()



Description of WSCsheet::setFixedColumnCount method

Form
long setFixedColumnCount(long cols)
Function
Set a number of fixed rows
Description
Parameters
(in)long cols fixed row numbers
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
See setRowCount()



Description of WSCsheet::getFixedRowHeight method

Form
long getFixedRowHeight(long row)
Function
Get height of fixed line
Description
Parameters
(in)long row line number
Return value
Returns a specified line height, 0 means an error
Notice
None
Samples
See getFixedRowCount()



Description of WSCsheet::setFixedRowHeight method

Form
long setFixedRowHeight(long row,long height)
Function
Set fixed line height
Description
Parameters
(in)long row line number
(in)long height fixed line height
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None.
Samples



Description of WSCsheet::getFixedColumnWidth method

Form
long getFixedColumnWidth(long col)
Function
Get row width
Description
Parameters
(in)long col row number
Return value
Returns a specified row width, 0 means an error
Notice
None
Samples
See getRowCount()



Description of WSCsheet::setFixedColumnWidth method

Form
long setFixedColumnWidth(long col, long width)
Function
Set row width
Description
Parameters
(in)long col row number
(in)long width row width
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None.
Samples



Description of WSCsheet::setSheetBkColor method

Form
long setSheetBkColor(char* cname)
Form
long setSheetBkColor(short color)
Function
Set background sheet color
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set background sheet color to white.
  ss->setSheetBkColor("#ffffff");
}



Description of WSCsheet::getSheetBkColor method

Form
short getSheetBkColor()
Function
Get color number of sheet background color
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get color number of sheet background color
  short color = ss->getSheetBkColor();
  printf("sheet backcolor no = %d\", color);
}



Description of WSCsheet::setCellDefBkColor method

Form
long setCellDefBkColor(char* cname)
Form
long setCellDefBkColor(short color)
Function
Set cell default background color
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set variable cell's default background color to white
  ss->setCellDefBkColor("#ffffff");
}



Description of WSCsheet::getCellDefBkColor method

Form
short getCellDefBkColor()
Function
Get varialbe cell's default color number
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get varialbe cell's default color number
  short color = ss->getCellDefBkColor();
  printf("cell default backcolor no = %d\", color);
}



Description of WSCsheet::setCellBkColor method

Form
long setCellBkColor(char* cname)
Form
long setCellBkColor(long col,long row,char* cname)
Form
long setCellBkColor(short color)
Form
long setCellBkColor(long col,long row,short color)
Function
Set cell background color
Description
Parameters
(in)char* cname color name
(in)short color color number
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set cell background color to white for line 1, row 1
  ss->setCol(1);
  ss->setRow(1);
  ss->setCellBkColor("#ffffff");

  //Set cell background color to white for line 1, from line 2 to row 2, to line 3
  ss->setStartCol(1);
  ss->setStartRow(2);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setCellBkColor("#ffffff");
  ss->setSelectCell(False);
}



Description of WSCsheet::getCellBkColor method

Form
short getCellBkColor(long col, long row)
Function
Get cell background color
Description
Parameters
(in)long col row number
(in)long row line number
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get cell background color
  short color = ss->getCellBkColor(1, 1);
  printf("cell(1, 1) backcolor no = %d\", color);
}



Description of WSCsheet::setCellDefTextColor method

Form
long setCellDefTextColor(char* cname)
Form
long setCellDefTextColor(short color)
Function
Set default foreground color for variable cell
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set variable cell's foreground color to black
  ss->setCellDefTextColor("#000000");
}



Description of WSCsheet::getCellDefTextColor method

Form
short getCellDefTextColor()
Function
Get variable cell's default foreground color
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get variable cell's default foreground color
  short color = ss->getCellDefTextColor();
  printf("cell default textcolor no = %d\", color);
}



Description of WSCsheet::setCellTextColor method

Form
long setCellTextColor(char* cname)
Form
long setCellTextColor(long col,long row,char* cname)
Form
long setCellTextColor(short color)
Form
long setCellTextColor(long col,long row,short color)
Function
Set variable cell's foreground color
Description
Parameters
(in)char* cname color name
(in)short color color number
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set foreground color to black for line 1, row 1
  ss->setCol(1);
  ss->setRow(1);
  ss->setCellTextColor("#000000");

  //Set foreground color to black for line 1, from line 2 to row 2, line 3.
  ss->setStartCol(1);
  ss->setStartRow(2);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setCellTextColor("#000000");
  ss->setSelectCell(False);
}



Description of WSCsheet::getCellTextColor method

Form
short getCellTextColor(long col, long row)
Function
Get cell foreground color
Description
Parameters
(in)long col row number
(in)long row line number
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get cell foreground color
  short color = ss->getCellTextColor(1, 1);
  printf("cell(1,1) textcolor no = %d\", color);
}



Description of WSCsheet::setFixedBkColor method

Form
long setFixedBkColor(char* cname)
Form
long setFixedBkColor(short color)
Function
Set fixed cell's background color
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set fixed cell's background color to white
  ss->setFixedBkColor("#ffffff");
}



Description of WSCsheet::getFixedBkColor method

Form
short getFixedBkColor()
Function
Get fixed cell's background color number
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get fixed cell's background color number
  short color = ss->getFixedBkColor();
  printf("fixed cell backcolor no = %d\", color);
}



Description of WSCsheet::setFixedTextColor method

Form
long setFixedTextColor(char* cname)
Form
long setFixedTextColor(short color)
Function
Set fixed cell's foreground color number
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set fixed cell's foreground color to black
  ss->setFixedTextColor("#000000");
}



Description of WSCsheet::getFixedTextColor method

Form
short getFixedTextColor()
Function
Get fixed cell's foreground color number
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get fixed cell's foreground color number
  short color = ss->getFixedTextColor();
  printf("fixed cell textcolor no = %d\", color);
}



Description of WSCsheet::setGridColor method

Form
long setGridColor(char* cname)
Form
long setGridColor(short color)
Function
Set grid line color
Description
Parameters
(in)char* cname color name
(in)short color color number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set grid line color to white
  ss->setGridColor("#ffffff");
}



Description of WSCsheet::getGridColor method

Form
short getGridColor()
Function
Get grid line color number
Description
Parameters
None
Return value
color number
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get grid line color number
  short color = ss->getGridColor();
  printf("grid line color no = %d\", color);
}



Description of WSCsheet::setGridLines method

Form
long setGridLines(short glidLines)
Function
Configure grid line
Description
Parameters
(in)short glidLines grid line properties

Grid line has the following properties
Properties Description
WSCSHEET_NONE None
WSCSHEET_HORZ Horizon
WSCSHEET_VERT Vartical
WSCSHEET_BOTH Both
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Show grid line for both directions
  ss->setGridLines(WSCSHEET_BOTH);
}



Description of WSCsheet::getGridLines method

Form
short getGridLines()
Function
Get grid line properties
Description
Parameters
None
Return value
Show grid line
Return values are as follows
Property Description
WSCSHEET_NONE None
WSCSHEET_HORZ Horizon
WSCSHEET_VERT Varitical
WSCSHEET_BOTH Both
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get grid line properties
  short lines = ss->getGridLines();
  printf("grid lines = %d\", lines);
}



Description of WSCsheet::setCellGridLines method

Form
long setCellGridLines(short glidLines)
Form
long setCellGridLines(long col,log row,short glidLines)
Function
Set grid line properties
Description
Parameters
(in)short glidLines Property
(in)long col row number
(in)long row line number

See getGridLines() for more details
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  
  //Set grid line for line 1, row 1 to both directions
  ss->setCellGridLines(WSCSHEET_BOTH);

  //Set grid line for line 1, from line 2 to row 2, line 3 to both directions
  ss->setStartCol(1);
  ss->setStartRow(2);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setCellGridLines(WSCSHEET_BOTH);
  ss->setSelectCell(False);
}



Description of WSCsheet::getCellGridLines method

Form
long getCellGridLines(long col,long row)
Function
Get grid line properties
Description
Parameters
(in)long col row number
(in)long row line number
Return value
Grid line property See getGridLines() for more details
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get grid line properties
  short lines = ss->getCellGridLines(1, 1);
  printf("cell(1,1) grid lines = %d\", lines);
}



Description of WSCsheet::setText method

Form
long setText(short text)
Form
long setText(WSCushort text)
Form
long setText(long text)
Form
long setText(WSCulong text)
Form
long setText(float text)
Form
long setText(double text)
Form
long setText(const char* text)
Form
long setText(const WSCvariant& text)
Form
long setText(const WSCstring& text)
Form
long setText(long col,long row,short text)
Form
long setText(long col,long row,WSCushort text)
Form
long setText(long col,long row,long text)
Form
long setText(long col,long row,WSCulong text)
Form
long setText(long col,long row,float text)
Form
long setText(long col,long row,double text)
Form
long setText(long col,long row,const char* text)
Form
long setText(long col,long row,const WSCvariant& text)
Form
long setText(long col,long row,const WSCstring& text)
Function
Set cell value
Description
Parameters
(in)Type text Value
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  
  //Set a value for line 1, row 1
  ss->setCol(1);
  ss->setRow(1);
  ss->setText("text");

  //Set values for line 1, from line 2 to row 2, line 3
  ss->setStartCol(1);
  ss->setStartRow(2);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setText("text");
  ss->setSelectCell(False);
}



Description of WSCsheet::getText method

Form
WSCstring getText(long col,long row)
Function
Get cell value.
Description
Parameters
(in)long col row number
(in)long row line number
Return value
Cell value
Notice
None
Samples
See getRowCount()



Description of WSCsheet::setFixedText method

Form
long setFixedText(long col,long row,short text)
Form
long setFixedText(long col,long row,WSCushort text)
Form
long setFixedText(long col,long row,long text)
Form
long setFixedText(long col,long row,WSCulong text)
Form
long setFixedText(long col,long row,float text)
Form
long setFixedText(long col,long row,double text)
Form
long setFixedText(long col,long row,const char* text)
Form
long setFixedText(long col,long row,const WSCvariant& text)
Form
long setFixedText(long col,long row,const WSCstring& text)
Function
Get fixed cell value
Description
Parameters
(in)Type text Value
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See getFixedText()



Description of WSCsheet::getFixedText method

Form
WSCstring getFixedText(long col,long row)
Function
Get fixed cell value
Description
Parameters
(in)long col row number
(in)long row line number
Return value
Cell value
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  ss->setFixedRowCount(1);
  //Set a value to row 1, line 0
  ss->setFixedText(0, 1, "fixed text");
  //Get a value of row 1, row 0
  WSCstring text = ss->getFixedText(0, 1, "text");
  printf(fixed cell(0,1) text=%s\n", text.getString());
}



Description of WSCsheet::getCellNo method

Form
long getCellNo(WSCpoint* pt,long* col,long* row)
Function
Get line and row from a coordinates
Description
Parameters
(in)WSCpoint* pt Coordinates
(out)long* col variable for row
(out)long* row variable for line
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  // Get row and line of x:100,y:100
  WSCpoint pt;
  long     col, row;
  pt.x = 100;
  pt.y = 100;
  ss->getCellNo(&pt, &col, &row);
  printf(x=100, y=100 cell(%d,%d)\n", col, row);
}



Description of WSCsheet::setFocusCell method

Form
long setFocusCell(long col,long row)
Function
Set forcus on cell
Description
Parameters
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See getFocusCell()



Description of WSCsheet::getFocusCell method

Form
long getFocusCell(long* col,long* row)
Function
Get cell's row
line that has forcus
Description
Parameters
(out)long* col variable for row
(out)long* row variable for line
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  // Set forcus on line 1, row 1
  ss->setFocusCell(1, 1);
 
  // Get row 
line that has forcus long col, row; ss->getFocusCell(&col, &row); printf(focus cell(%d,%d)\n", col, row); // Get row line that has forcus col = ss->getFocusCol(); row = ss->getFocusRow(); printf(focus cell(%d,%d)\n", col, row); }


Description of WSCsheet::getFocusCol method

Form
long getFocusCol()
Function
Get row of forcused cell
Description
Parameters
None
Return value
row number of forcused cell
Notice
None
Samples
See getFocusCell()



Description of WSCsheet::getFocusRow method

Form
long getFocusRow()
Function
Get a line of forcused cell
Description
Parameters
None
Return value
line number of forcused cell
Notice
None
Samples
See getFocusCell()



Description of WSCsheet::setRow method

Form
long setRow(long row)
Function
Set current row
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getRow method

Form
long getRow()
Function
Get current line
Description
Parameters
None
Return value
Current line number
Notice
None
Samples



Description of WSCsheet::setStartRow method

Form
long setStartRow(long row)
Function
Set start line
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getStartRow method

Form
long getStartRow()
Function
Get start line
Description
Parameters
None
Return value
Start line number
Notice
None
Samples



Description of WSCsheet::setEndRow method

Form
long setEndRow(long row)
Function
Set end line
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getEndRow method

Form
long getEndRow()
Function
Get end line
Description
Parameters
None
Return value
End line number
Notice
None
Samples



Description of WSCsheet::setCol method

Form
long setCol(long row)
Function
Set current row
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getCol method

Form
long getCol()
Function
Get current row
Description
Parameters
None
Return value
Current row number
Notice
None
Samples



Description of WSCsheet::setStartCol method

Form
long setStartCol(long row)
Function
Set start row
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getStartCol method

Form
long getStartCol()
Function
Get start row
Description
Parameters
None
Return value
Start row number
Notice
None
Samples



Description of WSCsheet::setEndCol method

Form
long setEndCol(long row)
Function
Set end row
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See setCellBkColor()



Description of WSCsheet::getEndCol method

Form
long getEndCol()
Function
Get end row
Description
Parameters
None
Return value
End row number
Notice
None
Samples



Description of WSCsheet::setSelectCell method

Form
long setSelectCell(WSCbool fl)
Function
Set status of block selection
Description
Parameters
(in)WSCbool fl Selection Status
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Remember to set unselected status when block selection status is not required
Samples
See setCellBkColor()



Description of WSCsheet::getSelectCell method

Form
WSCbool getSelectCell()
Function
Get block selection status
Description
Parameters
None
Return value
True for selected, False for unselected
Notice
None
Samples



Description of WSCsheet::setEditEnabled method

Form
long setEditEnabled(WSCbool fl)
Function
Set editable status
Description
Parameters
(in)WSCbool fl Editable:True, Uneditable:False
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getEditEnabled method

Form
WSCbool getEditEnabled()
Function
Get editable status
Description
Parameters
None
Return value
True for editable, False for uneditable
Notice
None
Samples



Description of WSCsheet::getFocusCellRect method

Form
long getFocusCellRect(WSCrect* rect)
Function
Get location and site of forcused cell
Description
Parameters
(out)WSCrect* rect Variable for location and size
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
   // Get location and site of forcused cell
   WSCrect r;
   long err = newshee_001->getFocusCellRect(&r);
   printf("x,y,w,h=%d,%d,%d,%d\n",r.x,r.y,r.width,r.height);



Description of WSCsheet::getVisibleCellRect method

Form
long getVisibleCellRect(long col,long row,WSCrect* rect)
Function
Get location and size of variable cell currently displayed e
Description
Parameters
(in)long col row number
(in)long row line number
(out)WSCrect* rect Variable for location and size
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getCellRect method

Form
long getCellRect(long col,long row,WSCrect* rect)
Function
Get location and size of cell
Description
Parameters
(in)long col row number
(in)long row line number
(out)WSCrect* rect Variable for location and size
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
This caliculates from top of cells and may not match with actual location.
Samples
   // Get location and size of cell (1,3)
   WSCrect r;
   long err = newshee_001->getCellRect(1,3,&r);
   printf("x,y,w,h=%d,%d,%d,%d\n",r.x,r.y,r.width,r.height);



Description of WSCsheet::setTopVisibleRow method

Form
long setTopVisibleRow(long row)
Function
Set top row number of variable cell that currently displayed
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getTopVisibleRow method

Form
long getTopVisibleRow()
Function
Get to row number of variable cell that currently displayed
Description
Parameters
None
Return value
row number of variable cell that currently displayed
Notice
None
Samples



Description of WSCsheet::setTopVisibleCol method

Form
long setTopVisibleCol(long row)
Function
Set top row number of fixed cell that currently displayed
Description
Parameters
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getTopVisibleCol method

Form
long getTopVisibleCol()
Function
Get to row number of variable cell that currently displayed
Description
Parameters
None
Return value
row number of variable cell that currently displayed
Notice
None
Samples



Description of WSCsheet::setCellDefFont method

Form
long setCellDefFont(short fontno)
Function
Set default font number for variable cell
Description
Parameters
(in)short fontno font number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getCellDefFont method

Form
long getCellDefFont()
Function
Get default font number of variable cell
Description
Parameters
None
Return value
default font number of variable cell
Notice
None
Samples



Description of WSCsheet::setCellFont method

Form
long setCellFont(short fontno)
Form
long setCellFont(long col,long row,short fontno)
Function
Set cell font number
Description
Parameters
(in)short fontno font number
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
See getCellFont()



Description of WSCsheet::getCellFont method

Form
long getCellFont()
Form
long getCellFont(long col,log row)
Function
Get cell font number
Description
Parameters
(in)long col row number
(in)long row line number
Return value
font number of variable cell
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Get font number of variable cell
  short font = ss->getCellFont();
  printf("cell default font:%d\n", font);
  
  //Set font 1 to row 1, line 1
  font = ss->setCellFont(1, 1, 1);

  //Set font 1 to row 1, from line 2 to row 2, line 3
  ss->setStartCol(1);
  ss->setStartRow(2);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setCellFont(1);
  ss->setSelectCell(False);
  
}



Description of WSCsheet::setFixedCellFont method

Form
long setFixedCellFont(short fontno)
Function
Set default font number of fixed cell
Description
Parameters
(in)short fontno font number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getFixedCellFont method

Form
long getFixedCellFont()
Function
Get default font number of fixed cell
Description
Parameters
None
Return value
default font number of fixed cell
Notice
None
Samples



Description of WSCsheet::setVertAutoNumber method

Form
long setVertAutoNumber(WSCbool fl)
Function
Set line number status
Description
Parameters
(in)WSCbool fl Status
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getVertAutoNumber method

Form
WSCbool getVertAutoNumber()
Function
Get line number status
Description
Parameters
None
Return value
True:Show, False:Do not show
Notice
None
Samples
   // Get line number status
   WSCbool fl = newshee_001->getVertAutoNumber();



Description of WSCsheet::setHorzAutoNumber method

Form
long setHorzAutoNumber(WSCbool fl)
Function
Specify whether it displays the auto number or not.
Description
Parameters
(in)WSCbool fl True:Show, False:Do not show
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getHorzAutoNumber method

Form
WSCbool getHorzAutoNumber()
Function
Description
Get row number status
Parameters
None
Return value
True:Show,False:Do not show
Notice
None
Samples



Description of WSCsheet::setCellAlignment method

Form
long setCellAlignment(char align)
Form
long setCellAlignment(long col,long row,char align)
Function
Set location of variable cell
Description
Parameters
(in)char align alignment
(in)long col row number
(in)long row line number

Alignment should be:
Property Description
WS_LEFT Left anchor
WS_RIGHT Right anchor
WS_CENTER Center
WS_TOP Top anchor
WS_BOTTOM Bottom anchor
WS_LEFT_TOP Left top anchor
WS_LEFT_BOTTOM Left bottom anchor
WS_RIGHT_BOTTOM Right bottom anchor
WS_RIGHT_TOP Right top anchor
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getCellAlignment method

Form
char getCellAlignment(long col,long row)
Function
Get alighment of specified col,row
Description
Parameters
(in)long col row number
(in)long row line number
Return value
alighment of specified col,row
Notice
None
Samples
   // Get alignment of cell(1,2)
   char align = newshee_001->getCellAlignment(1,2);



Description of WSCsheet::setFixedCellAlignment method

Form
long setFixedCellAlignment(char align)
Form
long setFixedCellAlignment(long col,long row,char align)
Function
Set location of fixed cell
Description
Parameters
(in)char align Alignment
(in)long col row number
(in)long row line number

Alignment should be:
Property Description
WS_LEFT Left anchor
WS_RIGHT Right anchor
WS_CENTER Center
WS_TOP Top anchor
WS_BOTTOM Bottom anchor
WS_LEFT_TOP Left top anchor
WS_LEFT_BOTTOM Left bottom anchor
WS_RIGHT_BOTTOM Right bottom anchor
WS_RIGHT_TOP Right top anchor
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getFixedCellAlignment method

Form
char getFixedCellAlignment(long col,long row)
Function
Get location of fixed cell
Description
Parameters
(in)long col row number
(in)long row line number
Return value
location of fixed cell
Notice
None
Samples



Description of WSCsheet::setCellLock method

Form
long setCellLock(WSCbool fl)
Form
long setCellLock(long col,long row,WSCbool fl)
Function
Set editable/uneditable(locked) to variable cell
Description
Parameters
(in)WSCbool fl True:Uneditable (locked),False:Editable
(in)long col row number
(in)long row line number
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getCellLock method

Form
WSCbool getCellLock()
Function
Get uneditable property of variable cell
Description
Parameters
None
Return value
True:Uneditable, False:Editable
Notice
None
Samples



Description of WSCsheet::getClientWidth method

Form
unsigned short getClientWidth()
Function
Get valid client width
Description
Parameters
None
Return value
client width
Notice
None
Samples



Description of WSCsheet::getClientHeight method

Form
unsigned short getClientHeight()
Function
Get valid client height
Description
Parameters
None
Return value
client height
Notice
None
Samples



Description of WSCsheet::setNoRefresh method

Form
void setNoRefresh(WSCbool fl)
Function
Set validation of drawing
Description
Parameters
(in)WSCbool fl Drawable/Undrawable
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Set undrawable
  ss->setNoRefresh(True);

  //Set background color, foreground color and text for row 1, from line 1 to row 2, line 3
  ss->setStartCol(1);
  ss->setStartRow(1);
  ss->setEndCol(2);
  ss->setEndRow(3);
  ss->setSelectCell(True);
  ss->setCellBkColor("#00ffff");
  ss->setCellTextColor("#ff0000");
  ss->setTect("text");
  ss->setSelectCell(False);
  //Set drawable
  ss->setNoRefresh(False);

  // Redraw
  ss->draw();
}



Description of WSCsheet::getNoRefresh method

Form
WSCbool getNoRefresh()
Function
Get drawable status
Description
Parameters
None
Return value
True:Undrawable,False:Drawable
Notice
None
Samples



Description of WSCsheet::insertRow method

Form
long insertRow()
Function
Insert line
Description
Parameters
None
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Insert a line into current line
  ss->insertRow();

  //Insert two lines in line 1
  ss->setStartCol(1);
  ss->setStartRow(1);
  ss->setEndCol(1);
  ss->setEndRow(2);
  ss->setSelectCell(True);
  ss->insertRow();
  ss->setSelectCell(False);

}



Description of WSCsheet::insertRow method

Form
long insertRow(long row,long rows)
Function
Insert line
Description
Parameters
(in)long row line number
(in)long rows number of lines to insert
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }

  //Insert two lines in line 1
  ss->insertRow(1, 2);

}



Description of WSCsheet::insertCol method

Form
long insertCol()
Function
Insert row
Description
Parameters
None
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Insert row into the currentl row
  ss->insertCol();

  //Insert two rows in row 1
  ss->setStartCol(1);
  ss->setStartRow(1);
  ss->setEndCol(2);
  ss->setEndRow(1);
  ss->setSelectCell(True);
  ss->insertCol();
  ss->setSelectCell(False);

}



Description of WSCsheet::insertCol method

Form
long insertCol(long col,long cols)
Function
Insert row
Description
Parameters
(in)long col row number
(in)long cols number of rows to insert
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }

  //Insert two rows in line 1
  ss->insertCol(1, 2);

}



Description of WSCsheet::deleteRow method

Form
long deleteRow()
Function
Delete line
Description
Parameters
None
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Delete current line
  ss->deleteRow();

  //Delete two lines from line 1
  ss->setStartCol(1);
  ss->setStartRow(1);
  ss->setEndCol(1);
  ss->setEndRow(2);
  ss->setSelectCell(True);
  ss->deleteRow();
  ss->setSelectCell(False);
}



Description of WSCsheet::deleteRow method

Form
long deleteRow(long row,long rows)
Function
Delete line
Description
Parameters
(in)long row line number
(in)long rows number of lines to delete
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }

  //delete two lines from line 1
  ss->deleteRow(1, 2);
}



Description of WSCsheet::deleteCol method

Form
long deleteCol()
Function
Delete row
Description
Parameters
None
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }
  //Delete current row
  ss->deleteCol();

  //Delte two lines from row 1
  ss->setStartCol(1);
  ss->setStartRow(1);
  ss->setEndCol(1);
  ss->setEndRow(2);
  ss->setSelectCell(True);
  ss->deleteCol();
  ss->setSelectCell(False);
}



Description of WSCsheet::deleteCol method

Form
long deleteCol(long col,long cols)
Function
Delete row
Description
Parameters
(in)long col row number
(in)long cols number of rows to delete
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples
#include 
void sample_proc(WSCbase* object){
  WSCsheet* ss = (WSCsheet*)object->cast("WSCsheet");
  if (ss == NULL){
    return;
  }

  //Delte two rows from row 1
  ss->deleteCol(1, 2);
}



Description of WSCsheet::setDataSource method

Form
long setDataSource(const char* name)
Form
long setDataSource(WSCstring& sname)
Function
Set datasource name
Description
Parameters
(in)const char* name datasource name
(in)WSCstring& sname datasource name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDataSource method

Form
WSCstring getDataSource()
Function
Get datasource name
Description
Parameters
None
Return value
Datasource name
Notice
Samples



Description of WSCsheet::setTableName method

Form
long setTableName(const char* name)
Form
long setTableName(WSCstring& tname)
Function
Set table name of database
Description
Parameters
(in)const char* name Table name
(in)WSCstring& tname Table name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getTableName method

Form
WSCstring getTableName()
Function
Get table name of database
Description
Parameters
None
Return value
Table name of database
Notice
Samples



Description of WSCsheet::setDbItem method

Form
long setDbItem(const char* name)
Form
long setDbItem(WSCstring& iname)
Function
Set item name
Description
Parameters
(in)const char* name item name
(in)WSCstring& iname item name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getDbItem method

Form
WSCstring getDbItem()
Function
Get item name
Description
Parameters
None
Return value
Item name
Notice
Samples



Description of WSCsheet::setDbSortItem1 method

Form
long setDbSortItem1(const char* name)
Form
long setDbSortItem1(WSCstring& iname)
Function
Set 1st item name for sort key
Description
Parameters
(in)const char* name item name
(in)WSCstring& iname item name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSortItem1 method

Form
WSCstring getDbSortItem1()
Function
Get 1st item name for sort key
Description
Parameters
None
Return value
1st item name for sort key
Notice
Samples



Description of WSCsheet::setDbSortItem2 method

Form
long setDbSortItem2(const char* name)
Form
long setDbSortItem2(WSCstring& iname)
Function
Set 2st item name for sort key
Description
Parameters
(in)const char* name item name
(in)WSCstring& iname item name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSortItem2 method

Form
WSCstring getDbSortItem2()
Function
Get 2nd item name for sort key
Description
Parameters
None
Return value
2nd item name for sort key
Notice
Samples



Description of WSCsheet::setDbSortItem3 method

Form
long setDbSortItem3(const char* name)
Form
long setDbSortItem3(WSCstring& iname)
Function
Set 3rd item name for sort key
Description
Parameters
(in)const char* name item name
(in)WSCstring& iname item name
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSortItem3 method

Form
WSCstring getDbSortItem3()
Function
Get 3rd item name for sort key
Description
Parameters
None
Return value
3rd item name for sort key
Notice
Samples



Description of WSCsheet::setDbSort1 method

Form
long setDbSort1(unsigned char sort)
Function
Set 1st sort condition
Description
Parameters
(in)unsigned char sort Sort condition

Sort conditions are:
Property Description
WSCSHEET_DB_SORT_ASC Ascending
WSCSHEET_DB_SORT_DESC Descending
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSort1 method

Form
unsigned char getDbSort1()
Function
Get 1st sort condition
Description
Parameters
None
Return value
Returns sort property See setDbSort1() for more details
Notice
Samples



Description of WSCsheet::setDbSort2 method

Form
long setDbSort2(unsigned char sort)
Function
Set 2st sort condition
Description
Parameters
(in)unsigned char sort Sort condition

See setDbSort1() for more details
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSort2 method

Form
unsigned char getDbSort2()
Function
Get 2nd sort condition
Description
Parameters
None
Return value
Returns sort property See setDbSort1() for more details
Notice
Samples



Description of WSCsheet::setDbSort3 method

Form
long setDbSort3(unsigned char sort)
Function
Get 3rd sort condition
Description
Parameters
(in)unsigned char sort Sort condition

See setDbSort1() fore more details
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbSort3 method

Form
unsigned char getDbSort3()
Function
Get 3rd sort condition
Description
Parameters
None
Return value
Returns sort property See setDbSort1() for more details
Notice
Samples



Description of WSCsheet::setDbFilter method

Form
long setDbFilter(const char* filter)
Form
long setDbFilter(WSCstring& filter)
Function
Set extraction condition
Description
Parameters
(in)const char* filter extraction condition
(in)WSCstring& filter extraction condition
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Samples



Description of WSCsheet::getDbFilter method

Form
WSCstring getDbFilter()
Function
Get extraction condition
Description
Parameters
None
Return value
Extractin condition
Notice
Samples



Description of WSCsheet::setDbStmtString method

Form
long setDbStmtString(const char* stmt)
Form
long setDbStmtString(WSCstring& stmt)
Function
Set extraction condition
Description
Parameters
(in)const char* stmt SQL Statement
(in)WSCstring& stmt SQL Statement
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
None
Samples



Description of WSCsheet::getDbStmtString method

Form
WSCstring getDbStmtString()
Function
Get SQL statement
Description
Parameters
None
Return value
SQL statement
Notice
Samples



Description of WSCsheet::dbRefresh method

Form
long dbRefresh()
Function
Connect to database and show data
Description
Parameters
None
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
If DB connection information is configured in properties, data is retrieved automatically at first time
Samples



Description of WSCsheet::dataClear method

Form
long dataClear(long col, long row)
Function
Clear data and set number of rows/lines
Description
Parameters
(in)long col number of rows
(in)long row number of lines
Return value
Returns WS_NO_ERR if it succeeds; returns otherwise if it fails.
Notice
Data in fixed row, fixed line and properties of each cell are preserved Note that properties of removed lines are discarded.
Samples


Document Release 3.90

For use with WideStudio/MWT Release 3.90, Summer 2005


WideStudio/MWT Home | Up to

Copyright(C) WideStudio/MWT Development Team, 1999-2005 Last modified: June 25, 2005