home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Object = "{3B7C8863-D78F-101B-B9B5-04021C009402}#1.2#0"; "RICHTX32.OCX"
- Object = "{48E59290-9880-11CF-9754-00AA00C00908}#1.0#0"; "MSINET.OCX"
- Begin VB.Form CCDid
- Caption = "Form1"
- ClientHeight = 8190
- ClientLeft = 1620
- ClientTop = 1545
- ClientWidth = 11295
- LinkTopic = "Form1"
- ScaleHeight = 8190
- ScaleWidth = 11295
- Begin VB.CommandButton Command4
- Caption = "CDDB STATS"
- Height = 375
- Left = 7920
- TabIndex = 21
- Top = 6960
- Width = 1455
- End
- Begin VB.CommandButton Command3
- Caption = "CDDB HELP"
- Height = 375
- Left = 7920
- TabIndex = 20
- Top = 6480
- Width = 1455
- End
- Begin VB.CommandButton Command2
- Caption = "CDDB SITES"
- Height = 375
- Left = 7920
- TabIndex = 19
- Top = 6000
- Width = 1455
- End
- Begin InetCtlsObjects.Inet It
- Left = 10680
- Top = 7560
- _ExtentX = 1005
- _ExtentY = 1005
- _Version = 393216
- URL = "http://"
- RequestTimeout = 10
- End
- Begin VB.TextBox QS
- Height = 855
- Left = 7920
- MultiLine = -1 'True
- TabIndex = 8
- Text = "Form1.frx":0000
- Top = 1440
- Width = 3255
- End
- Begin VB.CommandButton Command1
- Caption = "PARSE DATA"
- Height = 375
- Left = 7920
- TabIndex = 7
- Top = 5520
- Width = 1455
- End
- Begin RichTextLib.RichTextBox T
- Height = 7695
- Left = 0
- TabIndex = 6
- Top = 480
- Width = 7815
- _ExtentX = 13785
- _ExtentY = 13573
- _Version = 393217
- Enabled = -1 'True
- ScrollBars = 2
- TextRTF = $"Form1.frx":0006
- End
- Begin VB.TextBox txtID
- Height = 285
- Left = 7920
- TabIndex = 5
- Top = 720
- Width = 975
- End
- Begin VB.CommandButton btnCalc
- Caption = "QUERY CDDB"
- Height = 375
- Left = 7920
- TabIndex = 4
- Top = 3600
- Width = 1455
- End
- Begin VB.ComboBox CB
- Height = 315
- Left = 7920
- TabIndex = 3
- Top = 2760
- Width = 1455
- End
- Begin VB.CommandButton btnExit
- Caption = "CLOSE"
- Height = 375
- Left = 7920
- TabIndex = 2
- Top = 7800
- Width = 1455
- End
- Begin VB.TextBox txtURL
- Height = 285
- Left = 0
- TabIndex = 1
- Top = 120
- Width = 11295
- End
- Begin VB.CommandButton cmdShowURL
- Caption = "GET DATA"
- Height = 375
- Left = 7920
- TabIndex = 0
- Top = 4560
- Width = 1455
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "WHATEVER"
- Height = 195
- Index = 5
- Left = 8160
- TabIndex = 18
- Top = 5280
- Width = 1290
- WordWrap = -1 'True
- End
- Begin VB.Label Label1
- Caption = "4)"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- Height = 255
- Index = 3
- Left = 7920
- TabIndex = 17
- Top = 5280
- Width = 255
- End
- Begin VB.Label Label1
- Caption = "3)"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- Height = 255
- Index = 2
- Left = 7920
- TabIndex = 16
- Top = 4320
- Width = 255
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "DISPLAY DATA"
- Height = 195
- Index = 4
- Left = 8160
- TabIndex = 15
- Top = 4320
- Width = 1290
- WordWrap = -1 'True
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "QUERY CDDB WEB SITE"
- Height = 255
- Index = 3
- Left = 8160
- TabIndex = 14
- Top = 3360
- Width = 2010
- WordWrap = -1 'True
- End
- Begin VB.Label Label1
- Caption = "2)"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- Height = 255
- Index = 1
- Left = 7920
- TabIndex = 13
- Top = 3360
- Width = 255
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "SELECT CD DRIVE"
- Height = 195
- Index = 2
- Left = 8160
- TabIndex = 12
- Top = 2520
- Width = 1515
- WordWrap = -1 'True
- End
- Begin VB.Label Label1
- Caption = "1)"
- BeginProperty Font
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 700
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- Height = 255
- Index = 0
- Left = 7920
- TabIndex = 11
- Top = 2520
- Width = 255
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "UNIQUE DISC ID"
- Height = 315
- Index = 1
- Left = 7920
- TabIndex = 10
- Top = 480
- Width = 1275
- WordWrap = -1 'True
- End
- Begin VB.Label Label2
- AutoSize = -1 'True
- Caption = "QUERY STRING TO SEND"
- Height = 195
- Index = 0
- Left = 7920
- TabIndex = 9
- Top = 1200
- Width = 1995
- WordWrap = -1 'True
- End
- Attribute VB_Name = "CCDid"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- ' IF CONNECTION IS IMPOSSIBLE, TRY THIS SAMPLE AS A URL IN A BROWSER:
- 'http://cddb.cddb.com/~cddb/cddb.cgi/?cmd=cddb+read+rock+a10c480c&hello=BUZZLE+AA.BB.COM+CDclient+2.1&proto=4
- Private Const Sd1 = "http://cddb.cddb.com/~cddb/cddb.cgi/?cmd="
- Private Const Sd2 = "&hello=buzzle+no.host.com+NON+0.1&proto=4"
- Function Src(URL As String) As String
- On Error GoTo drt
- Src = It.OpenURL(URL)
- Select Case It.ResponseCode
- Case 0: Resume Next
- Case Else: MsgBox It.ResponseCode
- End Select
- End Function
- Private Sub cmdShowURL_Click()
- Dim FND1%, Gn$, X$, XX$, DD$
- Dim MyCD As New CCd, Y$, Z$
- Dim Gen
- Gen = Array("rock", "country", "soundtrack", "classical", _
- "newage", "blues", "folk", "jazz", "reggae", "misc") 'ORDER NOT IMPORTANT
- FND1 = T.Find("210", , , 2 Or 8)
- If Not FND1 = 0 Then FND1 = T.Find("200", , , 2 Or 8)
- If FND1 = 0 Then
- For i = 0 To 10
- If T.Find(Gen(i), 4, , 2 Or 8) > -1 Then
- Gn = Gen(i)
- Exit For
- End If
- Next
- End If
- XX = Sd1 & "cddb+read+" & Gn & "+" & txtID & Sd2
- T.TextRTF = Src(XX)
- txtURL.Text = XX
- End Sub
- Private Sub btnCalc_Click()
- Dim MyCD As New CCd, X$, Y$, Z$, Drv$
- If DvT(CB.Text) = 5 Then
- MyCD.Init CB.Text
- Else
- MsgBox "Drive is not a CD."
- Exit Sub
- End If
- txtID.Text = MyCD.DiscID
- QS = MyCD.QueryString
- X = Sd1 & MyCD.QueryString & Sd2
- Me.txtURL = X
- T = Src(X)
- It.OpenURL (X)
- DoEvents
- End Sub
- Private Sub Command1_Click()
- Dim X%, XX%, Y$
- Dim MyCD As New CCd
- X = T.Find("DISCID=" & txtID, , , 2 Or 8)
- XX = T.Find(vbCrLf & ".", , , 2 Or 8)
- T.Text = Right(T.Text, Len(T.Text) - X)
- T.Text = Left(T.Text, Len(T.Text) - 5)
- End Sub
- Private Sub Command2_Click(): T = Src(Sd1 & "sites" & Sd2): End Sub 'DISPLAY CDDB SITES
- Private Sub Command3_Click(): T = Src(Sd1 & "help" & Sd2): End Sub 'DISPLAY CDDB HELP
- Private Sub Command4_Click(): T = Src(Sd1 & "stat" & Sd2): End Sub 'DISPLAY CDDB STATS
- Private Sub Form_Load()
- CB.AddItem "D:"
- CB.AddItem "E:"
- CB.AddItem "F:"
- CB.AddItem "G:"
- CB.AddItem "H:"
- CB.AddItem "I:"
- CB.ListIndex = 0
- End Sub
- Private Sub It_StateChanged(ByVal State As Integer)
- On Error GoTo DD
- Select Case State
- Case 11
- MsgBox It.ResponseCode
- Case 8 ',12
- Dim vD As Variant
- Dim sD As String: sD = ""
- Dim bD As Boolean: bD = False
- vD = It.GetChunk(1024, 0)
- DoEvents
- Do While Not bD
- sD = sD & vD
- vD = It.GetChunk(1024, 0)
- If Len(vD) = 0 Then bD = True
- Loop
- T.Text = T.Text & sD
- End Select
- Resume Next
- End Sub
- Private Sub btnExit_Click(): Unload Me: End Sub
-