multishell.getCurrent

From ComputerCraft Wiki
Jump to: navigation, search



Grid Redstone.png  Function multishell.getCurrent
Returns the tab ID of the currently running program. You can use this along with other multishell functions, such as, multishell.getTitle and multishell.setTitle.
Syntax multishell.getCurrent()
Returns number tabID
Part of ComputerCraft
API multishell

Examples

Grid paper.png  Example
Gets the currently running tab and prints it's title.
Code
local currentTabID = multishell.getCurrent()

print(multishell.getTitle(currentTabID))
Output The title of the currently running program (tab)
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox