Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
B

Bosse62

@Bosse62
About
Posts
5
Topics
0
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • How to seamlessly share code in Visual Studio?
    B Bosse62

    Using GitHub when you are the only one changing the code, you don't need to do forks or pulls. Check in everything (code working/compiling or not doesn't matter) from your work computer. Check it out when you come home to your home computer, and you're back where you left off. Before you go to sleep, check in everything (working or not), and the next morning at work, you're back where you left off. Maybe I misunderstood this completely since I don't understand why you are mentioning "Microsoft Account" ? Use your own account! What has "account" to do with your GitHub space. Please don't tell me you're using Visual Studio's GitHub implementataion. It sux!!

    Windows Development csharp visual-studio hosting cloud tutorial

  • Converting string into non-string Form.Object types for passing to methods or updating non-string object.Property with strings
    B Bosse62

    Your BUTTON_LIST_str array contains the class System.String Your APPLY_BUTTON_CFG method needs the class System.Windows.Forms.Button as the parameter Theres is no way to convert a string to a button.

    C# help question csharp graphics data-structures

  • I need to convert a string to a float....
    B Bosse62

    Is there a problem with the decimal sign; period or comma?

    C# visual-studio data-structures question

  • Should 0.5 round up or down?
    B Bosse62

    I learned in school: "When you have a 5 to round from; the number to round to shall be even." Let me give you some examples: Rounding to no decimals: 0.5 --> 0 1.5 --> 2 2.5 --> 2 3.5 --> 4 Rounding to one decimal: 0.35 --> 0.4 0.45 --> 0.4 0.55 --> 0.6 0.65 --> 0.6

    C# question

  • IParsable? IFormattable? ICustomFormatter? IFormatProvider? TryParse! ToString!
    B Bosse62

    I would use switch statements, multiple switch statements inside switch statements! Sounds complicated? Bare with me. Start with a a TryParse to find out if your input contains numbers-only or not. (not digits-only) You might need to handle different decimal signs, period or comma. Now you can call two different switches: Inside the numbers-only switch there probably wouldn't be many 'case' statements. Use TryParse or ConvertTo to get a Double. Examine the value you got so it is within reason. Convert the Double to a suitable integer or keep it as is depending on what you need. Inside the digits+char switch you may use String.Contains('some char') to branch out one of these: 1) More switches depending on what character was found - Maybe branch even further depending on what position the character was found... (maybe not, but you get what I'm saying?) 2) Different methods (with good names explaining what they do) Inside some of these methods it might be useful to use even more switches for readability purposes. Then you start using TryParse/ConvertTo as I descibed above. What I'm saying is: One step at a time, Keep It Simple, and branch out to more specifics on the way. Using Interfaces or RegEx or whatever to "parse" your data in "one" line... and you will end up in some completely unreadable and non-maintainable code. Best regards The K.I.S.-guy

    C# csharp c++ question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups