![]() |
Saving Raw Text with input controls - Printable Version +- Atozed Forums (https://www.atozed.com/forums) +-- Forum: Atozed Software Products (https://www.atozed.com/forums/forum-1.html) +--- Forum: IntraWeb (https://www.atozed.com/forums/forum-3.html) +---- Forum: English (https://www.atozed.com/forums/forum-16.html) +----- Forum: IntraWeb General Discussion (https://www.atozed.com/forums/forum-4.html) +----- Thread: Saving Raw Text with input controls (/thread-2641.html) |
Saving Raw Text with input controls - davidmcevoy@outlook.com - 02-16-2022 Hello. I am having to make a questionnaire and I was wondering if it was possible by using the RawText to load an html file, the html will have input controls. I can get that part to work fine, but what I want to do is save the results and I was hoping I could just do a save to file but that doesn't seem to work, is this possible? What I am finding is it just saves back the original content, ignoring anything in the input boxes. It would certainly make this questionnaire a lot easier as it is likely to change often and so simply updating the html and then saving the results would be great. Is this possible, and if not any other suggestions? Regards David. RE: Saving Raw Text with input controls - Alexandre Machado - 02-24-2022 The problem here is that the controls that you create in your HTML file (e.g input controls) don't have any correspondent class/control on server side. When you change anything on the browser, the server is not notified of those changes (through a request). Do you have a list of types of controls that you have (e.g. edits, combo boxes, radio buttons, check boxes, etc)? I believe the best way to do this is via templates. A mix of raw HTML for most of the document + a few IW controls that can be created at runtime... RE: Saving Raw Text with input controls - davidmcevoy@outlook.com - 02-24-2022 (02-24-2022, 10:12 AM)Alexandre Machado Wrote: The problem here is that the controls that you create in your HTML file (e.g input controls) don't have any correspondent class/control on server side. When you change anything on the browser, the server is not notified of those changes (through a request). Hi Alexandre. Yes this form will be made up mainly of Combo boxes, memos and text boxes. I have started to use templates and got something working reasonably well, but I then need to find a way to save/reload this data easily. I can use a database which is probably what I will start off with, but the trouble with this is that if the questionnaire changes frequently, that will make maintaining the database and having to add more fields, obsolete old fields etc a bit of a pain. That is why I was hoping of an easy way to save the page to file would be possible. The way I am using the template is to define a page that is part of a master page then just put in place holders in the html file and correspondingly named components on the IW Form. This allows me to put in some logic like hiding memo boxes unless a Yes is defined in a corresponding combo box. It works quite well but takes a bit of time to get it all setup. Any suggestions on saving the template to a blob field in a database or file? Thanks David. RE: Saving Raw Text with input controls - Alexandre Machado - 03-16-2022 Hi there, sorry for the late response, I missed you answer. I'll try to get some demo showing how to use templates in a more dynamic way. I think it might be useful in your case. >That is why I was hoping of an easy way to save the page to file would be possible. Do you mean at server side or browser side? I'm assuming you want to load the template from a blob field at runtime before displaying it, is that correct? RE: Saving Raw Text with input controls - davidmcevoy@outlook.com - 03-17-2022 (03-16-2022, 08:18 PM)Alexandre Machado Wrote: Hi Alexandre that would be great if you have something that might help. |