Link to home
Start Free TrialLog in
Avatar of andre72
andre72

asked on

Using code blocks in Javascript

Hi,

when I access an ASP control I've just to include it's client ID:
<script type="text/javascript">
...
<%= Speichern.ClientID %>
---
</script>

But how can I do this in an external js file?
When I try <script type="text/javascript" src="myjs.js">
<%= Speichern.ClientID %> eber returns null.

Is there a way to use it?

Thanks

Andre
ASKER CERTIFIED SOLUTION
Avatar of DalHorinek
DalHorinek
Flag of Czechia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of andre72
andre72

ASKER

Is this really the only way to do so?
I don't say it's only way, you can generate the external file along the web page, but I don't think that's better solution.