VBScript CStrFunction
Complete VBScript Reference
The CStr function converts an expression to a string (String) type.
Syntax
CStr(expression)
| Parameters | Description |
|---|---|
| expression | Required. Any valid expression. If the expression is:
|
Example
Example
<script type="text/vbscript">
document.write(CStr("300000") & "<br />")
document.write(CStr(#10-05-25#) & "<br />")
</script>
document.write(CStr("300000") & "<br />")
document.write(CStr(#10-05-25#) & "<br />")
</script>
The output of the above example is:
300000
10/5/2025
10/5/2025
Try it yourself »
Complete VBScript Reference Other Extensions