<textarea name="TO" id="S_TO" tabindex="1" autocomplete="off" style="border:1px #CCC6BF solid;height:17px;line-height:17px;width:100%;font-size:12px;overflow:hidden;word-break:break-all;"></textarea>这是html源码procedure TForm1.Button6Click(Sender: TObject);var d:IHTMLDocument2; Form : IHTMLFormElement;begin with WebBrowser1 do begin D := Document as IHTMLDocument2; Form := D.Forms.item('Mail_Form',0) as IHTMLFormElement; (form.item('S_TO',0) as IHTMLElement).setAttribute('value','aa',0); end;end;