Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently January 10th, 2025, 6:36 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Scratchpad - Notepad
PostPosted: April 5th, 2009, 7:04 am 
Offline

Joined: November 4th, 2008, 6:36 pm
Posts: 29
I am making an application to help Hungarians learn English, I would like them to be able to call up a personal Notepad on screen to make notes and then be able to email the text file to me and then they will be able to view it anytime they like and add to it.

I understand about variables and I have tried to make a text box, add a variable, write it to disk then read it from disk, but this seems to be as far as I can get, any help please would be greatly appreciated

I am using the latest addition of Opus Pro


Top
 Profile  
 
 Post subject:
PostPosted: April 5th, 2009, 7:58 am 
Offline
Godlike
Godlike

Joined: November 12th, 2005, 1:56 am
Posts: 1474
Location: SFBay Area
Opus: OpusPro v9.0x, & Evol.
OS: Vista32
System: Core 2 duo 2Ghz, RAM 3GB, Nvidia Go 7700 - laptop
I assume you mean text input box. If you've got that working, you may find help with the email part of your question here:
viewtopic.php?t=644&highlight=input+email
...found in forum by Searching --- input email

I think you'll find this post helpful for file writes even if you've accomplished that already:
viewtopic.php?t=2688&highlight=text+input

If you are logged in on the Forum, you will see when people have posted sample solutions you can download and use.

good luck.

_________________
_good things come to those who wait(0)_


Top
 Profile  
 
 Post subject: Still don't get it
PostPosted: April 6th, 2009, 3:23 am 
Offline

Joined: November 4th, 2008, 6:36 pm
Posts: 29
Lars,
Thanks for your reply, but I still can not seem to understand it.

I want to let the user input information into an input area,

this is then allocated to a variable which in turn is written to disk,

I then need the user to be able to close the publication and when he comes
back to this page the text file is read into the variable and shown on screen,

then I need the user to be able to add more information to the file and so the circle begins again.

I have not mastered script yet, so the most basic help would have more chance of being understood.

Thanks


Top
 Profile  
 
 Post subject:
PostPosted: April 6th, 2009, 4:05 am 
Offline
Godlike
Godlike

Joined: November 12th, 2005, 1:56 am
Posts: 1474
Location: SFBay Area
Opus: OpusPro v9.0x, & Evol.
OS: Vista32
System: Core 2 duo 2Ghz, RAM 3GB, Nvidia Go 7700 - laptop
Quote:
then need the user to be able to close the publication and when he comes back to this page the text file is read into the variable and shown on screen


The 2nd link I posted above, topic number 2688, does this already. I had had a very similar question to yours and others here provided the solution... both an explanation AND a sample Pub I could download. (again, be logged-in to the Forum to see that there are those Attached files to download).

While the solution was done in scripts, you can Preview the Pub and see it operate right now. You should be able to get an idea how it works with just a little patience to follow the flow. The same Actions can be built via standard Opus Triggers and Actions (however Trig/Action approach is not my forte. you may find other examples by searching, or by waiting for others to post.)

Cheers.

_________________
_good things come to those who wait(0)_


Top
 Profile  
 
 Post subject: Thanks Lar, heres another one
PostPosted: April 6th, 2009, 6:58 am 
Offline

Joined: November 4th, 2008, 6:36 pm
Posts: 29
I have now got my thick head around it and everything is working well thank you for your help.

The next thing is:

I have made a button to set the text input variable to read blank " ", I then save the variable hoping it will overwrite the text and result in an empty file, then allowing the user to restart their notes but the text file keeps coming back showing the old text, any ideas where I am going wrong?


Top
 Profile  
 
 Post subject:
PostPosted: April 6th, 2009, 9:09 am 
Offline

Joined: November 25th, 2004, 1:24 pm
Posts: 512
Location: Scotland
Opus: 9.75
OS: Win 10
System: Asus i7-7700K 16Gb
Everyone has a 'thick head' at some time...my one normally just the first 12 hours of the day . I have attached a very basic pub which shows some of the things you can do using just actions. It can also all be done in scripting.
In the sample, you can type text into the input box, there is a button to clear the text, but you can also clear by right clicking the box.
You can e-mail the text in the input box.
You can save (Append) the text in the input box to a text file saved in the pub directory.
You can clear the text file
You can look at the text file to see what's in it.
You can e-mail the text file.
Sorry the pub is a biit basic, but it should give you some idea what is possible just using actions.

Sandy


You do not have the required permissions to view the files attached to this post.

_________________
Whoever designed this, never actually used it!


Top
 Profile  
 
 Post subject: Location of text files
PostPosted: April 7th, 2009, 5:23 am 
Offline

Joined: November 4th, 2008, 6:36 pm
Posts: 29
Thanks Sandy, that was very useful indeed, you have put your text files in the SYSTEM_PUBLICATION folder,

I am giving these CDs to individuals who will run the system from their computers, I have been putting the files in the WINDOWS/TEMP (because I know everyone has one of those, which is best for this type of application.

Also I tried a search for the text file in Windows and it drew a blank which seemed strange any ideas? Once again thanks everyone for your help


Top
 Profile  
 
 Post subject:
PostPosted: April 7th, 2009, 9:17 am 
Offline

Joined: November 25th, 2004, 1:24 pm
Posts: 512
Location: Scotland
Opus: 9.75
OS: Win 10
System: Asus i7-7700K 16Gb
Strangely.....or not....(I have Vista)..... windows/temp directory would not work if I tick the 'store in windows temp directory' option, but if I put the full path name C:\Windows\Temp\file.txt it saves OK and can be seen in that directory.

If I view the variable 'SYSTEM_TEMP_DIR' for Vista, it is C:\users\sandy\appdata\local\temp....which is a hidden folder in Vista....so for my system, Opus saves the file to a hidden folder....when I looked (Start %temp%) the file was there. The Windows Temp directory is in a different place in Vista and may be hidden.......(no comment!)


If you know your user base, you can design to suit, but don't assume the pub will run on XP and Vista. Probably the safest way is to specify a path and filename to save the file such as C:\Windows\Temp\file.txt.

I would always check a folder/file exists after writing, then do something about it if it is not found, but this needs some scripting.

Sandy

_________________
Whoever designed this, never actually used it!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group