C++ Builder????????????????
???????????? ???????[ 2014/4/1 9:48:02 ] ????????C++ ???? ???
????Ping??????????????????????IP???????????IP?????????32??????????????????????????????????任??£????·??????????????????????Щ??????????????????????C++ Builder NetMaster?е?NMEcho?????????????????????
?????????????????
????????Edit????????????????????????IP??????????????????????????????????????????????????????
????????RichEdit?????????????????????????????????????????????????????????
????????CheckBox???????????????????趨?????
???????Button???????????в????
???????StatusBar??????????????ó????????
??????????????????£?
void __fastcall TForm1::Button1Click(TObject ender)
{ //????NMEcho???????TCP/IP????
NMEcho1-??Host=Edit1-??Text ;
NMEcho1-??TimeOut=StrToInt(Edit2-??Text) ;
if(CheckBox1-??Checked)
NMEcho1-??Port=StrToInt(Edit3-??Text);
else
NMEcho1-??Port=7;
//TCP/IP??Echo????????
NMEcho1-??ReportLevel=Status_Basic;
NMEcho1-??Connect(); //????????
RichEdit2-??Clear ();
for(int i=0;i
//RichEdit1???????????????????
RichEdit2-??Text=RichEdit2-??Text +NMEcho1-??Echo(RichEdit1-??Lines-??
Strings[i]);
NMEcho1-??Disconnect ();
}
???????:?????NMEcho?????Connect?????????????????????????????????????????
??????????Connect?????????????????????????????????IP???????????????????????????????????????????????OnHostResoved?????????????????У?????????????????????????????????????????????????£?
void __fastcall TForm1::NMEcho1HostResolved(TComponent ??ender)
{
StatusBar1-??Panels-??Items[0]-??Text="Host Resolved!";
}
????????????????????????????????????????OnInvalidHost?????????????????У?????????????????????????????????IP?????????????????????????????????????????????£?
void __fastcall TForm1::NMEcho1InvalidHost(bool &&Handled)
{
AnsiString s;
if(InputQuery("Invailid host!"??"Specify a new host:"??s))
{
NMEcho1-??Host=s;
Handled=true;
}
}
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11