DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Wed, 15 Aug 2007 13:36:28 -0400,    posted on: microsoft.public.dotnet.framework.aspnet        back       

Thread Index
  1    Kevin Mat
          2    Ladislav Mrnka
          3    Kevin Mapppov
          4    Alexey Smirnov


dynamic controls   
hi,

In my aspx page I do have some dynamic aspx controls. I am using 
document.getElementById('pageID_Ctl1_text1') in the javascript to copy some 
values from these controls. It is working in the first time, and these 
controls id values are changing after the page reloaded. I am getting the 
error on this getElementById.

This was working in 2003 and after migrating to 2005, it is not working.

Any help would be appreciated.

Thanks
Kevin
Date:Wed, 15 Aug 2007 13:36:28 -0400   Author:  

RE: dynamic controls   
Hi Kevin,
how does the id change and where is your control placed?

Regards,
Ladislav

"Kevin Mat" wrote:


> hi,
> 
> In my aspx page I do have some dynamic aspx controls. I am using 
> document.getElementById('pageID_Ctl1_text1') in the javascript to copy some 
> values from these controls. It is working in the first time, and these 
> controls id values are changing after the page reloaded. I am getting the 
> error on this getElementById.
> 
> This was working in 2003 and after migrating to 2005, it is not working.
> 
> Any help would be appreciated.
> 
> Thanks
> Kevin 
> 
> 
> 
Date:Wed, 15 Aug 2007 12:10:02 -0700   Author:  

Re: dynamic controls   
thanks for the reply,
the controls are in a user control and it is placed in an aspx page. the 
controls in the user controls are dynamic.
it will create new id after the page got reloaded.
Eg: pageid_ctl1_text1 will change to pageid_ctl2_text1




"Ladislav Mrnka"  wrote in message 
news:A3723D7E-4A7B-4607-848D-5695B5FD24EC@microsoft.com...

> Hi Kevin,
> how does the id change and where is your control placed?
>
> Regards,
> Ladislav
>
> "Kevin Mat" wrote:
>
>> hi,
>>
>> In my aspx page I do have some dynamic aspx controls. I am using
>> document.getElementById('pageID_Ctl1_text1') in the javascript to copy 
>> some
>> values from these controls. It is working in the first time, and these
>> controls id values are changing after the page reloaded. I am getting the
>> error on this getElementById.
>>
>> This was working in 2003 and after migrating to 2005, it is not working.
>>
>> Any help would be appreciated.
>>
>> Thanks
>> Kevin
>>
>>
>> 
Date:Wed, 15 Aug 2007 15:28:15 -0400   Author:  

Re: dynamic controls   
On Aug 15, 9:28 pm, "Kevin Mapppov" 
wrote:

> thanks for the reply,
> the controls are in a user control and it is placed in an aspx page. the
> controls in the user controls are dynamic.
> it will create new id after the page got reloaded.
> Eg: pageid_ctl1_text1 will change to pageid_ctl2_text1
>
> "Ladislav Mrnka"  wrote in message



use a mix of ASP.NET and javascript

document.getElementById("<%=text1.ClientID%>");

where text1 is id of your Control, e.g.

<asp:TextBox id="text1" runat="server"/>
Date:Wed, 15 Aug 2007 20:10:41 -0000   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us