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. Convert From c# - For Report Viewer Report save as PDF format

Convert From c# - For Report Viewer Report save as PDF format

Scheduled Pinned Locked Moved Managed C++/CLI
csharpc++
4 Posts 3 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.
  • P Offline
    P Offline
    Paramu1973
    wrote on last edited by
    #1

    Hi Iam using the below codes to save the report as PDF in c#...Is it possible to convert it in C++/Cli

    Thanks:thumbsup:

    My Codes

    byte[] Bytes = Reportviewer1.LocalReport.Render(format:"PDF",deviceInfo:"");
    using (FileStream stream = new FileStream("C:\MyFolder", FileMode.Create))
    {
    stream.Write(Bytes, 0, Bytes.Length);
    }

    L J 2 Replies Last reply
    0
    • P Paramu1973

      Hi Iam using the below codes to save the report as PDF in c#...Is it possible to convert it in C++/Cli

      Thanks:thumbsup:

      My Codes

      byte[] Bytes = Reportviewer1.LocalReport.Render(format:"PDF",deviceInfo:"");
      using (FileStream stream = new FileStream("C:\MyFolder", FileMode.Create))
      {
      stream.Write(Bytes, 0, Bytes.Length);
      }

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      Paramu1973 wrote:

      Is it possible to convert it in C++/Cli

      No conversion is necessary, as C++/CLI is essentially the same.

      1 Reply Last reply
      0
      • P Paramu1973

        Hi Iam using the below codes to save the report as PDF in c#...Is it possible to convert it in C++/Cli

        Thanks:thumbsup:

        My Codes

        byte[] Bytes = Reportviewer1.LocalReport.Render(format:"PDF",deviceInfo:"");
        using (FileStream stream = new FileStream("C:\MyFolder", FileMode.Create))
        {
        stream.Write(Bytes, 0, Bytes.Length);
        }

        J Offline
        J Offline
        John Schroedl
        wrote on last edited by
        #3

        Yep, conversion should be straightforward. 'using' is unnecessary. 'gcnew' instead of 'new'. :: to scope namespaces and clases instead of '.', etc..

        P 1 Reply Last reply
        0
        • J John Schroedl

          Yep, conversion should be straightforward. 'using' is unnecessary. 'gcnew' instead of 'new'. :: to scope namespaces and clases instead of '.', etc..

          P Offline
          P Offline
          Paramu1973
          wrote on last edited by
          #4

          THANKS:thumbsup:

          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