sandabot Posted December 25, 2011 Report Share Posted December 25, 2011 Aveti nevoie de :1 WebBrowser , 1 Button , 1 TextboxImportam :Imports System.Runtime.InteropServicesRegiunea cu proxy (sub Public Class Form1)#Region "Using Proxy" <Runtime.InteropServices.DllImport("wininet.dll", SetLastError:=True)> _ Private Shared Function InternetSetOption(ByVal hInternet As IntPtr, ByVal dwOption As Integer, ByVal lpBuffer As IntPtr, ByVal lpdwBufferLength As Integer) As Boolean End Function Public Structure Struct_INTERNET_PROXY_INFO Public dwAccessType As Integer Public proxy As IntPtr Public proxyBypass As IntPtr End Structure Private Sub UseProxy(ByVal strProxy As String) Const INTERNET_OPTION_PROXY As Integer = 38 Const INTERNET_OPEN_TYPE_PROXY As Integer = 3 Dim struct_IPI As Struct_INTERNET_PROXY_INFO struct_IPI.dwAccessType = INTERNET_OPEN_TYPE_PROXY struct_IPI.proxy = Marshal.StringToHGlobalAnsi(strProxy) struct_IPI.proxyBypass = Marshal.StringToHGlobalAnsi("local") Dim intptrStruct As IntPtr = Marshal.AllocCoTaskMem(Marshal.SizeOf(struct_IPI)) Marshal.StructureToPtr(struct_IPI, intptrStruct, True) Dim iReturn As Boolean = InternetSetOption(IntPtr.Zero, INTERNET_OPTION_PROXY, intptrStruct, System.Runtime.InteropServices.Marshal.SizeOf(struct_IPI)) End Sub#End RegionIar in buton UseProxy(TextBox1.Text)Bagati un proxy in textbox apasati butonul si gata Quote Link to comment Share on other sites More sharing options...
seboo00111 Posted December 25, 2011 Report Share Posted December 25, 2011 Ms, Keep it up! Quote Link to comment Share on other sites More sharing options...
Wav3 Posted December 25, 2011 Report Share Posted December 25, 2011 Good job Quote Link to comment Share on other sites More sharing options...
Scorpionadi Posted December 31, 2011 Report Share Posted December 31, 2011 Interesant , multumim Quote Link to comment Share on other sites More sharing options...
pr00f Posted December 31, 2011 Report Share Posted December 31, 2011 http://rstcenter.com/forum/27657-tut-webbrowser-proxy.rstAm postat ?i eu acest lucru acum mult timp, am ?i explicat toate porc?riile. Quote Link to comment Share on other sites More sharing options...
sandabot Posted December 31, 2011 Author Report Share Posted December 31, 2011 http://rstcenter.com/forum/27657-tut-webbrowser-proxy.rstAm postat ?i eu acest lucru acum mult timp, am ?i explicat toate porc?riile.Nice post dar pot sa-ti garantez ca nu m-am inspirat de acolo Quote Link to comment Share on other sites More sharing options...
roantonyo Posted January 2, 2012 Report Share Posted January 2, 2012 chiar imi trebuia asta, merci Quote Link to comment Share on other sites More sharing options...