Private Type WorldInfo Prefix As String End Type Private Function GetWorldInfo(World As Integer, Html As String) As WorldInfo Dim pos As Long pos = InStr(1, Html, "e(" & World) If pos = 0 Then MsgBox "That world doesn't exist or is currently offline.", vbCritical, "Error": Exit Function GetWorldInfo.Prefix = Mid(Html, InStr(pos, Html, ",""") + 2, (InStr(pos, Html, """,") - InStr(pos, Html, ",""")) - 2) End Function Function WorldNavigate(ByVal Server As Integer) As String Dim Detail As String Dim shtml As String If Inet1.StillExecuting = True Then Exit Function shtml = Inet1.OpenURL("http://www.runescape.com/slj.ws?lores.x=1&plugin=0&order=WMLP") WorldNavigate = GetWorldInfo(Server, shtml).Prefix If mnuDetailHigh.Checked = True Then Detail = 0 ElseIf mnuDetailLow.Checked = True Then Detail = 1 End If WebBrowser1.Navigate "http://" & WorldNavigate & ".runescape.com/l" & Detail & ",p0,j1" End Function