DgsEditGetReadOnly

From Multi Theft Auto: Wiki

This function allows you to get read-only status for a dgs edit box.

Syntax

bool dgsEditGetReadOnly ( element edit )

Required Arguments

  • edit: The dgs-dxedit that you want to get.

Returns

Returns a boolean value of the read-only status of the dgs edit.

Example

DGS = exports.dgs 
myWebsite = "development.mtasa.com" -- define the text to be displayed in advert field
function createAdvert( )
	local advert = DGS:dgsCreateEdit( 0.845, 0.94, 0.15, 0.05, myWebsite, true ) -- create edit field for the advert
	outputChatBox("The edit is"..(DGS:dgsEditGetReadOnly ( advert ) and " not" or "") .." editable")
	if advert then -- if it was successfully created
		DGS:dgsEditSetReadOnly( advert, true ) -- make it read only
	end
	outputChatBox("The edit is"..(DGS:dgsEditGetReadOnly ( advert ) and " not" or "") .." editable")
end
addEventHandler ( "onClientResourceStart", getResourceRootElement( getThisResource() ), createAdvert )

See Also

Multi Language Supports

Animation

3D Interface

3D Text

Browser

Button

Check Box

Combo Box

Custom Renderer

Edit

Detect Area

Grid List

Image

Memo

Label

Progress Bar

Radio Button

Scroll Bar

Scroll Pane

Selector

Switch Button

Tab Panel

Window

Plugin

Blur Box

Color Picker

Canvas

Effect 3D

Media Browser

Mask

Nine Slice

Object Preview Supports

QRCode

Remote Image

Rounded Rectangle