Skip to content

Commit f21f797

Browse files
committed
fix sample
1 parent 68dd3fd commit f21f797

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

samples/Sample_37_Comments.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
$textrun = $section->addTextRun();
1616
$textrun->addText('This ');
1717
$text = $textrun->addText('is');
18-
$text->setCommentStart($comment);
18+
$text->setCommentRangeStart($comment);
1919
$textrun->addText(' a test');
2020

2121
$section->addTextBreak(2);
@@ -28,10 +28,10 @@
2828
$textrunWithEnd = $section->addTextRun();
2929
$textrunWithEnd->addText('This ');
3030
$textToStartOn = $textrunWithEnd->addText('is', array('bold' => true));
31-
$textToStartOn->setCommentStart($commentWithStartAndEnd);
31+
$textToStartOn->setCommentRangeStart($commentWithStartAndEnd);
3232
$textrunWithEnd->addText(' another', array('italic' => true));
3333
$textToEndOn = $textrunWithEnd->addText(' test');
34-
$textToEndOn->setCommentEnd($commentWithStartAndEnd);
34+
$textToEndOn->setCommentRangeEnd($commentWithStartAndEnd);
3535

3636
$section->addTextBreak(2);
3737

@@ -42,7 +42,7 @@
4242
$imageComment->addText('red', array('color' => 'FF0000'));
4343
$phpWord->addComment($commentOnImage);
4444
$image = $section->addImage('resources/_mars.jpg');
45-
$image->setCommentStart($commentOnImage);
45+
$image->setCommentRangeStart($commentOnImage);
4646

4747
$section->addTextBreak(2);
4848

0 commit comments

Comments
 (0)