masterk 6 Posted August 16, 2017 Report Share Posted August 16, 2017 Hi;How do I do this? Example :- 1. I have a cat, her name is #variablename.2. #variablename loves to play ball.3. I pet #variablename last year. User insert the #variablename using UI, and when they click generate, they got all the lines above. Quote Link to post Share on other sites
Marton 48 Posted August 16, 2017 Report Share Posted August 16, 2017 Hi! Please see attached file. This is just a quick example. You can also have it saved as a text file (command: save to file), or use the command "alert": ui text box("Input cat\'s name:",#name) ui button("Generate") { load html("1. I have a cat, her name is {#name}.<br> 2. {#name} loves to play ball.<br> 3. I pet {#name} last year.") } Martoncat.ubot 1 Quote Link to post Share on other sites
masterk 6 Posted August 16, 2017 Author Report Share Posted August 16, 2017 Hi! Please see attached file. This is just a quick example. You can also have it saved as a text file (command: save to file), or use the command "alert": ui text box("Input cat\'s name:",#name) ui button("Generate") { load html("1. I have a cat, her name is {#name}.<br> 2. {#name} loves to play ball.<br> 3. I pet {#name} last year.") } MartonThanks Marton.You're a lifesaver ! Quote Link to post Share on other sites
Marton 48 Posted August 16, 2017 Report Share Posted August 16, 2017 Thanks Marton.You're a lifesaver ! No problem & good luck on your journey with Ubot! Marton Quote Link to post Share on other sites
masterk 6 Posted October 12, 2017 Author Report Share Posted October 12, 2017 How to export the load html into text file? I mean, save as text.txt Hi! Please see attached file. This is just a quick example. You can also have it saved as a text file (command: save to file), or use the command "alert": ui text box("Input cat\'s name:",#name) ui button("Generate") { load html("1. I have a cat, her name is {#name}.<br> 2. {#name} loves to play ball.<br> 3. I pet {#name} last year.") } Marton Quote Link to post Share on other sites
Marton 48 Posted October 12, 2017 Report Share Posted October 12, 2017 In this case I would not save the contents of the generated html, but rather use the command "save to file" (please use the search box in Ubot to find it easily). You can insert it after the load html command (or instead of it). Simply input the file path and filename (example: C:\example.txt), and use the same content you used in the load html command. I would recommend that you go over some of the basic tutorials (videos) to learn Ubot. And you can of course always consult the Ubot wiki for help with a specific command. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.