从Spotfire.Dxp.Application导入书签
从Spotfire.Dxp.Application.AnalyticItems导入BookmarkManager
从Spotfire.Dxp.Application导入BookmarkComponentFlags
从Spotfire.Dxp.Application导入页面
Page1 == Document.Properties ['PageName']
如果Page1 =“第一年”
Document.ActivePageReference = Document.Pages [1]
https://community.tibco.com/questions/how-navigate-another-page-when-click-cross-table
答案 0 :(得分:2)
您的IronPython有两个错误。这是固定版本。当您从document属性设置Page1的值时,您需要使用一个等于而不是两个。然后,当您检查Page1是否等于“第一年”时,您需要使用两个等于而不是一个。最后,在if语句后需要一个冒号。
from Spotfire.Dxp.Application import Bookmark
from Spotfire.Dxp.Application.AnalyticItems import BookmarkManager
from Spotfire.Dxp.Application import BookmarkComponentFlags
from Spotfire.Dxp.Application import Page
Page1=Document.Properties['PageName']
print Page1
if Page1=="First Year":
Document.ActivePageReference=Document.Pages[1]
这负责脚本。现在是交叉表。 Spotfire不允许响应交叉表上的点击。为此,您将需要使用图形表。您可以使用图形表而不是交叉表来创建同一表。需要做更多的工作,因为您需要添加一个计算值轴,然后在该轴的“动作”下连接IronPython脚本。