652
Views
7
Comments
Solved
Resetting a table formĀ 
Question

Hi community,

I am using a traditional web page now. 

I have a ticket table and would like the following action to take place:

1) After clicking the submit button and successfully submitted my form, I would like the clear the form to its default state.  

2) Clicking the reset button will clear my field and return it to its default state. 

How should I go about doing it? 

2023-04-07 07-55-02
Krushna Mantri
Solution

Hi Alvin,

You can reset the form fields by following anyone step from below in Reset button

1)You can reset your form fields by assigning, NullIdentifier() if the form field is ID, ""(i.e. empty) if the form field is Text and Ajax refresh to your form.

2)If you are getting the form data from an Aggregate/SQL by data ID (suppose you are showing student data in the form and getting from student entity with student.id = StudentId), so you can just assign nullidentifier() to that Data id and refresh the aggregate, assign its output to your form  and Ajax refresh to your form

Hope it will help you

Cheers,

Krushna

UserImage.jpg
Alvin Teo

Krushana Mantri wrote:

Hi Alvin,

You can reset the form fields by following anyone step from below in Reset button

1)You can reset your form fields by assigning, NullIdentifier() if the form field is ID, ""(i.e. empty) if the form field is Text and Ajax refresh to your form.

2)If you are getting the form data from an Aggregate/SQL by data ID (suppose you are showing student data in the form and getting from student entity with student.id = StudentId), so you can just assign nullidentifier() to that Data id and refresh the aggregate, assign its output to your form  and Ajax refresh to your form

Hope it will help you

Cheers,

Krushna

 

 Hi Krushna,


What about AppointmentDateTime? How do I assign null to datetime?

2026-02-26 06-29-24
Rahul
Ā 
MVP

Hi Alvin,

Set default value after data insertion or before end node of submit button and use Ajax Refresh for form.

same this use on Reset button.

It will reset all inputs value.


Regards

Rahul Sahu

UserImage.jpg
Alvin Teo

Rahul Sahu wrote:

Hi Alvin,

Set default value after data insertion or before end node of submit button and use Ajax Refresh for form.

same this use on Reset button.

It will reset all inputs value.


Regards

Rahul Sahu

 

 Hi Rahul,


How do I set the default value before my end node? Sorry, I am quite new to OutSystems.

2023-04-07 07-55-02
Krushna Mantri
Solution

Hi Alvin,

You can reset the form fields by following anyone step from below in Reset button

1)You can reset your form fields by assigning, NullIdentifier() if the form field is ID, ""(i.e. empty) if the form field is Text and Ajax refresh to your form.

2)If you are getting the form data from an Aggregate/SQL by data ID (suppose you are showing student data in the form and getting from student entity with student.id = StudentId), so you can just assign nullidentifier() to that Data id and refresh the aggregate, assign its output to your form  and Ajax refresh to your form

Hope it will help you

Cheers,

Krushna

UserImage.jpg
Alvin Teo

Krushana Mantri wrote:

Hi Alvin,

You can reset the form fields by following anyone step from below in Reset button

1)You can reset your form fields by assigning, NullIdentifier() if the form field is ID, ""(i.e. empty) if the form field is Text and Ajax refresh to your form.

2)If you are getting the form data from an Aggregate/SQL by data ID (suppose you are showing student data in the form and getting from student entity with student.id = StudentId), so you can just assign nullidentifier() to that Data id and refresh the aggregate, assign its output to your form  and Ajax refresh to your form

Hope it will help you

Cheers,

Krushna

 

 Hi Krushna,


What about AppointmentDateTime? How do I assign null to datetime?

2023-04-07 07-55-02
Krushna Mantri

Hi Alvin,


Please assign NullDate() to the DateTime form field

Cheers,

Krushna

2026-01-15 03-18-59
Vijay Malviya

Hi Alvin, 

Refer the attached .oml .


Vijay M-

Resettingtableform.oml
UserImage.jpg
Alvin Teo

Thanks, Community :) The problem is solved. 

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.