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. Managed C++/CLI
  4. named pipe: how to write array of struct

named pipe: how to write array of struct

Scheduled Pinned Locked Moved Managed C++/CLI
data-structureshelptutorialquestion
4 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.
  • G Offline
    G Offline
    ginjikun
    wrote on last edited by
    #1

    hi... this is my first post here. can someone provide me with a sample of how to write an array of struct via named pipe? i am new to named pipe. i have tried writing using the message type mode... however i have not tried using byte mode. moreover, i have an array of struct to write. thanks in advance for any help! newbie :)

    M 2 Replies Last reply
    0
    • G ginjikun

      hi... this is my first post here. can someone provide me with a sample of how to write an array of struct via named pipe? i am new to named pipe. i have tried writing using the message type mode... however i have not tried using byte mode. moreover, i have an array of struct to write. thanks in advance for any help! newbie :)

      M Offline
      M Offline
      Mark Salsbery
      wrote on last edited by
      #2

      This question should be posted on the Visual C++/MFC board since it doesn't seem to involve managed C++. In byte mode you need a pointer to the first struct you want to write. The number of bytes to write is the sizeof the struct times the number of structs to write. Which part is giving you trouble? Mark

      "If you can dodge a wrench, you can dodge a ball."

      1 Reply Last reply
      0
      • G ginjikun

        hi... this is my first post here. can someone provide me with a sample of how to write an array of struct via named pipe? i am new to named pipe. i have tried writing using the message type mode... however i have not tried using byte mode. moreover, i have an array of struct to write. thanks in advance for any help! newbie :)

        M Offline
        M Offline
        Mark Salsbery
        wrote on last edited by
        #3

        Definitely a first post worthy of a 5 vote! :)

        "If you can dodge a wrench, you can dodge a ball."

        G 1 Reply Last reply
        0
        • M Mark Salsbery

          Definitely a first post worthy of a 5 vote! :)

          "If you can dodge a wrench, you can dodge a ball."

          G Offline
          G Offline
          ginjikun
          wrote on last edited by
          #4

          hi Mark... thanks and sorry for the wrong post... can i just continue the thread here and not repost in vc++? :) i have done a sample app of writing structs via named pipe... my trouble now is how to properly manage/convert the array of structs to LPVOID which is what i am passing to the named pipe functions (readfile/writefile)... and from LPVOID back to array of structs. or should i use a different data type and not lpvoid? thanks again! newbie :)

          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