+ Reply to Thread
Results 1 to 4 of 4

Problems with viewing values in simple calculations

  1. #1
    Registered User
    Join Date
    10-26-2012
    Location
    Gdansk, Poland
    MS-Off Ver
    Excel 2007
    Posts
    13

    Problems with viewing values in simple calculations

    Hi,

    Could anyone help with the following query?

    i created a userform that calclulates the differences of "before" and "after" both for individual values and total. Why do I get "1" in "Total before" even though there is 1,2 in the first value of before?

    ______before___after____difference
    1_______1,2______2_______ 0.8
    2________0______0_________0
    Total_____1______2________0.8

    Total1 is defined by
    TextBoxTotal.Value = Val(TextBox1before.Value) + Val(TextBox2before.Value)

    Thanks!
    Last edited by jazz_bass; 10-26-2012 at 04:10 PM.

  2. #2
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Problems with viewing values in simple calculations

    hi jazz_bass, try replace coma with a dot in "1,2" and you should get what you want

  3. #3
    Registered User
    Join Date
    10-26-2012
    Location
    Gdansk, Poland
    MS-Off Ver
    Excel 2007
    Posts
    13

    Re: Problems with viewing values in simple calculations

    already tried that.
    when i use coma i get runtime error 13 - type mismatch.

  4. #4
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Problems with viewing values in simple calculations

    post your workbook with the userform and coding

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1