alat
siapin
1 form
1 module
8 common button
1 combo
1 webbrowser
code nya ini
module
simple kn?

semoga bermanfaat
siapin
1 form
1 module
8 common button
1 combo
1 webbrowser
code nya ini
Code:
'edited by ho1onk
'http://ho1onk.cz.cc
'http://ho1onk-crew.uk.cr
Public Function IsConnected() As Boolean
Dim TRasCon(255) As RASCONN95
Dim lg As Long
Dim lpcon As Long
Dim RetVal As Long
Dim Tstatus As RASCONNSTATUS95
'
TRasCon(0).dwSize = 412
lg = 256 * TRasCon(0).dwSize
'
RetVal = RasEnumConnections(TRasCon(0), lg, lpcon)
If RetVal <> 0 Then
MsgBox \"ERROR\"
Exit Function
End If
'
Tstatus.dwSize = 160
RetVal = RasGetConnectStatus(TRasCon(0).hRasCon, Tstatus)
If Tstatus.RasConnState = &H2000 Then
IsConnected = True
MsgBox \" You Are Connected To Internet Surf & Enjoy \", vbMsgBoxSetForeground
Else
IsConnected = False
MsgBox \" Sorry You Are Not Connected To Internet \", vbMsgBoxSetForeground
End If
End Function
Sub PercentBar(Shape As Control, Done As Variant, Total As Variant)
On Error Resume Next
Shape.AutoRedraw = True
Shape.FillStyle = 0
Shape.DrawStyle = 0
Shape.FontName = \"Fixedsys\"
Shape.FontSize = 8.25
Shape.FontBold = False
X = Done / Total * Shape.Width
Shape.Line (0, 0)-(Shape.Width, Shape.Height), &HC0C0C0, BF
Shape.Line (0, 0)-(X - 10, Shape.Height), &H800000, BF
Shape.CurrentX = (Shape.Width / 2) - 100
Shape.CurrentY = (Shape.Height / 2) - 125
Shape.ForeColor = RGB(0, 0, 0)
End Sub
Private Sub Command1_Click()
If Combo1.Text = \"\" Then
MsgBox (\"There Is No Page Avilable To Go Back\")
Else
WebBrowser1.GoBack
End If
End Sub
Private Sub Command2_Click()
If Combo1.Text = \"\" Then
MsgBox (\"There Is No Page Avilable To Go Forward\")
Else
WebBrowser1.GoBack
End If
End Sub
Private Sub Command3_Click()
WebBrowser1.Stop
End Sub
Private Sub Command4_Click()
WebBrowser1.Refresh
End Sub
Private Sub Command5_Click()
WebBrowser1.GoHome
End Sub
Private Sub Command6_Click()
WebBrowser1.GoSearch
End Sub
Private Sub Command7_Click()
Dim a
With CommonDialog1
.Filter = \"HTML Files (*.htm)|*.htm|HTML Files (*.html)| *.html\"
.ShowOpen
End With
a = CommonDialog1.FileName
Combo1.Text = a
Combo1.SetFocus
End Sub
Private Sub Command8_Click()
Call IsConnected
End Sub
Private Sub WebBrowser1_StatusTextChange(ByVal Text As String)
Label1.Caption = Text
End Sub
Private Sub WebBrowser1_TitleChange(ByVal Text As String)
Me.Caption = Text
End Sub
Private Sub WebBrowser1_BeforeNavigate(ByVal url As Variant, ByVal Cancel As Boolean)
Combo1.AddItem url
End Sub
Private Sub Combo1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
WebBrowser1.Navigate (Combo1.Text)
KeyAscii = 0
End If
End Submodule
Code:
Public Declare Function RasEnumConnections Lib \"RasApi32.dll\" Alias \"RasEnumConnectionsA\" (lpRasCon As Any, lpcb As Long, lpcConnections As Long) As Long
Public Declare Function RasGetConnectStatus Lib \"RasApi32.dll\" Alias \"RasGetConnectStatusA\" (ByVal hRasCon As Long, lpStatus As Any) As Long
'
Public Const RAS95_MaxEntryName = 256
Public Const RAS95_MaxDeviceType = 16
Public Const RAS95_MaxDeviceName = 32
'
Public Type RASCONN95
dwSize As Long
hRasCon As Long
szEntryName(RAS95_MaxEntryName) As Byte
szDeviceType(RAS95_MaxDeviceType) As Byte
szDeviceName(RAS95_MaxDeviceName) As Byte
End Type
'
Public Type RASCONNSTATUS95
dwSize As Long
RasConnState As Long
dwError As Long
szDeviceType(RAS95_MaxDeviceType) As Byte
szDeviceName(RAS95_MaxDeviceName) As Byte
End Type
semoga bermanfaat


![[Image: logo.png]](http://medancyberteam.web.id/forum/logo.png)


![[Image: kampret.gif]](http://i363.photobucket.com/albums/oo72/herisys/kampret.gif)
![[Image: logo-avh.png]](http://i1223.photobucket.com/albums/dd514/virmand/logo-avh.png)
![[Image: ibroke.png]](http://o2nri2.clan.su/onto/ibroke.png)
![[Image: sig2.png]](http://d.imagehost.org/0294/sig2.png)

