请问怎么实现?给出源代码,详细点,谢谢~!

解决方案 »

  1.   

    >>不能在XP下修改IP,主机名和DNS?什麼意思??? 你是想找段修改的代碼??還是想禁止別人不能修改??
      

  2.   

    有哪位高人能指点一下呢,Delphi下如何读写xp注册表里的多字符串值(REG_MULTI_SZ类型)的键值?结果定义为string类型,则使用readstring运行时提示读取的数据类型类型不对。结果定义为TstringList类型,则使用readstring,编译时提示类型不匹配?请问,如何读写? 
      

  3.   

    http://hub.myrice.com/delphizt/wlyy/001.htmhttp://community.csdn.net/Expert/FAQ/FAQ_Index.asp?id=193103
      

  4.   

    光改注册表是没有用的,大哥,我早就试过了!不过此功能还是可以实现的,网上有个国外的WMI控件,就是专门做这个的,不过是收费的!不过考虑试一下aiirii(ari-爱的眼睛) 所说的方法也不错!
      

  5.   

    用VC是可以实现的,我已经验证过,不过delphi就很麻烦!但是肯定的一点是:这个问题是绝对可以实现的!以下是delphi中用控件实现的例子:
    procedure TForm1.ShowProperties(Index: Integer);
    begin//Anzeige löschen
    ValueListEditor1.Strings.Clear;//Informationen aus NetworkAdapter
    ValueListEditor1.InsertRow('AdapterType',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].AdapterType,
    true);
    ValueListEditor1.InsertRow('Availability',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].Availability,
    true);
    ValueListEditor1.InsertRow('Caption',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].Caption, true);
    ValueListEditor1.InsertRow('Description',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].Description,
    true);
    ValueListEditor1.InsertRow('Manufacturer',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].Manufacturer,
    true);
    ValueListEditor1.InsertRow('NetConnectionStatus',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].NetConnectionStatus, true);
    ValueListEditor1.InsertRow('StatusInfo',
    NetworkAdapter.Win32_NetworkAdapterCollection.Items[Index].StatusInfo,
    true);//Informationen aus NetworkAdapterCfg
    ValueListEditor1.InsertRow('IPAddress',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].IPAddress,
    true);
    ValueListEditor1.InsertRow('IPSubnet',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].IPSubnet,
    true);
    ValueListEditor1.InsertRow('DHCPEnabled',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].DHCPEnabled,
    true);
    ValueListEditor1.InsertRow('DHCPLeaseExpires',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].DHCPLeaseExpires,
    true);
    ValueListEditor1.InsertRow('DefaultIPGateway',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].DefaultIPGateway,
    true);
    ValueListEditor1.InsertRow('MACAddress',
    NetworkAdapterCfg.Win32_NetworkAdapterConfigurationCollection.Items[Index].MACAddress,
    true);end; 不过这个控件需要60多美圆!!
      

  6.   

    试一试
    PostMessage(HWND_BROADCAST, WM_SETTINGCHANGE, NULL, NULL);
      

  7.   

    晕,用winshell就成了。netsh interface ip set address 本地连接 static 192.168.0.1 255.255.255.0 192.168.0.10 1
    [ 新 ip   ] [   掩码    ] [   网关   ]   2000的DNS可以用
    netsh interface ip set dns "本地连接" static 192.9.201.1  
    你直接用wiexec调吧