Results 1 to 6 of 6

Thread: Substitute textarea for Activex ?

  1. #1

    Thread Starter
    Frenzied Member Jmacp's Avatar
    Join Date
    Jul 2003
    Location
    UK
    Posts
    1,959

    Substitute textarea for Activex ?

    I was wanting to substitute a standard textarea for an activex control i made, so far the OCX is just a VB textbox, but i want to know how i can use this in a form post method to post/get its value, is it just the same as for a standard textarea or can you do this at all, for ex,

    HTML Code:
    <form method="post" action="main.php">
    
    <object classid="clsid:90E8CF72-B40A-11DA-8660-0002446E1033" id="T1" width="303" height="240">
    <param name="_ExtentX" value="8017">
    <param name="_ExtentY" value="6350">
    </object>
    
    <---- submit button etc
    
    </form>
    Can i post the Value for T1 then recieve this with say php ?

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Substitute textarea for Activex ?

    In the submit button's onclick event,

    document.form1.somehiddenfield.value = document.form1.T1.value

    Then get the value of somehiddenfield.

  3. #3

    Thread Starter
    Frenzied Member Jmacp's Avatar
    Join Date
    Jul 2003
    Location
    UK
    Posts
    1,959

    Re: Substitute textarea for Activex ?

    I put a hidden field in called hid1,


    HTML Code:
    <input type="hidden" name="hid1">
    <input type="submit" value="Preview" onclick="document.form1.hid1.value=document.form1.T1.value;alert(document.form1.hid1.value);">

    Is that syntax correct, the alert is there just to test ?

    giving me an error.

  4. #4
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Substitute textarea for Activex ?

    The error being...?

  5. #5

    Thread Starter
    Frenzied Member Jmacp's Avatar
    Join Date
    Jul 2003
    Location
    UK
    Posts
    1,959

    Re: Substitute textarea for Activex ?

    Quote Originally Posted by mendhak
    The error being...?

    syntax code 0 also removed the alert part and also tried this,

    HTML Code:
    <input type="submit" value="Preview" onclick="document.getElementById("hid1").value=document.getElementById("T1").value">

  6. #6

    Thread Starter
    Frenzied Member Jmacp's Avatar
    Join Date
    Jul 2003
    Location
    UK
    Posts
    1,959

    Re: Substitute textarea for Activex ?

    Tried this as well the msgbox displays an 'undefined'.

    HTML Code:
    <script language="JavaScript">
    
    function testit(){
    
    document.getElementById("hid1").value=document.getElementById("UserControl11").value;
    var e = document.getElementById("hid1").value;
    alert(e);
    
    return false;
            }
    
    </script>	
    
    
    <form method="post" action="main.php">
    
    <object classid="clsid:90E8CF72-B40A-11DA-8660-0002446E1033"
    id="UserControl11" width="303" height="240">
    
    <param name="_ExtentX" value="8017">
    <param name="_ExtentY" value="6350">
    
    </object>
                                                                	
    <input type="hidden" name="hid1">	
    <input type="submit" value="Preview" onclick="return testit()">
    	
    </form>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width