We use the following macro in our Word template:
Sub AutoOpen()
'
' Resize Images
'
Dim page_width, page_height, aspect_ratio As Double
Dim ishape As InlineShape
' determine the current usable page width
page_width = ThisDocument.PageSetup.TextColumns.Width
' determine the current usable page height
page_height = ThisDocument.PageSetup.PageHeight - ThisDocument.PageSetup.TopMargin - ThisDocument.PageSetup.BottomMargin
ThisDocument.Activate
' Process each shape in the document
For Each ishape In ThisDocument.InlineShapes
' determine aspect ratio
aspect_ratio = ishape.Height / ishape.Width
' if the shape is taller than the page, make it's height match the page
If (ishape.Height > page_height) Then
ishape.Height = page_height
ishape.Width = (page_height / aspect_ratio)
End If
' if the shape is wider than the page, make it's wdith match the page
If (ishape.Width > (page_width * 0.9)) Then
ishape.Width = (page_width * 0.9)
ishape.Height = (ishape.Width * aspect_ratio)
End If
Next
' Process each shape in tables
For Each Tbl In ThisDocument.Tables
For Each ishape In Tbl.Range.InlineShapes
aspect_ratio = ishape.Height / ishape.Width
If ishape.Width > (Tbl.Range.Cells(3).Width * 0.9) Then
ishape.Width = (Tbl.Range.Cells(3).Width * 0.9)
ishape.Height = (ishape.Width * aspect_ratio)
End If
Next
Next Tbl
End Sub
I don't think that there is an easy way of resizing all images automatically in Jama. That's a manual change you have to do item by item.
Nevertheless, in the Admin section, there is a setting for the max. pixel size of images in rich text fields. You can try to adjust it, but it won't affect images which were already uploaded.


------------------------------
Patrick
------------------------------
Original Message:
Sent: 01-11-2023 10:20
From: Mohamed Elshal
Subject: Export Template Generation From a Default One
I was able to run some macros but with limited success. Alternatively, how can I resize all images on Jama before exporting?
I appreciate your support.
------------------------------
Mohamed Elshal
LGC Biosearch Technologies
MN
Original Message:
Sent: 01-11-2023 06:52
From: Barbara Haglind
Subject: Export Template Generation From a Default One
Hello:
You go to the Export and download the Default Word Template file. This will show you the field codes. Mr. Szabo had spoken about macros. For that you would need to turn on Developer mode in MS Word and create your macros in there.
Original Message:
Sent: 1/11/2023 9:50:00 AM
From: Mohamed Elshal
Subject: RE: Export Template Generation From a Default One
Thank you. If you don't mind, how can I find those macros to install in the template?
------------------------------
Mohamed Elshal
LGC Biosearch Technologies
MN
Original Message:
Sent: 01-10-2023 23:44
From: Patrick Szabo
Subject: Export Template Generation From a Default One
If you are using the simple Office template, you could also include a Macro in the template which is executed when the file is opened. We also do that to resize images and tables.
------------------------------
Patrick
Original Message:
Sent: 01-10-2023 14:14
From: Mohamed Elshal
Subject: Export Template Generation From a Default One
Thank you for your input. I was able to create the template I like; however, a big problem I ran into is formatting. All the diagrams I have don't fit the output page; and sometimes there is a large space and sometimes there is a small space between headings and texts; and between the different sections.
Is there a way I can create a more user-friendly format using the export template or Would I have to adjust the formatting of each item field in the project one by one before exporting?
------------------------------
Mohamed Elshal
LGC Biosearch Technologies
MN
Original Message:
Sent: 01-10-2023 02:33
From: Barbara Haglind
Subject: Export Template Generation From a Default One
Patrick I have found you don't have to be JAMA Support to upload a template based on the Default Word Template, you just need to be some kind of admin (project or organizational).
BIRT reports, on the other hand, you can only upload to your self-hosted JAMA. Cloud based will indeed require you to work with JAMA Support to upload them.
Disclaimer
The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.
This email has been scanned for viruses and malware, and may have been automatically archived by Mimecast, a leader in email security and cyber resilience. Mimecast integrates email defenses with brand protection, security awareness training, web security, compliance and other essential capabilities. Mimecast helps protect large and small organizations from malicious activity, human error and technology failure; and to lead the movement toward building a more resilient world.
Original Message:
Sent: 1/10/2023 5:03:00 AM
From: Patrick Szabo
Subject: RE: Export Template Generation From a Default One
Hi Mohamed,
are you on the Cloud or Self-Hosted version of Jama? On Cloud you usually have to request Jama Software Support for help. On Self-Hosted, an Admin can upload a customized template, which can be a simple Office Template, Velocity or a BIRT report.
Office templates can also be uploaded from the "All export options" window, or you can download the simple office templates from there, modify and upload again.

The "All Item Details" is a Velocity Report, which cannot be downloaded or modified (even in the Self-Hosted version). So you probably have to build it from scratch, or get in contact with Jama Support and ask them to provide the template and install it on your instance. But for modifying velocity reports, you would need to know how to write them.
------------------------------
Patrick
Original Message:
Sent: 01-09-2023 14:00
From: Mohamed Elshal
Subject: Export Template Generation From a Default One
Hi,
Ideally, I would like to add my company's logo, cover page, and headers and footers to "All Item Details" export Word templates in Jama. Is that possible or would I have to create my own template from scratch?
In other words, can I reuse one of the export templates available in Jama and add what I want to it?
------------------------------
Mohamed Elshal
LGC Biosearch Technologies
MN
------------------------------