Forum

Author Topic: Export Report User Settings  (Read 296 times)

SamT

  • Newbie
  • *
  • Posts: 30
    • View Profile
Export Report User Settings
« on: June 15, 2020, 01:02:34 AM »
Hi Everyone!

Having some trouble adding user settings to exportReport().

User manual specifies "list of (string, string) tuples" for the user_settings parameter.

Code: [Select]
import os

import Metashape

doc = Metashape.app.document
chunk = doc.chunk

user_settings = [('Test 1', 'Value 1'), ('Test 2', 'Value 2')]

output_file = os.path.join(os.path.join(os.environ['USERPROFILE']), 'Desktop/test.pdf')
chunk.exportReport(path=output_file, user_settings=user_settings)

Error: ValueError: Invalid argument value: user_settings

Metashape version 1.6.2
« Last Edit: June 15, 2020, 04:27:08 AM by SamT »

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 11775
    • View Profile
Re: Export Report User Settings
« Reply #1 on: June 27, 2020, 02:27:14 AM »
Hello SamT,

Similar example works fine in Metashape 1.6.3 (build 10732).
Best regards,
Alexey Pasumansky,
AgiSoft LLC