Results 1 to 6 of 6

Thread: search strings help please

  1. #1

    Thread Starter
    Hyperactive Member jokerfool's Avatar
    Join Date
    Dec 2006
    Location
    Gold Coast, Australia
    Posts
    452

    search strings help please

    So on my form I have 2 forms, the top one shows the search box and the bottom form displays the result

    Code:
    VERSION 5.00
    Object = "{EAB22AC0-30C1-11CF-A7EB-0000C05BAE0B}#1.1#0"; "ieframe.dll"
    Begin VB.Form Form11 
       BackColor       =   &H00D8E9EC&
       BorderStyle     =   0  'None
       ClientHeight    =   13485
       ClientLeft      =   150
       ClientTop       =   435
       ClientWidth     =   13185
       LinkTopic       =   "Form1"
       MaxButton       =   0   'False
       ScaleHeight     =   899
       ScaleMode       =   3  'Pixel
       ScaleWidth      =   879
       StartUpPosition =   2  'CenterScreen
       Begin SHDocVwCtl.WebBrowser wbResults 
          Height          =   10095
          Left            =   120
          TabIndex        =   1
          Top             =   3360
          Width           =   12975
          ExtentX         =   22886
          ExtentY         =   17806
          ViewMode        =   0
          Offline         =   0
          Silent          =   0
          RegisterAsBrowser=   0
          RegisterAsDropTarget=   1
          AutoArrange     =   0   'False
          NoClientEdge    =   0   'False
          AlignLeft       =   0   'False
          NoWebView       =   0   'False
          HideFileNames   =   0   'False
          SingleClick     =   0   'False
          SingleSelection =   0   'False
          NoFolders       =   0   'False
          Transparent     =   0   'False
          ViewID          =   "{0057D0E0-3573-11CF-AE69-08002B2E1262}"
          Location        =   "Main Domain.com/"
       End
       Begin SHDocVwCtl.WebBrowser wbSearch 
          Height          =   2775
          Left            =   2760
          TabIndex        =   0
          ToolTipText     =   "Enter Search Here"
          Top             =   480
          Width           =   7455
          ExtentX         =   13150
          ExtentY         =   4895
          ViewMode        =   0
          Offline         =   0
          Silent          =   0
          RegisterAsBrowser=   0
          RegisterAsDropTarget=   1
          AutoArrange     =   0   'False
          NoClientEdge    =   0   'False
          AlignLeft       =   0   'False
          NoWebView       =   0   'False
          HideFileNames   =   0   'False
          SingleClick     =   0   'False
          SingleSelection =   0   'False
          NoFolders       =   0   'False
          Transparent     =   0   'False
          ViewID          =   "{0057D0E0-3573-11CF-AE69-08002B2E1262}"
          Location        =   "Main Domain.com/"
       End
    End
    Attribute VB_Name = "Form11"
    Attribute VB_GlobalNameSpace = False
    Attribute VB_Creatable = False
    Attribute VB_PredeclaredId = True
    Attribute VB_Exposed = False
    My question is based on this website
    Code:
    http://www.wowhead.com/
    Where I want the search box at the top and the results to be displayed in the box below. Can someone help me out please. I originally had this code for another website and would like to enhance apon that.

    Thank you.

  2. #2

    Thread Starter
    Hyperactive Member jokerfool's Avatar
    Join Date
    Dec 2006
    Location
    Gold Coast, Australia
    Posts
    452

    Re: search strings help please

    Isnt there anyone that can help me, or are the 60+ views from people who just have no clue in vb6?

  3. #3
    PowerPoster
    Join Date
    Dec 2004
    Posts
    25,618

    Re: search strings help please

    Isnt there anyone that can help me,
    probably, but it would have helped if you had posted your code, rather than just the form header
    i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
    Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next

    dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part

    come back and mark your original post as resolved if your problem is fixed
    pete

  4. #4
    PowerPoster Nightwalker83's Avatar
    Join Date
    Dec 2001
    Location
    Adelaide, Australia
    Posts
    13,344

    Re: search strings help please

    To load the code correctly you need to run the *.vbp file.
    when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    https://get.cryptobrowser.site/30/4111672

  5. #5
    PowerPoster
    Join Date
    Aug 2011
    Location
    B.C., Canada
    Posts
    2,887

    Re: search strings help please

    i am not 100% sure if this is what you are asking but here try this code

    Add
    -2 WebBrowser Control, "WebBrowser1" and "WebBrowser2" (do not need to change any properties)
    -1 Timer Control, "Timer1" (do not need to change any properties)

    Code:
    Private Sub Form_Load()
      Me.Height = 8985: Me.Width = 12870: Me.Caption = "Wowhead"
      WebBrowser1.Move 0, 0, 12615, 3495: WebBrowser1.Silent = True: WebBrowser1.Navigate "www.wowhead.com"
      WebBrowser2.Move 0, 3480, 12615, 4935: WebBrowser2.Silent = True
      Timer1.Interval = 400: Timer1.Enabled = True
    End Sub
    
    Private Sub Timer1_Timer()
      On Error Resume Next
      WebBrowser1.Document.ParentWindow.scrollTo 0, 0
    End Sub
    
    Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant)
      If Not WebBrowser1.LocationURL = "http://www.wowhead.com/" Then
        WebBrowser2.Navigate WebBrowser1.LocationURL
        WebBrowser1.Navigate "www.wowhead.com"
      End If
    End Sub
    I would make it with a simple textbox instead of two webbrowser... but like i said i am not 100% sure if you want a textbox control or a webbrowser control to display the webpage's textbox


    anyways for textbox code

    Add
    -1 TextBox Control, "Text1"
    -1 WebBrowser Control, "WebBrowser1"

    Code:
    Private Sub Form_Load()
      Me.Width = 7830: Me.Height = 7080
      Text1.Move 120, 120, 7335, 285
      WebBrowser1.Move 0, 480, 7575, 6015
    End Sub
    
    Private Sub Text1_KeyPress(KeyAscii As Integer)
      If KeyAscii = 13 Then WebBrowser1.Navigate "http://www.wowhead.com/search?q=" & Text1.Text: KeyAscii = 0
    End Sub

  6. #6
    PowerPoster
    Join Date
    Feb 2012
    Location
    West Virginia
    Posts
    14,206

    Re: search strings help please

    Quote Originally Posted by jokerfool View Post
    Isnt there anyone that can help me, or are the 60+ views from people who just have no clue in vb6?
    There are plenty here that are well versed in VB6 however you did not show any code in your OP nor did you actually ask a question.

    If you want an answer it always helps to ask a question and give any required details.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width