Saving user modifications to Table Data

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

trags3
Posts: 432
Joined: Wed Apr 09, 2014 1:58 am

Re: Saving user modifications to Table Data

Post by trags3 » Fri May 16, 2014 6:30 pm

Klaus wrote:Hi Simon,
Simon wrote:Are you reading the text file to see if the info is correct each time you change it? (make sure you close it so it can be written to).
The "url("file:" xyz) syntax does ecactly this in a one-liner:
...
open file xyz for read
read from file xyz ...
close file xyz...
...
:D


Best

Klaus
Klaus, Ans Simon,
Give me about 30 min and I will post the relevant cards of the stack.

I guess I don't quite understand the syntax.

Tom

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Saving user modifications to Table Data

Post by Simon » Fri May 16, 2014 6:56 pm

Hi Tom,
I copied your specialFolderPath stuff from the above posting and it didn't work!
Not sure why... it reads correctly.
So I redid it by hand

Code: Select all

  if there is not a directory (specialFolderPath("documents") & "/sellnet") then
      create folder (specialFolderPath("documents") & "/sellnet") 
   end if
   set the defaultFolder to (specialFolderPath("documents") & "/sellnet") 
Now it works!

On the desktop are you getting a folder called sellnet in your Documents folder?

weeeee found it!
create folder (specialFolderPath("documents") & "/sellnet")
NOT create folder (specialFolderPath("documents" & "/sellnet"))
Yahoo!

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Saving user modifications to Table Data

Post by Klaus » Fri May 16, 2014 7:15 pm

Simon wrote:...
weeeee found it!
create folder (specialFolderPath("documents") & "/sellnet")
NOT create folder (specialFolderPath("documents" & "/sellnet"))
Yahoo!
Simon
Yeah, Go, Simon, Go! :D

trags3
Posts: 432
Joined: Wed Apr 09, 2014 1:58 am

Re: Saving user modifications to Table Data

Post by trags3 » Fri May 16, 2014 7:45 pm

Klaus wrote:
Simon wrote:...
weeeee found it!
create folder (specialFolderPath("documents") & "/sellnet")
NOT create folder (specialFolderPath("documents" & "/sellnet"))
Yahoo!
Simon
Yeah, Go, Simon, Go! :D
Still does not save data between sessions

Tom

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Saving user modifications to Table Data

Post by Simon » Fri May 16, 2014 7:47 pm

Ok back a bit, is there a folder created?
Is the text file in it?
Whats in the text file?

Desktop only for the moment.

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

trags3
Posts: 432
Joined: Wed Apr 09, 2014 1:58 am

Re: Saving user modifications to Table Data

Post by trags3 » Fri May 16, 2014 7:50 pm

Simon & Klaus

You guys are the best! When correcting the code I made the mistale of copying a filename with a Capital letter in one place.
SUCCESS!! it all works now Thank you SOOOOOOO much fr the help

Tom

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Saving user modifications to Table Data

Post by Simon » Fri May 16, 2014 7:54 pm

YEAH!
YAHOO!
GREAT!
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Saving user modifications to Table Data

Post by Klaus » Fri May 16, 2014 9:17 pm

Hi Tom,
trags3 wrote:When correcting the code I made the mistale of copying a filename with a Capital letter in one place.
yep, that was what I was trying to tell you all the time! :D

Glad you solved it!


Best

Klaus

Post Reply