How to pass a server variable to a client varible?

Results 1 to 2 of 2

Thread: How to pass a server variable to a client varible?

  1. #1
    Peng Guest

    Default How to pass a server variable to a client varible?

    I want to retrieve some data from database using ASP and diplay them in a ActiveX control on client side. But how to pass those data to the varibles so the Active Control can see it?<BR><BR><BR>

  2. #2
    Join Date
    Dec 1969
    Posts
    2,849

    Default RE: How to pass a server variable to a client varible?

    Since all ASP pages are processed completely BEFORE the client gets to process it, you can simple print the contents of an ASP variable in the appropriate client-side script.<BR><BR>For example, say that you had this:<BR>&#060;OBJECT ...><BR>&#060;PARAM NAME="Width" VALUE="4"><BR>&#060;/OBJECT><BR><BR>but you wanted the value of that PARAM tag to be based on an ASP variable. You&#039d just do:<BR>&#060;PARAM NAME="Width" VALUE="&#060;%=someASPVariable&#037;&#062;"><BR><B R>Since the value is written before the client gets it, the client will only see the value of the ASP variable.<BR><BR>Does this make sense? Good luck!<BR>

Posting Permissions

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