Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
bikin browser sederhana
#1
Petunia_16 
alat

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 Sub

module
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
simple kn?
Bigsmile

semoga bermanfaat
[Image: logo.png]
Reply
#2
cara pakenya gmn bro
Reply
#3
sama kayk fire fox

cuma yang ini hasil bikinan kita
dan lebih ringan hehhe
[Image: logo.png]
Reply
#4
Gan.. buat tutor bergambarnya dong Gan.. ane mau buat Browser nih.. Ngakak Huwaa
Reply
#5
cara makenya gmna ya om... Malu
[Image: kampret.gif][Image: zombie.gif]
Reply
#6
Ini Pake VB ????
[Image: logo-avh.png]
Reply
#7
Code:
Create a Very Simple Browser #include &lt;afxinet.h&gt; //assumes URL names have been initialized CInternetSession session("My Session"); CStdioFile* pFile = NULL; //use a URL and display a Web page while (lpszURL = DisplayPage(...)) { pFile = session.OpenURL(lpszURL); while (pFile-&gt;Read(szBuff,1024) &gt; 0) { //read file... } delete pFile; } session.Close(); Download a Web Page //this code excerpt also demonstrates how to use //try/catch exception handling #include &lt;afxinet.h&gt; //assumes server, port and URL names have been initialized CInternetSession session("My Session"); CHttpConnection* pServer = NULL; CHttpFile* pFile = NULL; try { CString strServerName; INTERNET_PORT nPort; pServer = session.GetHttpConnection(strServerName, nPort); pFile = pServer-&gt;OpenRequest(CHttpConnection::HTTP_VERB_GET, strObject); pFile-&gt;AddRequestHeaders(szHeaders); pFile-&gt;SendRequest(); pFile-&gt;QueryInfoStatusCode(dwRet); if (dwRet == HTTP_STATUS_OK) { UINT nRead = pFile-&gt;Read(szBuff, 1023); while (nRead &gt; 0) { //read file... } } delete pFile; delete pServer; } catch (CInternetException* pEx) { //catch errors from WinInet } session.Close(); FTP a File #include &lt;afxinet.h&gt; //assumes server and file names have been initialized CInternetSession session("My FTP Session"); CFtpConnection* pConn = NULL; pConn = session.GetFtpConnection(lpszServerName); //get the file if (!pConn-&gt;GetFile(pstrRemoteFile, pstrLocalFile)) //display an error delete pConn; session.Close(); Retrieve a Gopher Directory #include &lt;afxinet.h&gt; //assumes file name has been initialized CInternetSession session("My Gopher Session"); CGopherConnection* pConn = NULL; CGopherFileFind* pFile; pConn = session.GetGopherConnection("gopher.yoursite.com"); pFile = new CGopherFileFind(pConn); BOOL bFound = pFile-&gt;FindFile(lpszFileToFind); while (bFound) { bFound = pFile-&gt;FindNextFile(); //retrieve attributes of found file } delete pFile; delete pConn; session.Close();


izin nyoret./..
[Image: ibroke.png]


[Image: sig2.png]
Reply
#8
aduh masih pusing.
pake gambar donk kk
Reply
#9
(02-16-2011, 03:28 PM)boledcool Wrote: aduh masih pusing.
pake gambar donk kk

ms gt doank kok mesti pake gambar?
Bingung
[Image: logo.png]
Reply
#10
Bingung ini scrip di apain ya ?
disimpan dalam bentuk apa ?
FB : Obieaja
Twitter : @ObieajaSan
My Blog : Obieaja's Site
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Cara Membuat Form Splash Sederhana Dengan VB6.0 AgamBastard 7 153 12-27-2013, 01:57 PM
Last Post: nesta
  (Tutor)Membuat Browser Sederhana dengan VB 6 Hab1b 9 303 11-28-2013, 05:00 PM
Last Post: Jacket^Cyber
  (ask) cara bikin paket instalansi vie_opie 5 153 10-27-2013, 11:57 AM
Last Post: .hack//
  [VB 6] Aplikasi Rumah Sakit Sederhana SQL Server + Crystal Report mydisha 4 168 09-06-2013, 02:58 PM
Last Post: mydisha
  Membuat effect animasi sederhana dengan menggunakan VB.net ( open and close slowly ) BlaCk CyBeR 10 308 01-13-2012, 07:51 PM
Last Post: Guantz
Red-stab_16 Cara buat Mp3 Sederhana Putrii 13 434 01-12-2012, 10:02 AM
Last Post: Jufry_Gaptek
Sarge_16 [ask] cara membuat browser seperti firefox ada yang tau gak google setan 9 206 01-09-2012, 06:15 AM
Last Post: UHD
  [Ask] Cara Bikin Kamus Sederhana (VB6) Drw123 0 75 11-29-2011, 08:50 PM
Last Post: Drw123
  [ASK] Bikin Injector Ayodance dgn VB6 Rumpeeee 2 103 02-22-2011, 06:16 PM
Last Post: ghalieh
Help_16 [ask] bikin form yang gini hogyz 4 215 12-23-2010, 01:52 AM
Last Post: hogyz

Forum Jump:


Users browsing this thread: 1 Guest(s)