Skip to content

format

typescript
Control.Hide()

class: Control

description

Hide the control.

The hidden control will not be rendered on the screen and will not respond to interaction events.

parameter

param_nametypedescription

reture

typedescription
void

code example

typeScript
let go = new GameObject("ui");
let uiComponent = go.AddComponent<UIComponent>(UIComponent);
let canvas = uiComponent.canvas;		
let button = canvas.FindChild("Button");
button.Hide();