Word Report generator Tableau Empecher une ligne de tablerau de se mettre sur 2 pages
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Daniel MONTERRAIN
il 22 Ago 2023
Modificato: Kausthub
il 14 Set 2023
bonjour
J'exporte des données matlab vers des tableaux word avec le report generator.
Parfois une ligne s"'imprime sur 2 pages. Je voudrait empêcher cela enforcanbt la nouvelle ligne du tableau à s"'imprimer surla pas suivante.
J'ai vu qu'il faut utiliser l'objet AllowBreakAcrossPages(tf) avec tf= false
mais je n'arrive pas à comprendre comment utiliser cette commande ou cet objet.
est ce qu'il faut l'associer au tableau oiu à chaque ligne et comment ?. (dans Style?)
il me faudrait un exemple de mise en oeuvre de cet objet sur un tableau
Merci
0 Commenti
Risposta accettata
Kausthub
il 1 Set 2023
Modificato: Kausthub
il 14 Set 2023
Hi Daniel Monterrain,
I understand that when the table overflows, you would like it in the next page rather than the next line and you need guidance on how to use the AllowBreakAcrossPages() class.
You can refer to the example in the MATLAB command-line help for this class:
>> help mlreportgen.dom.AllowBreakAcrossPages
Yes, you are right about using the AllowBreakAcrossPages(), it should be used with “style” and should be associated to a row.
For example:
table.row(6).Style = {AllowBreakAcrossPages(false)};
Here is the documentation to the AllowBreakAcrossPages():
Hope it helps!
3 Commenti
Kausthub
il 7 Set 2023
Modificato: Kausthub
il 7 Set 2023
I have attached a working example and the corresponding output pictures and you could manipulate it as per your needs.
Please run the testPageBreak.m file and try commenting and uncommenting line 31 in the example to see the difference.
table.row(3).Style = {AllowBreakAcrossPages(false)};
Hope this helps!
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!