ZTzTopiaa Posted April 21, 2019 Share Posted April 21, 2019 local note = gg.prompt( {'Please input text'}, {[1]='text'}, {[1]='text'} ) if note[1] == nil then gg.alert('Canceled') end if note[1] == novalue then gg.alert('Input text') end help me i want if people not input text on gg.prompt then gg.alert('input text') Link to comment Share on other sites More sharing options...
ZTzTopiaa Posted April 21, 2019 Author Share Posted April 21, 2019 wtf why you not understand Link to comment Share on other sites More sharing options...
maulz Posted April 21, 2019 Share Posted April 21, 2019 while true do local sel = gg.prompt({"Write something:"}, nil, {"text"}) if not sel then break end local t = string.len(sel[1]) if t == 0 then gg.alert("Please write something") else gg.alert(sel[1]) break end end Link to comment Share on other sites More sharing options...
ZTzTopiaa Posted April 22, 2019 Author Share Posted April 22, 2019 20 hours ago, maulz said: while true do local sel = gg.prompt({"Write something:"}, nil, {"text"}) if not sel then break end local t = string.len(sel[1]) if t == 0 then gg.alert("Please write something") else gg.alert(sel[1]) break end end Thx Link to comment Share on other sites More sharing options...
Question
ZTzTopiaa
local note = gg.prompt(
{'Please input text'},
{[1]='text'},
{[1]='text'}
)
if note[1] == nil then
gg.alert('Canceled')
end
if note[1] == novalue then
gg.alert('Input text')
end
help me i want if people not input text on gg.prompt then gg.alert('input text')
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.