Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to reset input field values using macro

hi

i want to reset the  value  of a field dynamically.

thanks

1 Solution

Accepted Solutions
er_mohit
Master II
Master II

try this

sub resetinput

dim x(1)

x(0) = 0 ' element to reset

set fld = ActiveDocument.Fields("NewPrice")

fld.ResetInputFieldValues 0, x ' 0 = All values reset, 1 = Reset Possible value, 2 = Reset single value

end sub

here NewPrice is my inputfield

so, you only generate an action eithe through button or on post data..

i attached file also.

hope it helps...

View solution in original post

2 Replies
er_mohit
Master II
Master II

try this

sub resetinput

dim x(1)

x(0) = 0 ' element to reset

set fld = ActiveDocument.Fields("NewPrice")

fld.ResetInputFieldValues 0, x ' 0 = All values reset, 1 = Reset Possible value, 2 = Reset single value

end sub

here NewPrice is my inputfield

so, you only generate an action eithe through button or on post data..

i attached file also.

hope it helps...

Not applicable
Author

hi mohit

its working fine. thanks for quick reply