Java number calculation.

hi, i am doing java encryption/decryption and my key is 128 bits. i need to times multiple keys and thus, the value is far exceed the integer and long value.
thus i decide to use math.biginteger.
however, the calculation is weird.
here is my code
BigInteger biPdi = new BigInteger(bPdi); //bPdi is a bytearray
BigInteger biKey = new BigInteger(groupKey);//group key is a bytearray
BigInteger bicKey = new BigInteger(bicGroupKey));//bicgroupkey is a bytearray
System.out.println("derivationkey: " + biPdi.toString(16));
System.out.println("child group key: " + bicKey.toString(16));
b = biPdi.add(bicKey).toByteArray();     
BigInteger bit2 = new BigInteger(b);
System.out.println("derivationkey: " + bit2.toString(16));
this is the result i am getting back.
derivationkey: 30
child group key: 3938393951128f27c3da559f36ea62de
derivationkey: 3938393951128f27c3da559f36ea630e
i know the derivationkey has value "0" which is encode as "30" b/c it is based on 16. thus, the byte value is "48" which is the value of "0".
when i add derviationkey with child group key, i expect to my new diviationkey is same as childgroup key b/c it is childgroup plus 0. however, i am getting a different value. i think the reason is because java byte array try to add 30 to childgroup.
in this case, how can i do a large number calculation? can someone give me any advice??
Thanks in advance.

There's a button what says "code." Hit it and put your code inside the tags.
i know the derivationkey has value "0" which is
encode as "30" b/c it is based on 16. thus, the byte
value is "48" which is the value of "0".0 is zero no matter what the base. And 48 != 0 no matter how much paint you sniff (though it can seem that way).
when i add derviationkey with child group key, i
expect to my new diviationkey is same as childgroup
key b/c it is childgroup plus 0. however, i am
getting a different value. i think the reason is
because java byte array try to add 30 to childgroup.If it's 30 and you add it, the answer will come out as 30 more than the number you added to 30.
in this case, how can i do a large number
calculation? can someone give me any advice??BigInteger works like it should. derivationkey is 30.
~Cheers

