Skip to main content

Control Class

#Declaration

TypeScript
class Control

#Remarks

IMPORTANT

Bootstrap Controls for ASP.NET Core are in maintenance mode. We don’t add new controls or develop new functionality for this product line. Our recommendation is to use the ASP.NET Core Controls suite.

#Properties

#name Property

#Declaration

TypeScript
readonly name: string

#Property Value

Type
string

#Methods

#adjustControl Method

#Declaration

TypeScript
adjustControl(): void

#getHeight Method

#Declaration

TypeScript
getHeight(): number

#Returns

Type
number

#getMainElement Method

#Declaration

TypeScript
getMainElement(): any

#Returns

Type
any

#getParentControl Method

#Declaration

TypeScript
getParentControl(): any

#Returns

Type
any

#getVisible Method

#Declaration

TypeScript
getVisible(): boolean

#Returns

Type
boolean

#getWidth Method

#Declaration

TypeScript
getWidth(): number

#Returns

Type
number

#inCallback Method

#Declaration

TypeScript
inCallback(): boolean

#Returns

Type
boolean

#off<K> Method

#Declaration

TypeScript
off<K extends keyof ControlEventMap>(): this

#Type Parameters

Name Type
K keyof

#Returns

Type
this

#off<K>(eventName) Method

#Declaration

TypeScript
off<K extends keyof ControlEventMap>(
    eventName: K
): this

#Parameters

Name Type
eventName K

#Type Parameters

Name Type
K keyof

#Returns

Type
this

#off<K>(eventName, callback) Method

#Declaration

TypeScript
off<K extends keyof ControlEventMap>(
    eventName: K,
    callback: (this: Control,
    args?: ControlEventMap[K]) => void
): this

#Parameters

Name Type
eventName K
callback (this: Control, args?: ControlEventMap[K]) => void

#Type Parameters

Name Type
K keyof

#Returns

Type
this

#on<K>(eventName, callback) Method

#Declaration

TypeScript
on<K extends keyof ControlEventMap>(
    eventName: K,
    callback: (this: Control,
    args?: ControlEventMap[K]) => void
): this

#Parameters

Name Type
eventName K
callback (this: Control, args?: ControlEventMap[K]) => void

#Type Parameters

Name Type
K keyof

#Returns

Type
this

#once<K>(eventName, callback) Method

#Declaration

TypeScript
once<K extends keyof ControlEventMap>(
    eventName: K,
    callback: (this: Control,
    args?: ControlEventMap[K]) => void
): this

#Parameters

Name Type
eventName K
callback (this: Control, args?: ControlEventMap[K]) => void

#Type Parameters

Name Type
K keyof

#Returns

Type
this

#sendMessageToAssistiveTechnology(message) Method

#Declaration

TypeScript
sendMessageToAssistiveTechnology(
    message: string
): void

#Parameters

Name Type
message string

#setHeight(height) Method

#Declaration

TypeScript
setHeight(
    height: number
): void

#Parameters

Name Type
height number

#setVisible(visible) Method

#Declaration

TypeScript
setVisible(
    visible: boolean
): void

#Parameters

Name Type
visible boolean

#setWidth(width) Method

#Declaration

TypeScript
setWidth(
    width: number
): void

#Parameters

Name Type
width number