-JScript runtime error-

For discussion about the NBOS Character Sheet Designer and Viewer.

-JScript runtime error-

Postby ChaosJudge » Sat Feb 26, 2011 10:35 pm

Hello I have been making a sheet that takes points form one "box" to add to another "box" (or the other way around) and i keep getting a run time errors. If would be awesome if someone could help me. ^_^
ChaosJudge
Torch Bearer
 
Posts: 6
Joined: Sat Feb 26, 2011 10:18 pm

Re: -JScript runtime error-

Postby MarkOliva » Sun Feb 27, 2011 12:00 am

ChaosJudge wrote:Hello I have been making a sheet that takes points form one "box" to add to another "box" (or the other way around) and i keep getting a run time errors. If would be awesome if someone could help me. ^_^


That's difficult, if you don't post the code segment that causes the problem.
Mark Oliva
The Vintyri (TM) Project
http://www.vintyri.org
info@vintyri.org
User avatar
MarkOliva
Name Level
 
Posts: 332
Joined: Sat Jul 11, 2009 5:17 am
Location: Altershausen, Northern Bavaria, Germany

Re: -JScript runtime error-

Postby ChaosJudge » Sun Feb 27, 2011 12:36 am

Sorry that was a little dum of me :P I put colored boxes to make it easier to see what is going where. I would just like there to be a 0 in Total Points and when i push the plus sign it becomes a 1 then a 2 then a 3... Thanks for the help :)
Attachments
bleach.csd
(57.75 KiB) Downloaded 86 times
ChaosJudge
Torch Bearer
 
Posts: 6
Joined: Sat Feb 26, 2011 10:18 pm

Re: -JScript runtime error-

Postby Ed_NBOS » Sun Feb 27, 2011 3:16 am

Are you asking how to run a function when a button is pressed? Assign a function call to the source for the button. That will get run when you click on it. See the 'two page' character sheet included as a sample as an example of this.

If you want to use the same function to add to different fields, pass the text field being changed as a parameter to the button's source. You can see that being done in the two-page example as well.
Ed_NBOS
Site Admin
 
Posts: 522
Joined: Wed Jul 08, 2009 12:16 am

Re: -JScript runtime error-

Postby ChaosJudge » Sun Feb 27, 2011 1:37 pm

O cool thanks... Yeah i was putting
function TotalPoints( f)
{
f = f +1;
}

when really it needed

function TotalPoints( f)
{
f.Text = f.Value + 1;
}
ChaosJudge
Torch Bearer
 
Posts: 6
Joined: Sat Feb 26, 2011 10:18 pm

Re: -JScript runtime error-

Postby ChaosJudge » Sun Feb 27, 2011 3:41 pm

I have another problem. Im trying to make it when the user levels it adds a number to the sum of "Total Points" and still allows me to add and subtract form it, as of right now it does not even show the sheet viewer.
Attachments
bleach.csd
(55.27 KiB) Downloaded 94 times
ChaosJudge
Torch Bearer
 
Posts: 6
Joined: Sat Feb 26, 2011 10:18 pm


Return to Character Sheet Designer General

Who is online

Users browsing this forum: No registered users and 0 guests