¿ªÔÆÌåÓý

Locked PanelPro # of Panels (Panel Count)


 

Team, I have 30+ panels created and I am curious if PanelPro can give me the total # of control panels that have been created? i.e. a panel count.


 

Vinny,

This little script will show the number of panels.

import java
import jmri

mgr = jmri.InstanceManager.getDefault(jmri.jmrit.display.EditorManager)
panels = mgr.getAll()
print 'There are {} panels'.format(len(panels))

Dave Sand


----- Original message -----
From: Vinny DeRobertis <vinny.derobertis@...>
Subject: [jmriusers] PanelPro # of Panels (Panel Count)
Date: Sunday, December 10, 2023 12:25 PM

Team, I have 30+ panels created and I am curious if PanelPro can give me the total # of control panels that have been created? i.e. a panel count.


 

Vinny,

This version also lists the panel titles.

import java
import jmri

mgr = jmri.InstanceManager.getDefault(jmri.jmrit.display.EditorManager)
panels = mgr.getAll()

print '\nThere are {} panels\n'.format(len(panels))

for panel in panels:
??? print '??? {}'.format(panel.getTitle())

Dave Sand


----- Original message -----
From: Dave Sand <ds@...>
Subject: Re: [jmriusers] PanelPro # of Panels (Panel Count)
Date: Sunday, December 10, 2023 12:39 PM

Vinny,

This little script will show the number of panels.

import java
import jmri

mgr = jmri.InstanceManager.getDefault(jmri.jmrit.display.EditorManager)
panels = mgr.getAll()
print 'There are {} panels'.format(len(panels))

Dave Sand


----- Original message -----
From: Vinny DeRobertis <vinny.derobertis@...>
Subject: [jmriusers] PanelPro # of Panels (Panel Count)
Date: Sunday, December 10, 2023 12:25 PM

Team, I have 30+ panels created and I am curious if PanelPro can give me the total # of control panels that have been created? i.e. a panel count.



 

I'll give that a try!
Thank you for the quick response, Dave!