在C++Builder中编写发送图象文件程序(二)

类别:编程语言 点击:0 评论:0 推荐:


源程序代码如下:

//“Unit1.h"的源代码

//---------------------------------------------------------------------------

#ifndef Unit1H
#define Unit1H
//----------------------------------------- -------------------------------
#include $#@60;Classes.hpp$#@62;
#include $#@60;Controls.hpp$#@62;
#include $#@60;StdCtrls.hpp$#@62;
#include $#@60;Forms.hpp$#@62;
#include $#@60;ComCtrls.hpp$#@62;
#include $#@60;Dialogs.hpp$#@62;
#include $#@60;ExtCtrls.hpp$#@62;
#include $#@60;ExtDlgs.hpp$#@62;
#include $#@60;NMSTRM.hpp$#@62;
#include $#@60;Psock.hpp$#@62;
//---------------------------------------------------------------------------
class TForm1 : public TForm
{
__published: // IDE-managed Components
TButton *Button1;
TButton *Button2;
TNMStrm *NMStrm1;
TNMStrmServ *NMStrmServ1;
TOpenPictureDialog *OpenPictureDialog1;
TImage *Image1;
TLabel *Label1;
TEdit *Edit1;
TButton *Button3;
TEdit *Edit2;
TStatusBar *StatusBar1;
void __fastcall Button3Click(TObject *Sender);
void __fastcall Button1Click(TObject *Sender);
void __fastcall Button2Click(TObject *Sender);
void __fastcall NMStrm1Connect(TObject *Sender);
void __fastcall NMStrm1ConnectionFailed(TObject *Sender);
void __fastcall NMStrm1Disconnect(TObject *Sender);
void __fastcall NMStrm1HostResolved(TComponent *Sender);
void __fastcall NMStrm1MessageSent(TObject *Sender);
void __fastcall NMStrm1PacketSent(TObject *Sender);
void __fastcall NMStrm1Status(TComponent *Sender, AnsiString Status);
void __fastcall NMStrm1InvalidHost(bool &Handled);
void __fastcall NMStrmServ1ClientContact(TObject *Sender);
void __fastcall NMStrmServ1MSG(TComponent *Sender,
const AnsiString sFrom, TStream *strm);
void __fastcall NMStrmServ1Status(TComponent *Sender,
AnsiString Status);
private: // User declarations
public: // User declarations
__fastcall TForm1(TComponent* Owner);
};
//---------------------------------------------------------------------------
extern PACKAGE TForm1 *Form1;
//---------------------------------------------------------------------------
#endif

本文地址:http://com.8s8s.com/it/it30099.htm