2020 Feb 04 2:27 PM
I have 2 conditions in smartform and need to display text one after other.
But as of now the second text is coming in next line, how to bring in same line?
example:
If sal > 0.
text1.
if bonus > 0.
text 2.
I want text 1 and text 2 appear in same line. but text 2 starting from next line how to avoid that?
2020 Feb 04 6:15 PM
You can always create a variable in the global definitions of the form and use program lines to achieve your objective.
Right Click -> Create -> Flow Logic -> Program Lines
If sal > 0.
v_text = text1.
if bonus > 0.
v_text = text2.
And now you can use v_text in yout text element instead of text1 or text2.
Regards.
I have 2 conditions in smartform and need to display text one after other.
But as of now the second text is coming in next line, how to bring in same line?
example:
If sal > 0.
text1.
if bonus > 0.
text 2.
I want text 1 and text 2 appear in same line. but text 2 starting from next line how to avoid that?
2020 Feb 04 3:22 PM
svasi_08,
This is usually controlled by smart style used for the relevant variable.
Can you please let us know the details of how the variable is declared and what smart style is used?
One simple solution would be concatenation of both text 1 and text 2 into a single variable say text 3. Now display only text 3. Below code could give you an idea. Am using text 3 only for your understanding, you can even concatenate in text1 also.
Concatenate text1 text2 into text3 separated by space. Regards
2020 Feb 04 6:15 PM
You can always create a variable in the global definitions of the form and use program lines to achieve your objective.
Right Click -> Create -> Flow Logic -> Program Lines
If sal > 0.
v_text = text1.
if bonus > 0.
v_text = text2.
And now you can use v_text in yout text element instead of text1 or text2.
Regards.
2020 Feb 04 6:35 PM
You should use the right paragraph format so that the second text continues after the first one. What did you use? (what "??" did you define?)
/: If sal > 0
?? text1.
/: if bonus > 0
?? text2.
/: endif
/: endif
2020 Feb 11 3:59 PM
SANDRA where should I write this if SAL > 0 ? or Bonus > 0. ?
2020 Feb 11 7:17 PM
svasi_08 In fact there are lots of solutions. I thought you had just one text node containing all the lines I mentioned (text2 is displayed only if both sal > 0 and bonus > 0). But as you didn't understand my question, it seems I was incorrect (it's still possible but it should be as below), in fact you had two distinct text nodes with output conditions. Or maybe two alternative nodes with two text nodes. So, either choose Satish or Danilo solution, or derive my question above to a solution if you understand what I meant.
2020 Feb 11 7:23 PM
Sandra thank you very much for the follow up answer and thanks for always being there when needed.
I applied simple logic like I put 2 yes or no.
If yes display whole text together i.e. text1, text2.
If no display only text1. Hope this is fine, thanks.
2020 Feb 12 7:26 AM
Fine. Please mark the best answer (eventually create your own answer) and close the question.
2020 Mar 02 2:46 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |