Sorry
I tried it but doesn't work
i'm being sent back to index.aspx ??? weird
so what i do know is
if(!Page.IsPostBack)
{
bla bla bla .....
Page.RegisterHiddenField("__EVENTTARGET","submit" );
this.txtSendTo.Attributes.Add("onFocus","javascrip t:SetTarget('submit');");
this.txtSubject.Attributes.Add("onFocus","javascri pt:SetTarget('submit');");
this.txtMessage.Attributes.Add("onFocus","javascri pt:SetTarget('notsubmit');");
}
if(Page.IsPostBack){
if(Page.Request.Form["__EVENTTARGET"].ToString().ToLower()=="submit"){
this.Send();
}
}
I know it's ugly but it works.
there has to be something not that ugly
Matt Berther <> wrote in message news:<>...
> Hello ,
>
> I've had a post that discusses how to accomplish this on my website:
>
> http://www.mattberther.com/2003/06/000125.html
>
> --
> Matt Berther
> http://www.mattberther.com
>
> > Hi me again
> >
> > problem 2
> >
> > on pages that have no user controls i want to submit using the enter
> > key
> >
> > i register
> > Page.RegisterHiddenField("__EVENTTARGET", "btnSubmit");
> > when i press enter it doesn't fire
> >
> > what am i missing ???
> >