Samurize script for Seti?

Originally posted by Berserker
Are you guys sure samurize is using the .net runtime components, and not the older VB runtime components?

Quite possible!
The .net runtime does contain some vb dll's if I remember correctly.
However, my windows/system32 contains VB5 & 6 kits

VB5StKit.dll
VB6STKIT.DLL
msvbvm50.dll
msvbvm60.dll

So that may be worth checking.

Garp . The usual reason for 'username not found' [other than as you rightly point out being setup] is b0rkley playing up and the script is unable to grab the xml page. A reload usually cures (ok yeah when the scripts working anyway) With regard to the problem with the temp file possibly not being processed I have had AV software dissallow VB scripts to write files as they treat this as malicious. However someone reported earlier that they did not run AV and still got no joy ..... ho hum

Seems definate that its something peculiar to an individuals setup as to whether it works or does not, just a case of going thru and finding what?!?!?!?


/scratches head

/gets more beer
 
Nah, its definately got the data. I've fudged the vbscript and got something that works, but its a real bodge job, can't guarantee it'll work for everyone. I'll post the relevant data later when I'm back home
 
edit: Shove that.. its so dodgy it no longer works :D

My errors are purely down to how it reads the temp file into the script.
I can bodge the script each time for each file, but its not a long term solution.
 
Weell, I've just started tinkering around with this and it is pretty good, but not without problems. I put a script in for seti and it work in the samurize config window but when I save it and reload the file it doesn't show up. It's the same with the one for my clockspeed. Any ideas where I'm going wrong?:confused:
 
I KNOW WHAT IT IS!

Its just suddenly struck me why the "name" parsing line has "</a>" in it on that script. Its looking for the end of an website link! My bodge involved removing that and then redoing the 'count'.

I bet those of you who have got it to work have got a website associated with your name on the SETI@home website.
I don't, hence my XML data won't have a </A> tag as part of my name!
 
if this is correct and you've removed the offending </A> does your script now fully work? if it does can you copy and paste the changes you made on to this thread so we can all change this bit :D

<edit> think i found the </a> you were on about and removed it, when i ran it this came up

l version="1.0" encoding="iso-8859-1" ?>
<!DOCTYPE userstats SYSTEM "http://setiathome.ssl.berkeley.edu/xml/userstats.dtd">

<userstats>

i have no idea as to what this means but its the best its worked so far, and at least were getting somewhere :) </edit>
 
Last edited:
now theres a good idea worth doing i'll try that after my tea :) and let everyone know if it works , that way anyone clicking my name will get pointed to this mighty team and who knows they might join :D
 
Originally posted by Jem
if this is correct and you've removed the offending </A> does your script now fully work? if it does can you copy and paste the changes you made on to this thread so we can all change this bit :D

<edit> think i found the </a> you were on about and removed it, when i ran it this came up

l version="1.0" encoding="iso-8859-1" ?>
<!DOCTYPE userstats SYSTEM "http://setiathome.ssl.berkeley.edu/xml/userstats.dtd">

<userstats>

i have no idea as to what this means but its the best its worked so far, and at least were getting somewhere :) </edit>

Yeah, thats what it did on mine, so I fudged the counting a bit to make it work. Evidentally it doesn't make it work all the time.

I'm going to add a web pointer when I get home.
 
