- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
04-22-2025 01:59 AM
フォーム画面上で動作する、フィールドに値を入力する以下UIアクション(クライアント)があります。
on click でg_form.setValue("field","value")
同様の動作でボタンをセクションに(自由に)配置したい要望があり、以下UI macroを設定し
解決済! 解決策の投稿を見る。
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
04-22-2025 02:13 AM
try this
Add type="button"
to the button to prevent automatic form submission:
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide">
<button type="button" onclick="ui_macro();">ui_macro</button>
<script>
function ui_macro() {
g_form.setValue("field", "value");
};
</script>
</j:jelly>
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
04-22-2025 02:13 AM
try this
Add type="button"
to the button to prevent automatic form submission:
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide">
<button type="button" onclick="ui_macro();">ui_macro</button>
<script>
function ui_macro() {
g_form.setValue("field", "value");
};
</script>
</j:jelly>
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
04-22-2025 11:34 PM
うまくいきました。ありがとうございました!
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
04-22-2025 11:40 PM
Glad to help.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader