Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

write after page-load

PfernPfern Posts: 2Member
Hello,

I have a select field populated with people's names. Beside the select field is open space. I want to display the name of the company the person works for after the select field in this blank space. However, all I can manage to do is write a newpage (because the function is called after the page load). Is there anyway to display this information using ASP or JavaScript? I see many ways to dynamically change images online, but nothing about changing text embedded in a table after a page load. Code snippets are below: (However wrong they may be/are)


Response.Write("")



var tester = "";
function DisplayComp(incoming) {
if (incoming) {
tester = incoming;
}
document.write(incoming);
}


I know the logic will only display YES, but if I could get it to display yes there, I believe I could figure the rest out about displaying the correct company name. I figured I'd start small.

Comments

  • NCS_OneNCS_One Posts: 170Member
    : Hello,
    :
    : I have a select field populated with people's names. Beside the select field is open space. I want to display the name of the company the person works for after the select field in this blank space. However, all I can manage to do is write a newpage (because the function is called after the page load). Is there anyway to display this information using ASP or JavaScript? I see many ways to dynamically change images online, but nothing about changing text embedded in a table after a page load. Code snippets are below: (However wrong they may be/are)
    :
    :
    : Response.Write("")
    :
    :
    :
    : var tester = "";
    : function DisplayComp(incoming) {
    : if (incoming) {
    : tester = incoming;
    : }
    : document.write(incoming);
    : }
    :
    :
    : I know the logic will only display YES, but if I could get it to display yes there, I believe I could figure the rest out about displaying the correct company name. I figured I'd start small.
    :

    Hi

    Not really sure this is what you want but here it goes :

    [code]


    Teste4

    function HandleClick()
    {
    Div1.innerText = "ProgrammersHeaven";
    }










    ProgrammersHeaven



    [/code]

    Hope it helps.
  • PfernPfern Posts: 2Member
    Thanks. That is perfect. I was trying to make it too hard. Thanks again.
Sign In or Register to comment.