Originally posted by Jem
well that didnt work:( so its back to the drawing board so to say :(

I think part of the problem is berkely are going up and down more frequently than a lady of the night! Bloomin' eck. I can't get my stats to appear consistantly in the browser, let alone Samurize collect them.
 
its not borkeley even though there up&down like a hores under garments:D , all i get still is that "mid" error still on making the changes, i've even tried it on a diff rig and still this annoying popup saying the "mid" error :mad:
 
Jem, download this file , and replace every instance of my e-mail address with yours, and change the seti directory as well.

Give that a whirl, and see what happens.
Its now working fine for me.
 
Originally posted by Garp
I KNOW WHAT IT IS!

Its just suddenly struck me why the "name" parsing line has "</a>" in it on that script. Its looking for the end of an website link! My bodge involved removing that and then redoing the 'count'.

I bet those of you who have got it to work have got a website associated with your name on the SETI@home website.
I don't, hence my XML data won't have a </A> tag as part of my name!


Well spotted 'sah :)
As usual I was looking to deep to spot that!!!!

Originally posted by si_sleaf
Weell, I've just started tinkering around with this and it is pretty good, but not without problems. I put a script in for seti and it work in the samurize config window but when I save it and reload the file it doesn't show up. It's the same with the one for my clockspeed. Any ideas where I'm going wrong?

Ummm minght be a bit grandma sucking eggs time but only thing I can think of is ensure you name the script with a .vbs extension [or equally .js if its javascript] as anything else will not show up on the script pulldown menu.
Prolly not that but all I can think of right now....

[edit] or did you mean it doesn't show up on the desktop sorry should have checked first [/edit]


Sp!
 
Last edited:
Thank Garp ;) works ok now.

Just out of curiousity and to learn more about this what exactly did you change on the setionline section?
If poss could you paste the section you changed on here so we can see what & where you altered it?:D
 
Originally posted by Jem
Thank Garp ;) works ok now.

Just out of curiousity and to learn more about this what exactly did you change on the setionline section?
If poss could you paste the section you changed on here so we can see what & where you altered it?:D

Yup no problem at all [as long as you dont laugh cos its just a quick/dirty fix]

Ok this is cut from the SETIProgress function

Original Code:

tpx = split(statetmp, vblf)
prog = Mid(tpx(4), 6)
progtmp = CLng(prog)/1000000
progtmp = Round(progtmp,dec)
done = progtmp & "%"
cpu = Mid(tpx(3), 5)
prog = Mid(tpx(4), 6)
totaltimetmp = CDbl(cpu) / CDbl(prog) * 100
timelefttmp = totaltimetmp - CDbl(cpu)/1000000
hours = Fix(timelefttmp / 3600)
minutes = Fix( ( (timelefttmp / 3600) - hours) * 60)
seconds = Fix( ( ( ( (timelefttmp / 3600) - hours) * 60) - minutes)*60)
timetogo = hours & "h " & minutes & "m " & seconds & "s"
cpu = Mid(tpx(3), 5)
prog = Mid(tpx(4), 6)
totaltimetmp = CDbl(cpu) / CDbl(prog) * 100
hours = Fix(totaltimetmp / 3600)
minutes = Fix( ( (totaltimetmp / 3600) - hours) * 60)
seconds = Fix( ( ( ( (totaltimetmp / 3600) - hours) * 60) - minutes)*60)
tottime = hours & "h " & minutes & "m " & seconds & "s"


And here is the Edited Code:


tpx = split(statetmp, vblf)
prog = Mid(tpx(4), 6)
progtmp = prog * 100
progtmp = Round(progtmp,dec)
done = progtmp & "%"
cpu = Mid(tpx(3), 5)
prog = Mid(tpx(4), 6)
totaltimetmp = cpu / prog
timelefttmpA = ( totaltimetmp / 100 ) * progtmp ' This is the bit everyone
timelefttmp = totaltimetmp - timelefttmpA ' CAN laugh at :-(
hours = Fix(timelefttmp / 3600)
minutes = Fix( ( (timelefttmp / 3600) - hours) * 60)
seconds = Fix( ( ( ( (timelefttmp / 3600) - hours) * 60) - minutes)*60)
timetogo = hours & "h " & minutes & "m " & seconds & "s"

cpu = Mid(tpx(3), 5)
prog = Mid(tpx(4), 6)
totaltimetmp = cpu / prog
hours = Fix(totaltimetmp / 3600)
minutes = Fix( ( (totaltimetmp / 3600) - hours) * 60)
seconds = Fix( ( ( ( (totaltimetmp / 3600) - hours) * 60) - minutes)*60)
tottime = hours & "h " & minutes & "m " & seconds & "s"


As you can see not a huge edit. I can see why the first code should work but I cant MAKE it work? But as I said I am no vbs scripter. Also I have done away with the longs and doubles [C programmers note :) ] This MAY cause untold problems and spurious results but as yet it is ok.

The only other edit was altering
result = replace(result, "<top_rankpct>", top_rankpct)

to read
result = replace(result, "<top_rankpct>", 100-top_rankpct)

This then gives you users behind you rather than in front! [A MUCH more satisfying figure]


Sp!
 
Back
Top Bottom