Load input form with Data from a query or method | Community
Skip to main content
CampaignerForLife
Level 5
December 26, 2023
Solved

Load input form with Data from a query or method

  • December 26, 2023
  • 2 replies
  • 890 views

Hello, is it possible to load an input form input with data of a method?

I call a method pressing a button, then I want that the info returned by that method is showed in the input form. Is it possible?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Amine_Abedour

Hello @campaignerforlife,

 

Yes it's possible.

Here is an exemple.

i've created bellow schema with the below method :

The definition of the method is simple, it just returns a string : 

In a form, i trriger the method using a button and store the result of the method in my @string field.

I use a <refresh/> so that the result can be seen on the screen and a <saveView/> so that the change get stored to database

Bellow the definition of my form :

 

 

Before clicking the button:

After clicking the button:

 

Br,

Amine ABEDOUR

 

2 replies

Marcel_Szimonisz
Community Advisor
Community Advisor
December 29, 2023

Hello @campaignerforlife,

Do you mean to load input in adobe campaign console or in web application?

In campaign console
In campaign console you can do radio button but that enumeration is defined in the schema.

https://experienceleague.adobe.com/docs/campaign-classic/using/configuring-campaign-classic/input-forms/form-structure.html?lang=en#radio-button

You can change the schema programatically but wont recommend. 
You can try to use enumaration field instead


On web app
On web app you can do it as well 🙂

Marcel

Amine_Abedour
Community Advisor
Amine_AbedourCommunity AdvisorAccepted solution
Community Advisor
December 29, 2023

Hello @campaignerforlife,

 

Yes it's possible.

Here is an exemple.

i've created bellow schema with the below method :

The definition of the method is simple, it just returns a string : 

In a form, i trriger the method using a button and store the result of the method in my @string field.

I use a <refresh/> so that the result can be seen on the screen and a <saveView/> so that the change get stored to database

Bellow the definition of my form :

 

 

Before clicking the button:

After clicking the button:

 

Br,

Amine ABEDOUR

 

Amine ABEDOUR