PDA

View Full Version : Example request



travisperkins
02-08-2006, 07:30 AM
Is there someone who would be willing, either for a fee or a return favor, to create me a quick example of something?

I need an example application with two pages.
On both pages I need a text box where a user can type in text and save it.
I need the text saved in the simplest way possible, preferably to a text file.

I need them to be able to come back at any point and change their text.

It can be ugly, simple and crude. I just need to see how the text box, the save button and the edit possibility is coded. I ask for two pages so I can clearly see what has to be coded per page and what for the whole project.

If this is a fee-paying situation, I can pay by paypal in advance of work done.

Hopefully, this would also be a useful example to post for others to download.

Many thanks.

rhosk
02-08-2006, 07:44 AM
Off the top of my head, the Calendar Plug-in example writes to a text file. Here is a post by user Worm that demonstrates it nicely. It doesn't have two(2) pages, but you should get the idea (saving to a text file) -

http://indigorose.com/forums/showpost.php?p=65905&postcount=2

Hope it helps. If not, we'll try something else.

travisperkins
02-08-2006, 08:00 AM
Having opened the project and seen that it is basically a simple type, save and edit process, it looks as though this could be enough for me to get going. The only trouble is that I do not have the calendar plug in and so the project will not build.

rhosk
02-08-2006, 08:07 AM
You're in the AMS6 forum, I assumed......

What version do you have?

travisperkins
02-08-2006, 08:54 AM
I am running Version 6.

rhosk
02-08-2006, 08:56 AM
Well then, you should have the Calendar Plugin. I "think" it comes standard in version 6. Someone correct me if I'm wrong :huh

travisperkins
02-08-2006, 09:07 AM
I just downloaded a brand new fresh trial version of 6 and put it on my lap top to make sure. No Calendar Plug in.

Can not even seem to find the calendar plug in to buy, which I would happily to do.

yosik
02-08-2006, 09:27 AM
Calendar should be in..
Anyway, why not just delete the calendar object in the example project and build it from there..
Or just copy the actins from the projects into yours?

Yossi

travisperkins
02-08-2006, 12:21 PM
I have deleted the Calendar Plugin and, on receiving 'On Click' errors pertaining to the Calendar, have deleted those parts of the script that seemed to be relevant only to the calendar.

This leaves me with a 'Clear' and 'Add/Update' Button and a text box, which is all I need.

I am however frustrated by my own lack of knowledge because I have obviously deleted too much script because although the 'Add/Update' button, on click, appears to save the text I type in the text box, when I quit and open the application it has disappeared.

Is there anyone with the time and will to correctly delete the uneccesary script from the calendar example and post it so it just contains a working text box with 'Clear' and 'Add/Update' on click events, so that the user entered text is there when you reopen the app after quiting?

Again, as I said before, I am open to any kind of remuneration or return.

Many thanks.

Worm
02-08-2006, 12:50 PM
In the simplest method:



sText = Input.GetText("Input1")
TextFile.WriteFromString("Autoplay\\Docs\\InputText.txt", sText, true)


Change the true to false if you want to over-write the existing file.

Roboblue
02-08-2006, 01:15 PM
This may do what you want.
Check Page On Show event and button actions.

travisperkins
02-08-2006, 01:28 PM
Thanks for this.

I have this for the 'Clear' button:
_____
Set the Text
Input.SetText("Input1","");
______

I have this for the 'Add/Update' button:

_________
sText = Input.GetText("Input1")
TextFile.WriteFromString("Autoplay\\Docs\\InputText.txt", sText, true)
_________

But after quiting the application and opening it again, it does not show the text in the text box.

Is there some code I need for the text box for the onshow event?

Thanks

Worm
02-08-2006, 01:31 PM
Yes


sText = TextFile.ReadToString("Autoplay\\Docs\\InputText.txt")
if sText then
Input.SetText("Input1", sText)
end

travisperkins
02-08-2006, 01:40 PM
This is everything I need.

It works perfectly on multiple pages.

Many thanks indeed for the kind and timely responses !!!!!!!!!!