+ Reply to Thread
Results 1 to 10 of 10

Combobox is changing decimal point from "'," to "."

  1. #1
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Combobox is changing decimal point from "'," to "."

    Hi,

    I am using combobox rowsource from listobjects:

    Screenshot_7.png

    And values are separated with "," - it is consistent with my polish regional settings (comma as decimal point).

    But when i am choosing one value from list - combobox automatically converting this to "." as decimal point.

    Screenshot_8.png

    Why? How to avoid this?
    Please help,

    Let the Joy be with you,
    Thank you in advance,
    BEst,
    Jacek Antek
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor Haluk's Avatar
    Join Date
    02-14-2019
    Location
    Turkiye
    MS-Off Ver
    2010 - 64 Bit on Windows-11 (22 H2) 64 Bit
    Posts
    1,150

    Re: Combobox is changing decimal point from "'," to "."

    You can fetch the values as Text. See the below code if this helps;

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Combobox is changing decimal point from "'," to "."

    o thank you!

    so the list is taken as number and this is why this is causing the error.
    O wow. Hmm what if my list will have thousends of records? Looping throguh all of them ?
    It will take a very long time.

    Best,
    jacek

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,908

    Re: Combobox is changing decimal point from "'," to "."

    Maybe this works for you.
    Please Login or Register  to view this content.
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

  5. #5
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Combobox is changing decimal point from "'," to "."

    Great working!!

    Best,
    Jacek

  6. #6
    Valued Forum Contributor Haluk's Avatar
    Join Date
    02-14-2019
    Location
    Turkiye
    MS-Off Ver
    2010 - 64 Bit on Windows-11 (22 H2) 64 Bit
    Posts
    1,150

    Re: Combobox is changing decimal point from "'," to "."

    Another alternative is:

    Please Login or Register  to view this content.

  7. #7
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Combobox is changing decimal point from "'," to "."

    Hi,

    sorry i have to reopen topic. After change event combobox (even i have values with "," as decimal point) is converting values like "1,67" to "1.67"
    Why?

    Best,
    Jacek

  8. #8
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Combobox is changing decimal point from "'," to "."

    Sorry, my mistake, i had wrong code in after change event.
    This code seems to work for me:

    Please Login or Register  to view this content.
    how can i use listobject here?

    Best,
    Jacek

  9. #9
    Valued Forum Contributor Haluk's Avatar
    Join Date
    02-14-2019
    Location
    Turkiye
    MS-Off Ver
    2010 - 64 Bit on Windows-11 (22 H2) 64 Bit
    Posts
    1,150

    Re: Combobox is changing decimal point from "'," to "."

    Do you mean this ?

    Please Login or Register  to view this content.

  10. #10
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Combobox is changing decimal point from "'," to "."

    great thanks!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 5
    Last Post: 02-05-2019, 12:03 AM
  2. Replies: 2
    Last Post: 07-24-2017, 02:19 AM
  3. [SOLVED] Column X-Ref list - Sheet1 Col A "pages", Col B:FL "Req" to Sheet2 ColA "req", ColB "page"
    By excel-card-pulled in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 04-07-2017, 09:30 AM
  4. = EMBED("Forms.ComboBox.1","") error "Reference not valid."
    By CatharinaCatharina in forum Excel General
    Replies: 2
    Last Post: 12-11-2014, 09:58 AM
  5. Replies: 4
    Last Post: 11-17-2013, 12:05 PM
  6. [SOLVED] How to USE """"" cells count """"" change font color
    By austin123456 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-09-2013, 06:14 AM
  7. Changing "returned" values from "0" to "blank"
    By LATATC in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-20-2005, 12:05 PM

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