Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
Hi every one!
I have a problem, i can send data from children page to parent page (in parent page i use masterpage ) and show on lable but when i want to get value in code behind i can't get them. The value i get always the text name on my lable, i don't know why?
Could u help me?
This my javarscrip to send data to parent page from children page.
function AcceptList() {
    opener.document.getElementById("ctl00_ContentPlaceHodlerMain_myIdLable").getAttribute.innerHTML = a;
    close();
    }
i use .getAttribute.innerText is the same result.
 
[edit]Code block added - OriginalGriff[/edit]
Posted 30-Jul-11 21:28pm
Edited 30-Jul-11 22:08pm
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Try
opener.document.getElementById("ctl00_ContentPlaceHodlerMain_myIdLable").innerHTML = a;
or
opener.document.getElementById("ctl00_ContentPlaceHodlerMain_myIdLable").setAttribute("innerHTML", a);
  Permalink  
Comments
Manas Bhardwaj at 31-Jul-11 6:44am
   
my 5!
Monjurul Habib at 31-Jul-11 6:55am
   
answer is ok. but is this professional approach to use rendered ID?
thanhntt89 at 1-Aug-11 3:06am
   
thank for helping me :)
but the result is the same. I still can get value of lable in code behind :(
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

  Permalink  
v2
Comments
Monjurul Habib at 1-Aug-11 3:25am
   
pleasure.
thanhntt89 at 4-Aug-11 6:43am
   
Ok i can see the value of children page on label parent page. but i wanna get value that in code behind. I can't get it ....the result i get always the text basic on label parent page. It's not value i want from children page.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 195
1 ProgramFOX 130
2 Maciej Los 105
3 Afzaal Ahmad Zeeshan 82
4 Sergey Alexandrovich Kryukov 75
0 OriginalGriff 6,564
1 Sergey Alexandrovich Kryukov 6,048
2 DamithSL 5,228
3 Manas Bhardwaj 4,717
4 Maciej Los 4,150


Advertise | Privacy | Mobile
Web02 | 2.8.1411022.1 | Last Updated 31 Jul 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100