View Single Post
Old 2008-03-26, 14:42   #7
AES
 
Jul 2007
Tennessee

10768 Posts
Default

Isn't "job" the array from the joblist file?

You could just add:
Code:
write(fileprime, format("user=%s\n", job.user))
Function OnPrime:
Code:
function OnPrime(t, k, n, job)
   local fileprime = openfile("primes.txt", "a")
   if fileprime then
      write(fileprime, format("user=%s\n", job.user))
      write(fileprime, format("[%s]\n", job.resultdate))
      write(fileprime, format(displayFormat.." is prime!  Time : %d.0 sec.\n",
                  k, n,
                  Seconds() - job.seconds))
      closefile(fileprime)
   end
end
AES is offline   Reply With Quote