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
  1. Home
  2. General Programming
  3. C#
  4. HiWord/LoWord/etc in C#

HiWord/LoWord/etc in C#

Scheduled Pinned Locked Moved C#
csharpc++question
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    J Dunlap
    wrote on last edited by
    #1

    What are the C# equivalents of the C/C++ HIWORD/LOWORD/HIBYTE/LOBYTE macros? In VB6 I had to write my own, but surely C# must have them.

    "Do unto others as you would have them do unto you." - Jesus
    "An eye for an eye only makes the whole world blind." - Mahatma Gandhi

    C 1 Reply Last reply
    0
    • J J Dunlap

      What are the C# equivalents of the C/C++ HIWORD/LOWORD/HIBYTE/LOBYTE macros? In VB6 I had to write my own, but surely C# must have them.

      "Do unto others as you would have them do unto you." - Jesus
      "An eye for an eye only makes the whole world blind." - Mahatma Gandhi

      C Offline
      C Offline
      cdehelean
      wrote on last edited by
      #2

      static int HiWord(int Number) { return (Number >> 16) & 0xffff; } static int LoWord(int Number) { return Number & 0xffff; } All I need is a roadmap and then I might be able to find a clue.

      J 1 Reply Last reply
      0
      • C cdehelean

        static int HiWord(int Number) { return (Number >> 16) & 0xffff; } static int LoWord(int Number) { return Number & 0xffff; } All I need is a roadmap and then I might be able to find a clue.

        J Offline
        J Offline
        J Dunlap
        wrote on last edited by
        #3

        Thanks. That's what I ended up doing - just re-writing the C++ macros myself.

        "Do unto others as you would have them do unto you." - Jesus
        "An eye for an eye only makes the whole world blind." - Mahatma Gandhi

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

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