Guidance
指路人
g.yi.org
software / rapidq / Examples / COM & OLE / Internet Projects / test.bas

Register 
注册
Search 搜索
首页 
Home Home
Software
Upload

  
     $TYPECHECK OFF
     $APPTYPE GUI
     $INCLUDE "Rapidq.Inc"

     DIM button1.Clicked AS QLABEL
     DIM MenuItem(100) AS QMENUITEM
     DIM buttonclicked AS INTEGER

     DECLARE SUB MenuItemClick (Sender AS QMENUITEM)
     DECLARE SUB Label1Click (Sender AS QLABEL)
     DECLARE SUB FormSize (Sender AS QFORM)
     DECLARE SUB ESCAPE



''    Search engine strings
''    "http://www.google.com/search?hl=en&ie=UTF-8&oe=UTF-8&q="+ +"%21&btnG=Google+Search"
''    "http://www.altavista.digital.com/cgi-bin/query?pg=q&what=web&fmt=.&q=" + searchString
''    "http://av.yahoo.com/bin/query?p=" + searchString + "&hc=0&hs=0"
''    "http://www.excite.com/search.gw?trace=a&search=" + searchString
''    "http://www.hotbot.com/?SW=web&SM=MC&MT=" + searchString + "&DC=10&DE=2&RG=NA&_v=2&act.search.x=89&act.search.y=7"
''    "http://www.infoseek.com/Titles?qt=" + searchString + "&col=WW&sv=IS&lk=noframes&nh=10"
''    "http://www.lycos.com/cgi-bin/pursuit?adv=%26adv%3B&cat=lycos&matchmode=and&query=" + searchString + "&x=45&y=11"
''    "http://netfind.aol.com/search.gw?search=" + searchString + "&c=web&lk=excite_netfind_us&src=1"
''    "http://search.news.yahoo.com/search/news?p=" + searchString +""
''    "http://maps.yahoo.com/py/maps.py?&addr=" + searchString + ""
''    "http://yp.yahoo.com/yt.hm?FAM=yahoo&CMD=GEODB&SEC=geocode&uSUB=&GCT=&RS=2&NR=10&AD3=" + searchString + ""
''    "http://finance.yahoo.com/q?s=+" + searchString + "&d=v1"
''    "http://search.weather.yahoo.com/weather/query.cgi?q=" + searchString + ""
''    "http://search.news.yahoo.com/search/news?p="+ searchString + ""
''    "http://www.exactseek.com/cgi-bin/search.cgi/"+ searchString + ""
''
'' Source code bugs:
'' 1. run-time error 216 at 71704AEE - may boot your ass off yahoo chat...


     DECLARE SUB Button1Click (Sender AS QBUTTON)
     DECLARE SUB CheckBox1Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox2Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox3Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox4Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox5Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox6Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox7Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox8Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox9Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox10Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox11Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox12Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox13Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox14Click (Sender AS QCHECKBOX)
     DECLARE SUB CheckBox15Click (Sender AS QCHECKBOX)

     CREATE Form AS QFORM
      CAPTION = "Form1"
      Width = 826
      Height = 376
      Center

      OnClick = ESCAPE
      AutoScroll=0
      OnResize = FormSize

      CREATE MainMenu AS QMAINMENU
       CREATE FileMenu AS QMENUITEM
        CAPTION = "&Help"
        CREATE OpenItem AS QMENUITEM
         CAPTION = "&ABOUT"
         Hint = "HELP ME !"
         OnClick =  MenuItemClick
        END CREATE
       END CREATE
      END CREATE


      CREATE Edit1 AS QEDIT
       Text = ""
       Left = 299
       Top = 0
       Width = 513
       Height = 29
      END CREATE
      CREATE Button1 AS QBUTTON
       CAPTION = "&Go Search:"
       Left = 216
       Top = 4
       TabOrder = 1
       OnClick = Button1Click
      END CREATE
      CREATE CheckBox1 AS QCHECKBOX
       CAPTION = "Google"
       Left = 9
       Top = 32
       TabOrder = 2
       OnClick = CheckBox1Click
      END CREATE
      CREATE CheckBox2 AS QCHECKBOX
       CAPTION = "Yahoo!"
       Left = 110
       Top = 0
       TabOrder = 3
       OnClick = CheckBox2Click
      END CREATE
      CREATE CheckBox3 AS QCHECKBOX
       CAPTION = "Yahoo.com"
       Left = 9
       Top = 16
       TabOrder = 4
       OnClick = CheckBox3Click
      END CREATE
      CREATE CheckBox4 AS QCHECKBOX
       CAPTION = "excite"
       Left = 9
       Top = 0
       TabOrder = 5
       OnClick = CheckBox4Click
      END CREATE
      CREATE CheckBox5 AS QCHECKBOX
       CAPTION = "hotbot"
       Left = 9
       Top = 64
       TabOrder = 6
       OnClick = CheckBox5Click
      END CREATE
      CREATE CheckBox6 AS QCHECKBOX
       CAPTION = "infoseek"
       Left = 9
       Top = 48
       TabOrder = 7
       OnClick = CheckBox6Click
      END CREATE
      CREATE CheckBox7 AS QCHECKBOX
       CAPTION = "lycos"
       Left = 110
       Top = 32
       TabOrder = 8
       OnClick = CheckBox7Click
      END CREATE
      CREATE CheckBox8 AS QCHECKBOX
       CAPTION = "altavista"
       Left = 110
       Top = 16
       TabOrder = 9
       OnClick = CheckBox8Click
      END CREATE
      CREATE CheckBox9 AS QCHECKBOX
       CAPTION = "NetFind-AOL"
       Left = 110
       Top = 48
       TabOrder = 10
       OnClick = CheckBox9Click
      END CREATE
      CREATE CheckBox10 AS QCHECKBOX
       CAPTION = "Y! Maps"
       Left = 110
       Top = 64
       TabOrder = 19
       OnClick = CheckBox10Click
      END CREATE
      CREATE CheckBox11 AS QCHECKBOX
       CAPTION = "Yellow-Pages"
       Left = 214
       Top = 32
       TabOrder = 20
       OnClick = CheckBox11Click
      END CREATE
      CREATE CheckBox12 AS QCHECKBOX
       CAPTION = "finance Y!"
       Left = 214
       Top = 48
       TabOrder = 21
       OnClick = CheckBox12Click
      END CREATE
      CREATE CheckBox13 AS QCHECKBOX
       CAPTION = "Weather"
       Left = 214
       Top = 64
       TabOrder = 22
       OnClick = CheckBox13Click
      END CREATE
      CREATE CheckBox14 AS QCHECKBOX
       CAPTION = "news"
       Left = 302
       Top = 32
       TabOrder = 23
       OnClick = CheckBox14Click
      END CREATE
      CREATE CheckBox15 AS QCHECKBOX
       CAPTION = "Exactseek"
       Left = 302
       Top = 48
       TabOrder = 24
       OnClick = CheckBox15Click
      END CREATE

      CREATE Explorer AS QOLECONTAINER
       Top=100
       Width=Form.ClientWidth
       Height = Form.ClientHeight
       Align=2
      END CREATE
     END CREATE





     IF Form.SHOWMODAL THEN
      Form.CLOSE
      IF label1clicked>0 THEN
       Explorer.Free
      END IF
     END IF

     Form.SHOWMODAL


     SUB Button1Click (Sender AS QBUTTON)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$=edit1.text
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB MenuItemClick (Sender AS QMENUITEM)
      CREATE Form2 AS QFORM
       CAPTION = "HELP ! "
       Width = 411
       Height = 108
       Center
       CREATE Label1x AS QLABEL
        CAPTION = "Fully Tested on the windows XP home edition operating system"
        Left = 8
        Top = 6
        Width = 360
       END CREATE
       CREATE Label2x AS QLABEL
        CAPTION = "This program is just a simple search engine exploiter  robot."
        Left = 7
        Top = 21
        Width = 312
        Transparent = 1
       END CREATE
       CREATE Label3x AS QLABEL
        CAPTION = "Sorry but I don’t have a lot of decimation on this program.."
        Left = 9
        Top = 54
        Width = 336
        Transparent = 1
       END CREATE
      END CREATE
      Form2.SHOWMODAL
     END SUB



     SUB CheckBox1Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.google.com/search?hl=en&ie=UTF-8&oe=UTF-8&q="+ edit1.text +"%21&btnG=Google+Search"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox2Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://search.yahoo.com/bin/search?p=" + edit1.text
       Explorer.Navigate(html$)
      END IF

     END SUB

     SUB CheckBox3Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://av.yahoo.com/bin/query?p=" + edit1.text + "&hc=0&hs=0"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox4Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")

       html$="http://www.excite.com/search.gw?trace=a&search=" + edit1.text
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox5Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.hotbot.com/?SW=web&SM=MC&MT=" + edit1.text + "&DC=10&DE=2&RG=NA&_v=2&act.search.x=89&act.search.y=7"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox6Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.infoseek.com/Titles?qt=" + edit1.text + "&col=WW&sv=IS&lk=noframes&nh=10"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox7Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.lycos.com/cgi-bin/pursuit?adv=%26adv%3B&cat=lycos&matchmode=and&query=" + edit1.text + "&x=45&y=11"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox8Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.altavista.digital.com/cgi-bin/query?pg=q&what=web&fmt=.&q=" + edit1.text
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox9Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://netfind.aol.com/search.gw?search=" + edit1.text + "&c=web&lk=excite_netfind_us&src=1"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox10Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://maps.yahoo.com/py/maps.py?&addr=" + edit1.text + ""
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox11Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://yp.yahoo.com/yt.hm?FAM=yahoo&CMD=GEODB&SEC=geocode&uSUB=&GCT=&RS=2&NR=10&AD3=" + edit1.text + ""
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox12Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://finance.yahoo.com/q?s=+" + edit1.text + "&d=v1"
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox13Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://search.weather.yahoo.com/weather/query.cgi?q=" + edit1.text + ""
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox14Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://search.news.yahoo.com/search/news?p="+ edit1.text + ""
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB CheckBox15Click (Sender AS QCHECKBOX)
      button1clicked=1
      IF button1.Clicked=1 THEN
       Explorer.Width=Form.Width
       Explorer.Height=Form._
        ClientHeight
       Explorer.CreateObject_
        ("Shell.Explorer.1")
       html$="http://www.exactseek.com/cgi-bin/search.cgi/"+ edit1.text + ""
       Explorer.Navigate(html$)
      END IF
     END SUB

     SUB ESCAPE
      Explorer.Navigate("c:")
     END SUB





































掌柜推荐
 
 
 
 
 
 
 
 
 
 
 
 
© Mon 2024-3-4  Guidance Laboratory Inc.
Email:webmaster1g.yi.org Hits:0 Last modified:2002-12-06 06:15:48