Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Search instead for 
Did you mean: 
xoceunder
Level 7

Problem with code

Problem with code

		dlg = CreateObject("roMessageDialog")
dlg.setTitle(tr("You have a message!"))
dlg.setText(json.msg)
dlg.addButton(1, tr("Accept"))
dlg.setMessagePort(createObject("roMessagePort"))
dlg.EnableBackButton(true)
dlg.show()

while true
msg = wait(0, dlg.getMessagePort())
if type(msg) = "roMessageDialogEvent"
              if msg.isButtonPressed()
                if msg.GetIndex() = 1
                   url = Url()+"/RokDev/mej.php"
                   post = "device="+device
                   body = read_body_and_headers(url,post)
      exit while
                end if
              end if
endif
end while

dlg.Close()


BRIGHTSCRIPT: WARNING: roMessageDialog: This component is deprecated:
0 Kudos
1 Reply
destruk
Level 10

Re: Problem with code

If that is the only problem, then converting to scenegraph will be really easy for you.
Download this and implement it and you're done.
https://sdkdocs.roku.com/display/sdkdoc ... xample.zip
0 Kudos