MCPcopy
hub / github.com/jmcnamara/XlsxWriter / write_string

Method write_string

xlsxwriter/worksheet.py:577–595  ·  view source on GitHub ↗

Write a string to a worksheet cell. Args: row: The cell row (zero indexed). col: The cell column (zero indexed). string: Cell data. Str. format: An optional cell Format object. Returns: 0: Success.

(
        self, row: int, col: int, string: str, cell_format: Optional[Format] = None
    )

Source from the content-addressed store, hash-verified

575
576 @convert_cell_args
577 def write_string(
578 self, row: int, col: int, string: str, cell_format: Optional[Format] = None
579 ) -> Literal[0, -1, -2]:
580 """
581 Write a string to a worksheet cell.
582
583 Args:
584 row: The cell row (zero indexed).
585 col: The cell column (zero indexed).
586 string: Cell data. Str.
587 format: An optional cell Format object.
588
589 Returns:
590 0: Success.
591 -1: Row or column is out of worksheet bounds.
592 -2: String truncated to 32k characters.
593
594 """
595 return self._write_string(row, col, string, cell_format)
596
597 # Undecorated version of write_string().
598 def _write_string(

Callers 15

time_xlsxwriterFunction · 0.45
perf_pyx.pyFile · 0.45
TestOneInputFunction · 0.45
test_close_file_twiceMethod · 0.45
test_create_fileMethod · 0.45
test_create_fileMethod · 0.45
test_create_fileMethod · 0.45

Calls 1

_write_stringMethod · 0.95

Tested by 15

test_close_file_twiceMethod · 0.36
test_create_fileMethod · 0.36
test_create_fileMethod · 0.36
test_create_fileMethod · 0.36
test_create_fileMethod · 0.36
test_create_file_A1Method · 0.36