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. Web Development
  3. How to generate a file from base64 binary stream tusing java script

How to generate a file from base64 binary stream tusing java script

Scheduled Pinned Locked Moved Web Development
javadatabasetoolstutorial
2 Posts 2 Posters 5 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
    Gokul_md
    wrote on last edited by
    #1

    Hi I have converted the whole file content to base64 binary stream using the below java script code. After converting I persisted into the database column. fileNode.dataType = "bin.base64"; // open stream object and read source file var adoStream = new ActiveXObject("ADODB.Stream"); if (adoStream.State != 1) { adoStream.Type = 1; // 1=adTypeBinary adoStream.Open(); adoStream.LoadFromFile(strFileName); } I can also retrieve the same base64 content to client side. Now I want to generate the same file using the base64 content. Can anyone tell me now how to convert the base64 to original file format using java script.

    M 1 Reply Last reply
    0
    • G Gokul_md

      Hi I have converted the whole file content to base64 binary stream using the below java script code. After converting I persisted into the database column. fileNode.dataType = "bin.base64"; // open stream object and read source file var adoStream = new ActiveXObject("ADODB.Stream"); if (adoStream.State != 1) { adoStream.Type = 1; // 1=adTypeBinary adoStream.Open(); adoStream.LoadFromFile(strFileName); } I can also retrieve the same base64 content to client side. Now I want to generate the same file using the base64 content. Can anyone tell me now how to convert the base64 to original file format using java script.

      M Offline
      M Offline
      Martin Jarvis
      wrote on last edited by
      #2

      Presumably you can start with something like this[^]? If not then I think we'll need more information.


      Freestyle Interactive Ltd | Martin on .Net

      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