Results 1 to 3 of 3

Thread: how can i add all this varible togeather

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 1999
    Posts
    219

    Post

    a = Text16.Text * 2
    b = Text14.Text * 2
    c = Text12.Text * 2
    d = Text10.Text * 2
    e = Text8.Text * 2
    f = Text6.Text * 2
    g = Text4.Text * 2
    h = Text2.Text * 2

    i have to what Add1 = len(((a + b) + (c+d)) + ((E+f) + (g + h )))

  2. #2
    Hyperactive Member
    Join Date
    Sep 1999
    Location
    Leeds, UK
    Posts
    287

    Post

    Could you please elaborate? I'm not quite sure what you're trying to do.

    ------------------
    rino_2
    Visual Basic, HTML

  3. #3
    Guest

    Post

    a = Val(Text16.Text) * 2
    b = Val(Text14.Text) * 2
    c = Val(Text12.Text) * 2
    d = Val(Text10.Text) * 2
    e = Val(Text8.Text) * 2
    f = Val(Text6.Text) * 2
    g = Val(Text4.Text) * 2
    h = Val(Text2.Text) * 2
    Assuming these are numeric values.

    Add1 = len(((a + b) + (c+d)) + ((E+f) + (g + h )))
    Mathematically speaking you don't need all those parens.....
    Add1 = Len(a + b + c + d + e + f + g + h)
    Also the length function will only give you the length of the value returned..... like 2 or 3

    -----------------------------------
    Or this could be what you possibly mean.....

    a = Len(Text16.Text) * 2
    b = Len(Text14.Text) * 2
    c = Len(Text12.Text) * 2
    d = Len(Text10.Text) * 2
    e = Len(Text8.Text) * 2
    f = Len(Text6.Text) * 2
    g = Len(Text4.Text) * 2
    h = Len(Text2.Text) * 2

    Add1 = a + b + c + d + e + f + g + h

    Assuming Add1 was defined as a numeric.

    Hope this helps.


    ------------------
    Boothman
    There is a war out there, and it is about who controls the information, it's all about the information.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width