You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I know we can add a break property that takes a numeric value to a TextRun (IRunOptions). I am assuming that would add however many br elements to the run specified by the number. Is there any way to add the type="page" to that break? As of right now I am just creating an empty paragraph with the pageBreakBefore set. But if you want the break to happen mid paragraph, that is not going to work very well (you can kind of get around it by overriding the following paragraph indent properties if you really have to but that is a kludgy and calculation heavy way of handling it).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
@dolanmiu I was looking into how we can create page breaks mid-paragraph and saw this
https://stackoverflow.com/questions/2795315/create-page-break-using-openxml
I know we can add a break property that takes a numeric value to a TextRun (IRunOptions). I am assuming that would add however many br elements to the run specified by the number. Is there any way to add the type="page" to that break? As of right now I am just creating an empty paragraph with the pageBreakBefore set. But if you want the break to happen mid paragraph, that is not going to work very well (you can kind of get around it by overriding the following paragraph indent properties if you really have to but that is a kludgy and calculation heavy way of handling it).
Beta Was this translation helpful? Give feedback.
All reactions