DgsGetDxGUIFromResource

From Multi Theft Auto: Wiki

This function is used to get DGS elements which were created by other resources.

Syntax

table dgsGetDxGUIFromResource( [ resource res ] )

Required Arguments

None

Optional Arguments

  • res: The resource which DGS elements were created by.

Returns

Returns a table containing DGS elements which were created by the resource, false otherwise.

Example

DGS = exports.dgs
for i=1,10 do
	DGS:dgsCreateLabel ( math.random(0,1),math.random(0,1),0.2,0.1, "Hello world"..i, true ) --Create Labels without storing into variables.
end

for k,v in ipairs(DGS:dgsGetDxGUIFromResource()) do --Get All DGS Dx GUIs that created by this resource.
	if DGS:dgsGetType(v) == "dgs-dxlabel" then
		local text = DGS:dgsGetText(v)  --Get Label Text.
		outputChatBox(text) --Out put Label Text.
	end
end

See Also

Multi Language Supports

Animation

3D Interface

3D Text

Arrow List

Browser

Button

Check Box

Combo Box

Custom Renderer

Edit

Ellipse Detect Area

Detect Area

Grid List

Image

Memo

Label

Progress Bar

Radio Button

Scroll Bar

Scroll Pane

Switch Button

Tab Panel

Window

Plugin

Media Browser

Rounded Rectangle

Color Picker

Blur Box

Effect 3D

Nine Slice

Object Preview

QRCode

mask