Similar Messages

  • Error in mapping for floating Number calculation

    Hi All,
       I have a small doubt in floating number calculation in Mapping.
    Actually i am geting a floating point number and calculating the SUM and generating the output. The input is of 2 decimal places(Ex: 26.02  and 26.03 ), but when it is adding all the values it is generating a three digit decimal number (Ex: 52.050003)
    I dont know from where it is geting one extra number "2" in the output.
    Please find the code for the same and let me know if i need to do something else to get ride of this.
       //write your code here
    float sum=0;
    if(a != null && a.length > 0.00)
       for ( int j =0; j<a.length;j++)
        sum  =  sum + Float.parseFloat(a[j]);
       result.addValue(String.valueOf(sum));
    else
    result.addValue("0");
    Thanks in Advance,
    JAY

    Jay,
    Please use the below code and let us know, if it helps.
    BigDecimal sum= new BigDecimal("0");
    BigDecimal bd;
    if(a != null && a.length > 0.00)
    for ( int j =0; j<a.length;j++)
    bd=new BigDecimal(a[j]);
    sum=sum.add(bd);
    result.addValue(""+sum+"");
    else
    result.addValue("0");
    in import section - java.math.*;
    raj.
    Edited by: Raj on Feb 18, 2008 11:11 AM

  • Week number calculations not working ...

    Why doesn the week number calculation (ISO 8601) using datepart ('ww',#date#,crMonday,crFirstFourDays) not work?
    As an example do the following formula:
    DatePart('ww',CDate(2005,1,1),crMonday,crFirstFourDays)
    The result is 9363, quite an impressive week number
    This is an issue in versions 2008, XI R2, XI, 10 and possibly previous versions too

    Hi Raghavendra
    No I want to be able to calculate week number according to the week numbering definition from ISO 8601 - have a look at [http://en.wikipedia.org/wiki/ISO_week_date|http://en.wikipedia.org/wiki/ISO_week_date]
    If you want to use datepart ('ww, ... to solve this,
    you have to specify crMonday as third argument and crFirstFourDays as argument number 4 to tell datepart that weeks starts on mondays and week #1 is the one with the first 4 days of the year.
    Doing this makes my example date  used with datepart returns the week number 9363!!
    The DatePart('ww',CDate(2005,1,1),crMonday,crFirstFourDays) is supposed to return 53!!
    Weeknumbers are supposed to be between 1 and 52 or 53 depending of the year.
    Be aware weeks number 1, 52 and 53 very often contains days from 2 consequtive years, when defined according to ISO 8691.
    Your suggestion does not take into account the fact Weeks start on mondays and january 1st is not always the first day of week 1.
    It returns week number 1
    In fact it seems every day in the start of a year with weeknumber starting in the previous year gets the weeknumber calculated wrong.
    Regards,
    Poul
    Do you want to calculate the weeknumber of a particular date? If so please try datepart('ww',CDate(2005,1,1)).
    If not could you please explain me what you are trying to calculate and what output you are expecting?
    Regards,
    Raghavendra

  • Restrict Automatic serial number calculation for Production order release

    Hi,
    I need the solution for following requirement.
    Release production order(CO02) . Then go to Menu header-> Serial Numbers.
    Here I am getting serial numbers automatically as the material used in production order is set for automatic serial number calculation.
    But I want to restrict automatic serial number assignment based on production order type.
    If order type is 'XYZ', I dont want to calculate serial numbers automatically.
    Can anyone tell me how to do it?
    Regards,
    Manan Desai.

    When you press Release Order button the BADI 'WORKORDER_UPDATE->AT_RELEASE' will be called.
    At this point the internal tables for Serial numbers are filled by the program automatically.
    So call function module 'SERIAL_INTTAB_REFRESH' which will refresh the internal tables for serial numbers generated before teh serial number window pops up.
    Also at the BADI 'WORKORDER_UPDATE->AT_SAVE' call the same function module because before this BADI call when you press 'SAVE' the program again checks if automatic serial number is set for that material and if yes then check if no serial numbers are generated then it generates the serial numbers again and fills the internal tables. So clear the internal tables again based on the conditions.
    In these BADI's we have access of header information which can be used to check condition.
    I hope this will give you better idea.
    Thanks for your efforts.
    Manan Desai.

  • Mysteries of Java number 32,194

    Mysteries of Java number 32,194:
    Why the class URL has methods marked "protected", even though it is itself marked "final".
    Drake

    Hey they are thinking about it... for 3 years now http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4880778
    These things take time.

  • Java Mortgage Calculator

    Im having trouble making my GUI look the way I want it. Obviously I dont know enough about Gridlayout And I think I need to use GridBagLayout instead. I need the amortization schedule to print all the way out and everything to line up. If anyone has some suggestions I would love to hear it, and yes, this is my homework. see the code below:
    Main java file: implements MyFrame4 java file
    import java.awt.*; //imports awt
    public class MortgageCalculator4 {   // main MortgageCalculator class constuctor
    public static void main(String args[]) {  //implements MyFrame4
    Frame f = new MyFrame4();
    } //end of MortgageCalculator4 class
    Adapter java file: implements WindowAdapter
    import java.awt.*; //imports awt
    import java.awt.event.*;
    class MyAdapter extends WindowAdapter {   //creates window adapter
    Frame myFrame;
    MyAdapter(Frame f) {
    super();
    myFrame = f;
    public void windowClosing(WindowEvent e) {
    myFrame.dispose();
    } //end of MyAdapter class
    Frame java file: main body of program implemented by MortgageCalculator file
    import java.awt.*; //imports awt's
    import java.awt.event.*;
    import java.text.DecimalFormat;
    import javax.swing.*;
    class MyFrame4 extends Frame implements TextListener, ActionListener {    //class constructs the frame and layout
    Button loanButton1 = new Button("Loan 1"), //creates and labels buttons
    loanButton2 = new Button("Loan 2"),
    loanButton3 = new Button("Loan 3"),
    clearButton = new Button("clear/New");
    TextField principalField = new TextField("0.00", 15), //sets TextField properties
    rateField = new TextField("0.00", 3), //adds field lenghts and initial properties
    yearsField = new TextField("0", 3),
    paymentField = new TextField("0.00", 15),
    intpaymentTextArea = new TextField("0.00", 40);
    double principal, rate, ratePercent; //assigns variables
    int years, n;
    final int paymentsPerYear = 12;
    final int timesPerYearCalculated = 12;
    double effectiveAnnualRate;
    double payment;      
    public MyFrame4() { //beginnig of frame constructor
    setTitle("Mortgage Payment Calculator");
    setLayout(new GridLayout(14, 2));
    Label title1Label = new Label("Enter loan amount then select a loan option");
    Label title2Label = new Label("or enter an interest rate and years");
    Label principalLabel = new Label("Loan Amount $"), // constructs labels
    rateLabel = new Label("Rate (%)"),
    yearsLabel = new Label("Years"),
    loan1Label = new Label("7 years at 5.35%"), //asigns labels
    loan2Label = new Label("15 years at 5.5%"),
    loan3Label = new Label("30 years at 5.75%%"),
    paymentLabel = new Label("Payment $"),
    intpaymentLabel = new Label("Ammortization Schedule");
    Panel title1LabelPanel = new Panel (new FlowLayout(FlowLayout.RIGHT));
    Panel title2LabelPanel = new Panel (new FlowLayout(FlowLayout.RIGHT));
    Panel principalLabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)), // places label positions and button panels
    loan1LabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    loan2LabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    loan3LabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    rateLabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    yearsLabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    paymentLabelPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    intpaymentLabelPanel = new Panel(new FlowLayout(FlowLayout.CENTER));
    Panel principalFieldPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    loan1ButtonPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    loan2ButtonPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    loan3ButtonPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    rateFieldPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    yearsFieldPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    paymentFieldPanel = new Panel(new FlowLayout(FlowLayout.LEFT)),
    clearButtonPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    blankPanel = new Panel(new FlowLayout(FlowLayout.RIGHT)),
    intpaymentTextAreaPanel = new Panel(new FlowLayout(FlowLayout.RIGHT));
    title1LabelPanel.add(title1Label);
    title1LabelPanel.add(title2Label);
    principalLabelPanel.add(principalLabel); //adds labels buttons and fields
    principalFieldPanel.add(principalField);
    loan1LabelPanel.add(loan1Label);
    loan1ButtonPanel.add(loanButton1);
    loan2LabelPanel.add(loan2Label);
    loan2ButtonPanel.add(loanButton2);
    loan3LabelPanel.add(loan3Label);
    loan3ButtonPanel.add(loanButton3);
    clearButtonPanel.add(clearButton);
    rateLabelPanel.add(rateLabel);
    rateFieldPanel.add(rateField);
    rateField.setEditable(true);
    yearsLabelPanel.add(yearsLabel);
    yearsFieldPanel.add(yearsField);
    yearsField.setEditable(true);
    paymentLabelPanel.add(paymentLabel);
    paymentFieldPanel.add(paymentField);
    paymentField.setEditable(false);
    intpaymentLabelPanel.add(intpaymentLabel);
    intpaymentTextAreaPanel.add(intpaymentTextArea);
    intpaymentTextArea.setEditable(false);
    add(title1LabelPanel);
    add(title2LabelPanel);
    add(principalLabelPanel);
    add(principalFieldPanel);
    add(loan1LabelPanel);
    add(loan1ButtonPanel);
    add(loan2LabelPanel);
    add(loan2ButtonPanel);
    add(loan3LabelPanel);
    add(loan3ButtonPanel);
    add(rateLabelPanel);
    add(rateFieldPanel);
    add(yearsLabelPanel);
    add(yearsFieldPanel);
    add(paymentLabelPanel);
    add(paymentFieldPanel);
    add(clearButtonPanel);
    add(intpaymentLabelPanel);
    add(blankPanel);
    add(intpaymentTextAreaPanel);
    loanButton1.addActionListener(this); //assigns ActionListener to buttons
    loanButton2.addActionListener(this);
    loanButton3.addActionListener(this);
    clearButton.addActionListener(this);
    principalField.addTextListener(this); //adds TextListener to fields
    rateField.addTextListener(this);
    yearsField.addTextListener(this);
    addWindowListener(new MyAdapter(this));
    pack(); //resizes window to fit components
    setVisible(true);
    DecimalFormat currency = new DecimalFormat("####0.00"); //sets currency format
    public void actionPerformed(ActionEvent e){ //checks for buttons clicked and sets variables to fields
         //wanted to get data from array but couldnt make it work
              if(e.getSource() == loanButton1){
                   rateField.setText("5.85");
                   yearsField.setText("7");
         if(e.getSource() == loanButton2){
                   rateField.setText("5.5");
              yearsField.setText("20");           
              if(e.getSource() == loanButton3){
                   rateField.setText("5.75");
              yearsField.setText("30");     
              if(e.getSource() == clearButton){
                   rateField.setText("0.00");
              yearsField.setText("0");
              principalField.setText("0.00");           
    public void textValueChanged(TextEvent e) {  //checks field variables and sends to calculations
    Object source = e.getSource();
    if (source == principalField
    || source == rateField
    || source == yearsField) {
    try {
    principal = Double.parseDouble(principalField.getText()); //perform calculations for payment
    ratePercent = Double.parseDouble(rateField.getText());
    rate = ratePercent / 100.0;
    years = Integer.parseInt(yearsField.getText());
    n = paymentsPerYear * years;
    effectiveAnnualRate = rate / paymentsPerYear;
    payment =
    principal
    * (effectiveAnnualRate
    / (1 - Math.pow(1 + effectiveAnnualRate, -n)));
    DecimalFormat payForm = new DecimalFormat("####.##"); //performs calculations for Ammortization text area
    int num_Months = years*12;     
    double i = ratePercent/1200;
    payment = principal*((i*(Math.pow((1+i),num_Months)))/((Math.pow((1+i),num_Months))-1));               
    int num_Payments = num_Months-1;
    int month_counter = 0;
    double intPaid = 0;
    double balance = principal;
    intpaymentTextArea.setText("");
    while (month_counter <= num_Months){
    intPaid = balance * i;
    balance = balance - (payment - intPaid);
    intpaymentTextArea.setText(("Month ")+month_counter+( " - Payment: $")
    payForm.format(payment)" Balance: "
    payForm.format(balance)(" Interest Paid: $")
    payForm.format(intPaid)"\n");
    month_counter++;
    paymentField.setText(currency.format(payment)); //display payment
    } catch (NumberFormatException ex) {  //catch exceptions
    } //end of MyFrame4 Class

    Another suggestion is post only the necessary code that exemplifies the unexpected behavior, and don't forget to use code tags when you're posting code. Look for CODE button when writing the post! This way your code will be well formatted and more readable. It also increases the chance of someone reading it and help you.

  • Java variables calculation on change in JSP (Excel replica)

    I have a excel sheet that I need to replicate in JSP (using struts 1 framework). Now everything is done but I am stuck at the calculation part. As you might have seen in excel, some columns are calculations based on other columns.
    So if I change field 'a', 'd' field should change automatically based on its formula (let's say, d=a*1.1 +b*2.1).
    Now I tried to use the funstion in javascript where I read 'a' and 'b' values from JSP, then I calculate and everything works fine. But when I try to assign the calculation result for field 'd' in JSP throush javascript, 'd' does not change.
    function adjustCalcs ()
    var a = eval("document.form.al.value");
    var b = eval("document.form.b.value");
    var dCalc = ((a * 1.05) + (b * 1.1));
    document.form.d.value = dCalc ; (this is where it should change the value of field 'd' in JSP, but ti won't...donno why?)
    Or is there any better way to do these dynamic changes in JSP ? Would appreciate the insight.
    Thanks,

    Fine. What's your problem in JSP side then? Do you want to let Java take over the calculation and "dynamic stuff" ? Then you need to let Javascript submit the form to the server side during the change event so that JSP can then display the result using taglibs/EL. But this is less good for user experience as this costs effectively one HTTP request and the user would see a "flash of content". Alternatively you can use Ajax for this to do it all asynchronously.

  • Java number formats?

    Hi.
    I am writing a program which contains a simple division code. The operation divides a word's frequency in a file by the number of words in that file. This is a code strip
    wordCount = wordsInFile(file2); //number of words in file is obtained from a static method
    String w = wordFreq.get(i).toString(); // I get the frequency of the word from an array list
    double wf = Double.parseDouble(w);
    double normalFreq = wf/wordCount;problem is that sometimes this program produces numbers like this : 8.025682182985554E-4
    I have no idea what this means and how to fix it. Is there a specific number format that I should use to avoid this?
    Thanks!
    Message was edited by:
    Yorae

    Hi.
    I am writing a program which contains a simple
    division code. The operation divides a word's
    frequency in a file by the number of words in that
    file. This is a code strip
    wordCount = wordsInFile(file2); //number of
    words in file is obtained from a static method
    String w = wordFreq.get(i).toString(); // I get the
    frequency of the word from an array list
    double wf = Double.parseDouble(w);
    double normalFreq = wf/wordCount;problem is that sometimes this program produces
    numbers like this : 8.025682182985554E-4
    I have no idea what this means and how to fix it. Is
    there a specific number format that I should use to
    avoid this?
    Thanks!
    Message was edited by:
    YoraeTake a look at java.text.DecimalFormat
    double normalFreq = wf/wordCount;
    DecimalFormat df = new DecimalFormat("#.##");
    String output = df.format(normalFreq);
    System.out.println("The formatted double is " + output);This should truncate any digits after the second decimal place (I think it rounds it for you but I havent checked).

  • Java number game confused help any1!

    The following simple game is played between a player and the computer. At the
    start the player enters either the number one or two on the keyboard (the computer will also
    choose either one or two at random). Then the computer draws two numbers between one and
    one hundred at random. The human player wins if the number in position corresponding to the
    number he selected is bigger than the number in position corresponding to the number chosen by
    the computer. If the two numbers are the same (either because the player and the computer chose
    the same value or because the random numbers in the chosen positions are the same) the game
    ends in a draw. The code doen't work properly it etiher comes up with computer wins and draw at the same time! Also i need to display the numbers that are generated randomly can anyone help my code:
    import java.lang.Object;
    import java.lang.System;
    import java.io.InputStream;
    import java.util.Scanner;
    class javataex1 {
    public static void main(String[] args) {
    // declarations
    Scanner input = new Scanner (System.in);
    int human ;
    int computer;
    int Number1;
    int Number2;
    //instructions
    Number1=(int) Math.ceil(100*Math.random());
    Number2=(int) Math.ceil(100*Math.random());
    computer=(int) Math.ceil(2*Math.random());
    System.out.print("Enter number 1 or 2: ");
    human = (input.nextInt());
    if (human!=1 && human!=2)
    System.out.println("you entered wrong number");
    else
    if (human==computer)
    System.out.print("Draw");
    else
    human=Number1;
    computer=Number2;
    if (human==computer)
    System.out.print("Draw");
    else
    if (human>computer)
    System.out.print("Human wins");
    else
    if (computer>human)
    System.out.print("Computer wins");
    }

    Crosspost
    http://forum.java.sun.com/thread.jspa?threadID=5245168&tstart=0
    Only post on one forum at a time, please. I think someone answered you in the other thread anyway.
    Illu

  • Java & NUMBER type

    How can I get a NUMBER(5, 7) from a db Oracle.
    I've tried with rs.getDouble, but i don't get espected result!
    I have jdk1.2.2 and I use a thin driver.

    useoracle.jbo.domain.Number Number n = new Number(100);
    java.lang.float f = n.floatValue();Timo

  • Java Memory Calculation

    Dear all,
    I have class
    Student{
    private int id;
    And my program, init array 10000000 student object.
    size = 10000000;
    Student[] sts = new Student[size];
    for(int i = 0; i< size; i++){
    sts[i] = new Student();
    Learning from
    http://www.javamex.com/tutorials/memory/object_memory_usage.shtml
    and
    http://www.javamex.com/tutorials/memory/array_memory_usage.shtml
    I calculation the memory usage for my programe is
    - 8: house keeping
    - 4 leng
    - size * 4 (object reference)
    - Each Student object size take (8 byte house keeping + 4 byte for id) = 12, padding 4 => 16 byte
    So the total memory is 8 + 4 + 4*size + 16*size = 20*size + 12 ~ 190M
    But the momory usage for my program is 277MB. That is the large difference.
    Could you give me some advice?
    Thank a lot for support.

    Helo..
    Using Windows Task manager is not the proper way to measure a Java programs Memory usage.
    Reason:When you run a java program ,it also requires the underlying JRE to run ,so the memory used for a java process in this case would be the memory for the Java programs Objects and also for the entire JRE.
    The Best way to measure your application's performance is use either of the two free tools:
    1.JConsole-its comes along with JDK. JDK_HOME/bin/jconsole
    2.Any Profiler Programs:A profiler for Java is a program which allows you to trace a running java program and see the memory and CPU consumption for the Java application.Netbeans comes with its own profiler.you can chk this out.
    The other option is to measure free memory before and after execution of the program using System Util Class.
    Hope this clarifies your qn.
    Thanks.

  • Cust  for Item number calculation when creating/changing a sales orders

    Hi
      I need to know if the item number when capturing/ modifying  a sales order can be calculated automatically with some route in the customizing,  or do I need to do it with some user exit in the sales order entry?.
    Thanks!
    Regards
    Soraya

    Hi,
    Goto the T.Code "VOV8".
    Select your order type.Details.
    Goto the "Number systems" tab.
    Maintain the value as "10" or "15" like this any number as per your requirement for the field "Item no.increment".
    So that the main item will be incremented by the number you specified here.Suppose you specified the number as "10" the line item numbers would be 10,20,30,.....
    Next is if you maintain the value for the field "Sub-item increment" then the sub items will be incremented by the number you specified here.
    It would be mainly used in the case of BOM.
    To get the numbers from the order,goto the T.Code "SE11/SE16".
    Enter the table name as "VBAP".
    Pass the order number.Execute.
    You will get the all line items with numbers.
    Regards,
    Krishna.

  • EPOS Java Number Rounding Problem

    I am developing a java EPOS system and am having a strange issue with number accuracy that doesnt make any sense to me.
    On a till system you have a user display of the form
    0000000.00
    When you type into this for example the number 7 then the number 8 it goes
    0000000.07
    0000000.78
    Moving along the screen.
    I cant figure out how to represent this accurately (ie using floats) but still have the functionality to append onto the float, not add to it.
    i have come up with the following
            Float tempNum = currentNum*10;
            StringBuffer sb = new StringBuffer(tempNum.toString());
            sb.append(i);
            String s = sb.toString();
            currentNum = Float.valueOf(s).floatValue();
            updateOutputs();With the basic idea being casting to a string buffer, appending then casting back of sorts but i get accuracy issues...
    Pressing 7 a whole bunch of times gives 7777.9995 not 7777.77 etc
    I know there must be a simple and more elegant way to solve this problem but i just cant seem to think around it right now.
    Thanks

    This is an input panel on an EPOS system, but as im designing it for touch screen it has an on screen number pad and display of the number.
    When the buttons are pressed for the numbers that number is appended to the internal integer storage value. Also the output string is updated.
    Most till systems allow you to enter up to X digits until then ignore what you type or print an error, so i am happy to follow this behavior but require the digit count.
    I hope that makes sense but if not my gui is similar to these...
    http://www.tillrollshop.co.uk/asps/uploads/big/1205-1.jpg
    http://www.mi-store.com/mi-store/Till_Main.jpg
    The second image shows a number pad and label just like mine.
    Thanks

  • Acrobat Pro 9, why is it ignoring my java script calculations?

    I am using a PC with Windows XP on it. This has happened many times, and I cant figure it out. I have layed out all of my cells and have given one column the java script commmand to subtract two other columns. I saved it, tested it, closed it, opened it and tested it again. Everything worked fine. I have come back into work this morning to find that the java script is still there and there are still 0's in the column, but it will not calculate anything. What's wrong?
    thanks!

    What  extra work! two, three lines of extra code (may just one) to put a time limit in, that can be overridden with entering a bought serial number. Even shareware peopel do it.
    And I remeber when Acrobat only worked on Mac's. You see it was introduced to Mac's first. Microsoft wouldn't allow it until version 3 or 4.  If I still had my 7100/66 I might could prove was I one of the beta Testers. But that machine was traded in on the G4-500 (which I still own).
    Most major software companies will come out with a new application on the Mac first. Because Mac users tend tobe willing to try out something new on the cutting edge. Then when its prefected they come out with a PC version, and forget about the Mac community.
    Look I am 61. And I didn't just fall off the turnip truck yesterday. I've been around since before the days of the moden internet. I  started with Buliten Boards on 300 baud modem on an old fashion POTS line.  Cost me a fortune in Phonebills
    So don't discount my experiences so lightly. I've used appliactions such as ATM Aldus PageMaker (yes you heard right Aldus). I've use Word Perfect for Mac and PC back when it was owned by WordPefect, then Novell) I've use Microsoft works when it came out for the SE/30. Lotus 1-2-3 both on Mac and PC, FaxSTF, and other that are now none existent on the Mac. Chance are I was using Computers about the same as some of you and probabaly earlier than some. I lived it.

  • No idea about Java or calculating script

    My problem is most likely a pretty simple one (not for me however).   I have eight boxes with user entered numbers and one box at the bottom that needs to total the amounts from the other boxes.   This total needs to be calculated ONLY when the checkbox next to each user entered number is checked.   I am so lost when it comes to this stuff.  Any help, without the script-speak or computer elitest terms, would be greatly appreciated.   I made the document in word, created a PDF and have edited it entirely through LiveCycle.   Thanks for the help.

    Hi,
    Mind if I chime in?
    I would do this using formCalc and a loop with a test for each checkbox. Put the script on the Grand Total field Calculate event:
        $ = 0
        var total = 0
        for i = 0 upto 8 do
            if (RowItem[i].CheckBoxAccept == "1") then
                 total = RowItem[i].NumItemAmt + total
            endif
            continue
        endfor
        $ = total
    Then I would have a "Accept All" checkbox (instead of clicking 9 times if you want to accept everyhing). Put a checkbox in the total row and on the Change event using formCalc like this:
        if ($ == "1") then
            RowItem[*].CheckBoxAccept = "1"
        elseif ($ == "0") then
            RowItem[*].CheckBoxAccept = "0"
        endif
        xfa.form.execCalculate()
    These 2 scripts may be one of the shortest ways to fo it. You have to name all the like items the same. And, you can easily adapt this for having multiple instances.
    Good luck!
    Stephen

Maybe you are looking for

  • SQL Code not working in Forms Developer without Functions?

    Hi all, I've write this code into Forms at it's work correctly in SQL and the following error occurened The PL-SQL Code: DECLARE      Product_Name Products.Name%TYPE;      Most_Occurence NUMBER(10); BEGIN      SELECT *      INTO Most_Occurence, Produ

  • No records in main.active table?

    I just updated my Muse, made a few changes to my site and saved. While saving, Muse crashed. Now when I try opening the site I receive the message "This Adobe Muse site file cannot be opened. no records in main.active table"? I freaking out here a li

  • How to use this API?

    Hi all, I have a doubt, I have to test an app which works with the API JavaPOS, I have downloaded it but now I don�t know what to do with it. I mean, I don�t know how I can import its classes and such things for it to be recognize by the java app. An

  • Unicode baltic charachters in plsql

    Hello, im creating a number spell function based on [Tom Kyte's article |http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:1407603857650] I have unicode letters in my plsql function as : , 'fifty' , 'penkiasdešimt' when i run the co

  • Iphoto hogs my cpu, even when running in the background

    Hi, I can't leave iPhoto running in the background because it regularly uses 47% to 98% of my cpu (although there are times that it only uses 12%).  Eventually the computer heats up to over 200 degrees (F) and freezes, forcing a hard re-start.  I did