How to request IronPython to change x and y ratios in Map Appearance property?
I am an absolute newbie in IronPython. Also, as an early FORTRAN user, I never faced a strong need to learn any object-oriented language other than copy/pasting code snippets.
However I am now finalizing a Spotfire dashboard that requires to automate the following manual process:
1.Open Map visualization Properties window
2.Click on Appearance branch
3.Change the values for both Y and X Ratio Settings to other than default 1:1
I hope these values are the x and y described at https://docs.tibco.com/pub/doc_remote/sfire_dev/area/doc/api/TIB_sfire-analyst_api/?topic=html/M_Spotfire_Dxp_Application_Visuals_Maps_MapChartTransform_FromScales.htm in Spotfire API.
I am now trying to figure out the code to change it.
I made the below attempt that seemed to be logical for me without spending time on reading IronPython basics
from Spotfire.Dxp.Application.Visuals.Maps import * #v1 is defined in Script Parameters map=v1.As[MapChart]() map.MapChartTransform.FromScales().x = 2 map.MapChartTransform.FromScales().y = 150
but got the error message: "AttributeError: 'MapChart' object has no attribute 'MapChartTransform'"
I think I am close to the solution, but not exactly there. What would you recommend to change in my code other than RTFM?
Thanks in advance, Dmitry
PS: a mem, just in case "If you want users to RTFM, make better FMs"