In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
In this issue, Xiaobian will bring you analysis on how to implement landing Ftp in VB. NET. The article is rich in content and analyzes and narrates from a professional perspective. After reading this article, I hope you can gain something.
VB. NET practical tutorial teaches you today for VB. NET landing Ftp method, take a look at learning it. We all know that remote video transmission can use thread download, image compression, and can also be considered to be stored in the database first.
VB. NET Practical Tutorial Code:
Private sckConnect As New Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp) Private RemoteIp As IPEndPoint Private thd As Thread Private blnExt As Boolean = True Private _Quality As Int16 = 50 Public WriteOnly Property Quality() As Int16 'This function indicates the image quality requested by the server Set(ByVal value As Int16) _Quality = value End Set End Property Private Sub run() Dim byt() As Byte Dim stream As MemoryStream Dim bmp As Bitmap While blnExt Try bmp = getGrcToBmp() 'This is Get Picture stream = New MemoryStream Compress(bmp, stream, _Quality) 'Compression function applied to image here byt = stream.ToArray sckConnect.Send(byt, byt.Length, SocketFlags.None) byt.Initialize() stream = Nothing Thread.Sleep(30) '30 milliseconds, or 33 images per second Catch ex As Exception Call Ext() End Try End While End Sub Public Sub Send(ByVal ip As String, ByVal port As Integer) 'IP and Port of server Try RemoteIp = New IPEndPoint(IPAddress.Parse(ip), port) sckConnect.SendTimeout = 100 sckConnect.Connect(RemoteIp) If sckConnect.Connected Then thd = New Thread(AddressOf run) thd.Start() End If Catch ex As Exception MsgBox(ex.Message) Exit Sub End Try End Sub Public Sub Ext() Try blnExt = False thd = Nothing sckConnect.Disconnect(True) sckConnect.Close() Catch ex As Exception End Try End Sub The above is how to carry out the analysis of VB. NET landing Ftp shared by everyone. If there are similar doubts, please refer to the above analysis for understanding. If you want to know more about it, please pay attention to the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.