-
Notifications
You must be signed in to change notification settings - Fork 63
/
word.tablerow.yml
726 lines (696 loc) · 29.1 KB
/
word.tablerow.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
### YamlMime:TSType
name: Word.TableRow
uid: 'word!Word.TableRow:class'
package: word!
fullName: Word.TableRow
summary: Represents a row in a Word document.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
type: class
properties:
- name: cellCount
uid: 'word!Word.TableRow#cellCount:member'
package: word!
fullName: cellCount
summary: Gets the number of cells in the row.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly cellCount: number;'
return:
type: number
- name: cells
uid: 'word!Word.TableRow#cells:member'
package: word!
fullName: cells
summary: Gets cells. Read-only.
remarks: >-
\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
#### Examples
```TypeScript
// Link to full sample:
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/40-tables/manage-formatting.yaml
// Gets content alignment details about the first cell of the first table in the document.
await Word.run(async (context) => {
const firstTable: Word.Table = context.document.body.tables.getFirst();
const firstTableRow: Word.TableRow = firstTable.rows.getFirst();
const firstCell: Word.TableCell = firstTableRow.cells.getFirst();
firstCell.load(["horizontalAlignment", "verticalAlignment"]);
await context.sync();
console.log(`Details about the alignment of the first table's first cell:`, `- Horizontal alignment of the cell's content: ${firstCell.horizontalAlignment}`, `- Vertical alignment of the cell's content: ${firstCell.verticalAlignment}`);
});
```
isPreview: false
isDeprecated: false
syntax:
content: 'readonly cells: Word.TableCellCollection;'
return:
type: '<xref uid="word!Word.TableCellCollection:class" />'
- name: context
uid: 'word!Word.TableRow#context:member'
package: word!
fullName: context
summary: >-
The request context associated with the object. This connects the add-in's process to the Office host
application's process.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'context: RequestContext;'
return:
type: '<xref uid="word!Word.RequestContext:class" />'
- name: endnotes
uid: 'word!Word.TableRow#endnotes:member'
package: word!
fullName: endnotes
summary: Gets the collection of endnotes in the table row.
remarks: '\[ [API set: WordApi 1.5](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly endnotes: Word.NoteItemCollection;'
return:
type: '<xref uid="word!Word.NoteItemCollection:class" />'
- name: fields
uid: 'word!Word.TableRow#fields:member'
package: word!
fullName: fields
summary: Gets the collection of field objects in the table row.
remarks: '\[ [API set: WordApi 1.4](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly fields: Word.FieldCollection;'
return:
type: '<xref uid="word!Word.FieldCollection:class" />'
- name: font
uid: 'word!Word.TableRow#font:member'
package: word!
fullName: font
summary: 'Gets the font. Use this to get and set font name, size, color, and other properties.'
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly font: Word.Font;'
return:
type: '<xref uid="word!Word.Font:class" />'
- name: footnotes
uid: 'word!Word.TableRow#footnotes:member'
package: word!
fullName: footnotes
summary: Gets the collection of footnotes in the table row.
remarks: '\[ [API set: WordApi 1.5](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly footnotes: Word.NoteItemCollection;'
return:
type: '<xref uid="word!Word.NoteItemCollection:class" />'
- name: horizontalAlignment
uid: 'word!Word.TableRow#horizontalAlignment:member'
package: word!
fullName: horizontalAlignment
summary: >-
Specifies the horizontal alignment of every cell in the row. The value can be 'Left', 'Centered', 'Right', or
'Justified'.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'horizontalAlignment: Word.Alignment | "Mixed" | "Unknown" | "Left" | "Centered" | "Right" | "Justified";'
return:
type: '<xref uid="word!Word.Alignment:enum" /> | "Mixed" | "Unknown" | "Left" | "Centered" | "Right" | "Justified"'
- name: isHeader
uid: 'word!Word.TableRow#isHeader:member'
package: word!
fullName: isHeader
summary: >-
Checks whether the row is a header row. To set the number of header rows, use `headerRowCount` on the Table
object.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly isHeader: boolean;'
return:
type: boolean
- name: parentTable
uid: 'word!Word.TableRow#parentTable:member'
package: word!
fullName: parentTable
summary: Gets parent table.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly parentTable: Word.Table;'
return:
type: '<xref uid="word!Word.Table:class" />'
- name: preferredHeight
uid: 'word!Word.TableRow#preferredHeight:member'
package: word!
fullName: preferredHeight
summary: Specifies the preferred height of the row in points.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'preferredHeight: number;'
return:
type: number
- name: rowIndex
uid: 'word!Word.TableRow#rowIndex:member'
package: word!
fullName: rowIndex
summary: Gets the index of the row in its parent table.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'readonly rowIndex: number;'
return:
type: number
- name: shadingColor
uid: 'word!Word.TableRow#shadingColor:member'
package: word!
fullName: shadingColor
summary: 'Specifies the shading color. Color is specified in "\#RRGGBB" format or by using the color name.'
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'shadingColor: string;'
return:
type: string
- name: values
uid: 'word!Word.TableRow#values:member'
package: word!
fullName: values
summary: 'Specifies the text values in the row, as a 2D JavaScript array.'
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'values: string[][];'
return:
type: 'string[][]'
- name: verticalAlignment
uid: 'word!Word.TableRow#verticalAlignment:member'
package: word!
fullName: verticalAlignment
summary: 'Specifies the vertical alignment of the cells in the row. The value can be ''Top'', ''Center'', or ''Bottom''.'
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'verticalAlignment: Word.VerticalAlignment | "Mixed" | "Top" | "Center" | "Bottom";'
return:
type: '<xref uid="word!Word.VerticalAlignment:enum" /> | "Mixed" | "Top" | "Center" | "Bottom"'
methods:
- name: clear()
uid: 'word!Word.TableRow#clear:member(1)'
package: word!
fullName: clear()
summary: Clears the contents of the row.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'clear(): void;'
return:
type: void
description: ''
- name: delete()
uid: 'word!Word.TableRow#delete:member(1)'
package: word!
fullName: delete()
summary: Deletes the entire row.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'delete(): void;'
return:
type: void
description: ''
- name: getBorder(borderLocation)
uid: 'word!Word.TableRow#getBorder:member(1)'
package: word!
fullName: getBorder(borderLocation)
summary: Gets the border style of the cells in the row.
remarks: >-
\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
#### Examples
```TypeScript
// Link to full sample:
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/40-tables/manage-formatting.yaml
// Gets border details about the first row of the first table in the document.
await Word.run(async (context) => {
const firstTable: Word.Table = context.document.body.tables.getFirst();
const firstTableRow: Word.TableRow = firstTable.rows.getFirst();
const borderLocation = Word.BorderLocation.bottom;
const border: Word.TableBorder = firstTableRow.getBorder(borderLocation);
border.load(["type", "color", "width"]);
await context.sync();
console.log(`Details about the ${borderLocation} border of the first table's first row:`, `- Color: ${border.color}`, `- Type: ${border.type}`, `- Width: ${border.width} points`);
});
```
isPreview: false
isDeprecated: false
syntax:
content: 'getBorder(borderLocation: Word.BorderLocation): Word.TableBorder;'
parameters:
- id: borderLocation
description: Required. The border location.
type: '<xref uid="word!Word.BorderLocation:enum" />'
return:
type: '<xref uid="word!Word.TableBorder:class" />'
description: ''
- name: getBorder(borderLocationString)
uid: 'word!Word.TableRow#getBorder:member(2)'
package: word!
fullName: getBorder(borderLocationString)
summary: Gets the border style of the cells in the row.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: >-
getBorder(borderLocationString: "Top" | "Left" | "Bottom" | "Right" | "InsideHorizontal" | "InsideVertical" |
"Inside" | "Outside" | "All"): Word.TableBorder;
parameters:
- id: borderLocationString
description: Required. The border location.
type: '"Top" | "Left" | "Bottom" | "Right" | "InsideHorizontal" | "InsideVertical" | "Inside" | "Outside" | "All"'
return:
type: '<xref uid="word!Word.TableBorder:class" />'
description: ''
- name: getCellPadding(cellPaddingLocation)
uid: 'word!Word.TableRow#getCellPadding:member(1)'
package: word!
fullName: getCellPadding(cellPaddingLocation)
summary: Gets cell padding in points.
remarks: >-
\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]
#### Examples
```TypeScript
// Link to full sample:
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/40-tables/manage-formatting.yaml
// Gets cell padding details about the first row of the first table in the document.
await Word.run(async (context) => {
const firstTable: Word.Table = context.document.body.tables.getFirst();
const firstTableRow: Word.TableRow = firstTable.rows.getFirst();
const cellPaddingLocation = Word.CellPaddingLocation.bottom;
const cellPadding = firstTableRow.getCellPadding(cellPaddingLocation);
await context.sync();
console.log(
`Cell padding details about the ${cellPaddingLocation} border of the first table's first row: ${cellPadding.value} points`
);
});
```
isPreview: false
isDeprecated: false
syntax:
content: 'getCellPadding(cellPaddingLocation: Word.CellPaddingLocation): OfficeExtension.ClientResult<number>;'
parameters:
- id: cellPaddingLocation
description: 'Required. The cell padding location must be ''Top'', ''Left'', ''Bottom'', or ''Right''.'
type: '<xref uid="word!Word.CellPaddingLocation:enum" />'
return:
type: '<xref uid="office!OfficeExtension.ClientResult:class" /><number>'
description: ''
- name: getCellPadding(cellPaddingLocationString)
uid: 'word!Word.TableRow#getCellPadding:member(2)'
package: word!
fullName: getCellPadding(cellPaddingLocationString)
summary: Gets cell padding in points.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: >-
getCellPadding(cellPaddingLocationString: "Top" | "Left" | "Bottom" | "Right"):
OfficeExtension.ClientResult<number>;
parameters:
- id: cellPaddingLocationString
description: 'Required. The cell padding location must be ''Top'', ''Left'', ''Bottom'', or ''Right''.'
type: '"Top" | "Left" | "Bottom" | "Right"'
return:
type: '<xref uid="office!OfficeExtension.ClientResult:class" /><number>'
description: ''
- name: getNext()
uid: 'word!Word.TableRow#getNext:member(1)'
package: word!
fullName: getNext()
summary: Gets the next row. Throws an `ItemNotFound` error if this row is the last one.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'getNext(): Word.TableRow;'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: getNextOrNullObject()
uid: 'word!Word.TableRow#getNextOrNullObject:member(1)'
package: word!
fullName: getNextOrNullObject()
summary: >-
Gets the next row. If this row is the last one, then this method will return an object with its `isNullObject`
property set to `true`<!-- -->. For further information, see [*OrNullObject methods and
properties](https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties)<!--
-->.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'getNextOrNullObject(): Word.TableRow;'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: 'insertRows(insertLocation, rowCount, values)'
uid: 'word!Word.TableRow#insertRows:member(1)'
package: word!
fullName: 'insertRows(insertLocation, rowCount, values)'
summary: 'Inserts rows using this row as a template. If values are specified, inserts the values into the new rows.'
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: >-
insertRows(insertLocation: Word.InsertLocation.before | Word.InsertLocation.after | "Before" | "After",
rowCount: number, values?: string[][]): Word.TableRowCollection;
parameters:
- id: insertLocation
description: >-
Required. Where the new rows should be inserted, relative to the current row. It must be 'Before' or
'After'.
type: >-
<xref uid="word!Word.InsertLocation.before:member" /> | <xref uid="word!Word.InsertLocation.after:member" />
| "Before" | "After"
- id: rowCount
description: Required. Number of rows to add
type: number
- id: values
description: >-
Optional. Strings to insert in the new rows, specified as a 2D array. The number of cells in each row must
not exceed the number of cells in the existing row.
type: 'string[][]'
return:
type: '<xref uid="word!Word.TableRowCollection:class" />'
description: ''
- name: load(options)
uid: 'word!Word.TableRow#load:member(1)'
package: word!
fullName: load(options)
summary: >-
Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading
the properties.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'load(options?: Word.Interfaces.TableRowLoadOptions): Word.TableRow;'
parameters:
- id: options
description: Provides options for which properties of the object to load.
type: '<xref uid="word!Word.Interfaces.TableRowLoadOptions:interface" />'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: load(propertyNames)
uid: 'word!Word.TableRow#load:member(2)'
package: word!
fullName: load(propertyNames)
summary: >-
Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading
the properties.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'load(propertyNames?: string | string[]): Word.TableRow;'
parameters:
- id: propertyNames
description: A comma-delimited string or an array of strings that specify the properties to load.
type: 'string | string[]'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: load(propertyNamesAndPaths)
uid: 'word!Word.TableRow#load:member(3)'
package: word!
fullName: load(propertyNamesAndPaths)
summary: >-
Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading
the properties.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: |-
load(propertyNamesAndPaths?: {
select?: string;
expand?: string;
}): Word.TableRow;
parameters:
- id: propertyNamesAndPaths
description: >-
`propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and
`propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load.
type: |-
{
select?: string;
expand?: string;
}
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: merge()
uid: 'word!Word.TableRow#merge:member(1)'
package: word!
fullName: merge()
summary: Merges the row into one cell.
remarks: '\[ [API set: WordApi 1.4](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'merge(): Word.TableCell;'
return:
type: '<xref uid="word!Word.TableCell:class" />'
description: ''
- name: 'search(searchText, searchOptions)'
uid: 'word!Word.TableRow#search:member(1)'
package: word!
fullName: 'search(searchText, searchOptions)'
summary: >-
Performs a search with the specified SearchOptions on the scope of the row. The search results are a collection of
range objects.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: |-
search(searchText: string, searchOptions?: Word.SearchOptions | {
ignorePunct?: boolean;
ignoreSpace?: boolean;
matchCase?: boolean;
matchPrefix?: boolean;
matchSuffix?: boolean;
matchWholeWord?: boolean;
matchWildcards?: boolean;
}): Word.RangeCollection;
parameters:
- id: searchText
description: Required. The search text.
type: string
- id: searchOptions
description: Optional. Options for the search.
type: |-
<xref uid="word!Word.SearchOptions:class" /> | {
ignorePunct?: boolean;
ignoreSpace?: boolean;
matchCase?: boolean;
matchPrefix?: boolean;
matchSuffix?: boolean;
matchWholeWord?: boolean;
matchWildcards?: boolean;
}
return:
type: '<xref uid="word!Word.RangeCollection:class" />'
description: ''
- name: select(selectionMode)
uid: 'word!Word.TableRow#select:member(1)'
package: word!
fullName: select(selectionMode)
summary: Selects the row and navigates the Word UI to it.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'select(selectionMode?: Word.SelectionMode): void;'
parameters:
- id: selectionMode
description: 'Optional. The selection mode must be ''Select'', ''Start'', or ''End''. ''Select'' is the default.'
type: '<xref uid="word!Word.SelectionMode:enum" />'
return:
type: void
description: ''
- name: select(selectionModeString)
uid: 'word!Word.TableRow#select:member(2)'
package: word!
fullName: select(selectionModeString)
summary: Selects the row and navigates the Word UI to it.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'select(selectionModeString?: "Select" | "Start" | "End"): void;'
parameters:
- id: selectionModeString
description: 'Optional. The selection mode must be ''Select'', ''Start'', or ''End''. ''Select'' is the default.'
type: '"Select" | "Start" | "End"'
return:
type: void
description: ''
- name: 'set(properties, options)'
uid: 'word!Word.TableRow#set:member(1)'
package: word!
fullName: 'set(properties, options)'
summary: >-
Sets multiple properties of an object at the same time. You can pass either a plain object with the appropriate
properties, or another API object of the same type.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'set(properties: Interfaces.TableRowUpdateData, options?: OfficeExtension.UpdateOptions): void;'
parameters:
- id: properties
description: >-
A JavaScript object with properties that are structured isomorphically to the properties of the object on
which the method is called.
type: '<xref uid="word!Word.Interfaces.TableRowUpdateData:interface" />'
- id: options
description: Provides an option to suppress errors if the properties object tries to set any read-only properties.
type: '<xref uid="office!OfficeExtension.UpdateOptions:interface" />'
return:
type: void
description: ''
- name: set(properties)
uid: 'word!Word.TableRow#set:member(2)'
package: word!
fullName: set(properties)
summary: 'Sets multiple properties on the object at the same time, based on an existing loaded object.'
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'set(properties: Word.TableRow): void;'
parameters:
- id: properties
description: ''
type: '<xref uid="word!Word.TableRow:class" />'
return:
type: void
description: ''
- name: 'setCellPadding(cellPaddingLocation, cellPadding)'
uid: 'word!Word.TableRow#setCellPadding:member(1)'
package: word!
fullName: 'setCellPadding(cellPaddingLocation, cellPadding)'
summary: Sets cell padding in points.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'setCellPadding(cellPaddingLocation: Word.CellPaddingLocation, cellPadding: number): void;'
parameters:
- id: cellPaddingLocation
description: 'Required. The cell padding location must be ''Top'', ''Left'', ''Bottom'', or ''Right''.'
type: '<xref uid="word!Word.CellPaddingLocation:enum" />'
- id: cellPadding
description: Required. The cell padding.
type: number
return:
type: void
description: ''
- name: 'setCellPadding(cellPaddingLocationString, cellPadding)'
uid: 'word!Word.TableRow#setCellPadding:member(2)'
package: word!
fullName: 'setCellPadding(cellPaddingLocationString, cellPadding)'
summary: Sets cell padding in points.
remarks: '\[ [API set: WordApi 1.3](/javascript/api/requirement-sets/word/word-api-requirement-sets) \]'
isPreview: false
isDeprecated: false
syntax:
content: 'setCellPadding(cellPaddingLocationString: "Top" | "Left" | "Bottom" | "Right", cellPadding: number): void;'
parameters:
- id: cellPaddingLocationString
description: 'Required. The cell padding location must be ''Top'', ''Left'', ''Bottom'', or ''Right''.'
type: '"Top" | "Left" | "Bottom" | "Right"'
- id: cellPadding
description: Required. The cell padding.
type: number
return:
type: void
description: ''
- name: toJSON()
uid: 'word!Word.TableRow#toJSON:member(1)'
package: word!
fullName: toJSON()
summary: >-
Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to
`JSON.stringify()`<!-- -->. (`JSON.stringify`<!-- -->, in turn, calls the `toJSON` method of the object that is
passed to it.) Whereas the original `Word.TableRow` object is an API object, the `toJSON` method returns a plain
JavaScript object (typed as `Word.Interfaces.TableRowData`<!-- -->) that contains shallow copies of any loaded
child properties from the original object.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'toJSON(): Word.Interfaces.TableRowData;'
return:
type: '<xref uid="word!Word.Interfaces.TableRowData:interface" />'
description: ''
- name: track()
uid: 'word!Word.TableRow#track:member(1)'
package: word!
fullName: track()
summary: >-
Track the object for automatic adjustment based on surrounding changes in the document. This call is a shorthand
for
[context.trackedObjects.add(thisObject)](https://learn.microsoft.com/javascript/api/office/officeextension.clientrequestcontext#office-officeextension-clientrequestcontext-trackedobjects-member)<!--
-->. If you're using this object across `.sync` calls and outside the sequential execution of a ".run" batch, and
get an "InvalidObjectPath" error when setting a property or invoking a method on the object, you need to add the
object to the tracked object collection when the object was first created. If this object is part of a collection,
you should also track the parent collection.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'track(): Word.TableRow;'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
- name: untrack()
uid: 'word!Word.TableRow#untrack:member(1)'
package: word!
fullName: untrack()
summary: >-
Release the memory associated with this object, if it has previously been tracked. This call is shorthand for
[context.trackedObjects.remove(thisObject)](https://learn.microsoft.com/javascript/api/office/officeextension.clientrequestcontext#office-officeextension-clientrequestcontext-trackedobjects-member)<!--
-->. Having many tracked objects slows down the host application, so please remember to free any objects you add,
once you're done using them. You'll need to call `context.sync()` before the memory release takes effect.
remarks: ''
isPreview: false
isDeprecated: false
syntax:
content: 'untrack(): Word.TableRow;'
return:
type: '<xref uid="word!Word.TableRow:class" />'
description: ''
extends: '<xref uid="office!OfficeExtension.ClientObject:class" />'