none
Web site/URL interaction RRS feed

  • Question

  • is it possible to create or call a URL from Small Basic?  it would great if I could build and call URLS.
    Monday, September 7, 2009 5:02 AM

Answers

  • This code will make a webbrowser, not in the same league as Internet Explorer!!

    GraphicsWindow.Show()
    GraphicsWindow.width=1024
    GraphicsWindow.height=740
    txtbx1=Controls.AddTextBox(900,20,"")
    browser=controls.AddWebBrowser(1024,720)
    Controls.Move(browser,0,20)
    txtbx2=Controls.AddButton(100,20,"Go")
    Controls.Move(txtbx2,900,0)

    Controls.RegisterEvent(txtbx2,"mousedownevent","seturl")


    Sub seturl
     
      dtxt=Controls.GetText(txtbx1)
      Controls.SetUrlOfWebBrowser(browser,dtxt)
    EndSub

    I think that the fremy extensions should be part of smallbasic as they are so useful.

    Monday, September 7, 2009 8:36 PM

All replies

  • This is possible with the fremyextension.

    The code is;

    GraphicsWindow.Show()
    browser=Controls.AddWebBrowser(1024,720)
    Controls.SetUrlOfWebBrowser(browser,"www.google.co.uk")

    This opens up a simple browser, to which you can add other controls.
    Monday, September 7, 2009 9:26 AM
  • This code will make a webbrowser, not in the same league as Internet Explorer!!

    GraphicsWindow.Show()
    GraphicsWindow.width=1024
    GraphicsWindow.height=740
    txtbx1=Controls.AddTextBox(900,20,"")
    browser=controls.AddWebBrowser(1024,720)
    Controls.Move(browser,0,20)
    txtbx2=Controls.AddButton(100,20,"Go")
    Controls.Move(txtbx2,900,0)

    Controls.RegisterEvent(txtbx2,"mousedownevent","seturl")


    Sub seturl
     
      dtxt=Controls.GetText(txtbx1)
      Controls.SetUrlOfWebBrowser(browser,dtxt)
    EndSub

    I think that the fremy extensions should be part of smallbasic as they are so useful.

    Monday, September 7, 2009 8:36 PM