Thread: SendDlgItemInt

  1. #1
    Registered User
    Join Date
    Apr 2007
    Posts
    162

    SendDlgItemInt

    Hi

    I am currently starting to create a calculator so I am now programming the basic options...

    I ve got problem with SetDlgItemInt function. This function allows me to set only number in size of maximum unsigned long(4 294 967 295) this problem remain even if the variable is declared as double

    Do you have any sollution how to get rid of this problem? Maybe usage of another function?

    Thx

  2. #2
    Hurry Slowly vart's Avatar
    Join Date
    Oct 2006
    Location
    Rishon LeZion, Israel
    Posts
    6,788
    Convert double to text in some way and SetDlgItemText
    All problems in computer science can be solved by another level of indirection,
    except for the problem of too many layers of indirection.
    – David J. Wheeler

  3. #3
    Registered User
    Join Date
    Apr 2007
    Posts
    162
    Quote Originally Posted by vart View Post
    Convert double to text in some way and SetDlgItemText
    Yes I thought of doing that but I dont want to work with text variables and numeric varialbes at one time. It could get too confused and there might appear several errors in future...

    Is there any other way how to solve this without conversion to TCHAR or char?

  4. #4
    Registered User Joelito's Avatar
    Join Date
    Mar 2005
    Location
    Tijuana, BC, México
    Posts
    310
    sprintf doesn't work for you?
    * PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with xfce4.
    * Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with xfce4.

  5. #5
    Registered User
    Join Date
    Apr 2007
    Posts
    162
    Quote Originally Posted by Joelito View Post
    sprintf doesn't work for you?
    Well I can try that... I would rather prefer to use only int variables but if there is no other possibility...

    Still if someone remembers of any way please note me

Popular pages Recent additions subscribe to a feed