VBScriptトリム関数
❮完全なVBScriptリファレンス
Trim関数は、文字列の両側のスペースを削除します。
ヒント: LTrimとRTrimの機能も確認してください。
構文
Trim(string)
Parameter | Description |
---|---|
string | Required. A string expression |
例
例
<%
fname=" Jack "
response.write("Hello" & Trim(fname) & "and welcome.")
%>
上記のコードの出力は次のようになります。
HelloJackand welcome.
❮完全なVBScriptリファレンス