Write the Send image file program in C + + Builder

Source: Internet
Author: User

ICQ can achieve point-to-point data transfer, but if you want to send a multimedia image file to the other side, it is more difficult. However, you can use the C++builder 5.0 control to write an application for sending images.

Open C++builder 5.0, create a new project, add the Nmstrm,nmstrmserv,openpicturedialog control to the FORM1, plus the button control 3, the Label control 1, the Edit Control 2, StatusBar Control 1.

Let's start by recognizing the NMSTRM control, the Nmstrmserv control, and the Openpicturedialog control. The NMSTRM control is a TCP/ip-based control that can receive data streams and then send them to the server over the network. The Nmstrmserv control is a data stream that can be received from the client, which listens only on TCP/IP ports and is not responsible for listening on UDP ports. The Openpicturedialog control is used to open an image file for browsing or editing.

The properties of the various controls are designed as follows:

控件名  属性    值
Form   Caption   发送图像
Image  Name    Image1
Button name=Button1,Caption=发送
Button name=Button2,Caption=显示
Button name=Button3,Caption=打开
Label  name=Label1,Caption=远程主机:
Edit  name     Edit1
Edit  name     Edit2
NMStrm name     NMStrm1
NMStrmServ name   NMStrmServ1
OpenPictureDialog name OpenPictureDialog1
StatusBar name    StatusBar1

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.