DgsGetDxGUIFromResource

From Multi Theft Auto: Wiki
Jump to navigation Jump to search

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

Custom Cursor Functions

Multi Language Supports

Animation

3D Interface

3D Line

3D Image

3D Text

Browser

Button

Check Box

Combo Box

Custom Renderer

Edit

Detect Area

Drag'N Drop

Grid List

Image

Memo

Label

Line

Progress Bar

Radio Button

Scale Pane

Scroll Bar

Scroll Pane

Selector

Style

Switch Button

Tab Panel

Window

Plugin

Blur Box

Color Picker

Canvas

Circle

Effect 3D

Media Browser

Mask

Nine Slice

Object Preview Supports

Paste Handler

QRCode

Remote Image

Rounded Rectangle