473,570 Members | 2,811 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Handling Binary Stream In Java Script

2 New Member
HI All,

Could you please Help me to Handle Binary Stream Object in Java Script.
Sep 11 '07 #1
5 3842
5,390 Recognized Expert Moderator Expert
hi ...

welcome to TSDN ...

please make it more clear ... what do you have so far and what do you want to achieve? do you have any code to post here?

kind regards
Sep 11 '07 #2
2 New Member
hi ...

welcome to TSDN ...

please make it more clear ... what do you have so far and what do you want to achieve? do you have any code to post here?

kind regards


I am trying to get image as binary stream from database. I want to handle the same in Java script to display as Graph in my UI.

Could you please help me out in the same

Kind regards,
Sep 11 '07 #3
2,476 Top Contributor

I am trying to get image as binary stream from database. I want to handle the same in Java script to display as Graph in my UI.

Could you please help me out in the same

Kind regards,
File I/O is not possible with Standard JavaScript.

Kind regards,
Sep 11 '07 #4
5,390 Recognized Expert Moderator Expert
hi ...

sorry ... but i don't know whether this might be possible ... javascript cannot handle this as far as i know ... may be there are activex-controls for IE out there ... but that would be proprietary for IE only. javascript is able to manipulate the dom of a document, you may do a lot of validation-logik or some dhtml-things etc. but it has no file-, stream-reading abilities ...

of course you may set img-sources dynamically ... but the images has to be provided as ready sources ... so you may do something like:

Expand|Select|Wrap|Line Numbers
  1. img_node_ref.src = 'new_image_src.jpg';
perhaps you may control plugins that handle streams, but js itself cannot do that ...

kind regards
Sep 11 '07 #5
16,027 Recognized Expert Moderator MVP

I am trying to get image as binary stream from database. I want to handle the same in Java script to display as Graph in my UI.
If you're getting the image from a database, you're using a server-side scripting language. Just use that to create the image on the server-side all ready for use on the client-side.
Sep 11 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

by: Russ Reynolds | last post by:
Problem: I'm writing a client app. that needs to download an image file (non-text) from a remote location and save to the client machine. Here is what I have so far (pseudocode): import java.io.* import java.net.*; //create the socket to the server Socket client = new Socket(host,port);
by: Matthias Czapla | last post by:
Hi! Whats the canonical way for handling raw data. I want to read a file without making any assumption about its structure and store portions of it in memory and compare ranges with constant byte sequences. _I_ would read it into arrays of unsigned char and use C's memcmp(), but as you see Im a novice C++ programmer and think that theres...
by: Steven T. Hatton | last post by:
§ Type ios_base::openmode Says this about the std::ios::binary openmode flag: *binary*: perform input and output in binary mode (as opposed to text mode) And that is basically _all_ it says about it. What the heck does the binary flag mean? -- If our hypothesis is about anything and not about some one or more particular things,...
by: Lisa Pearlson | last post by:
Hi, My php application (on Apache/Linux) needs to do the following: The PHP script receives a request from a client (binary), asking for certain records of data. My PHP script loops through all records and sends each of them ONE BY ONE. After each record that my server script sends, it waits for the client to confirm proper reception...
by: Gladiator | last post by:
When I am trying to execute a program from "The C Programming Language" by Dennis Ritchie, I tried to run the following program.I am using Dev++ as a compiler software. The Program is presented below. #include <stdio.h> main() { long nc;
by: AirYT | last post by:
Hello, Here's a quick explanation & problem: i have an ASP (iis v5.0) application that generates a pdf file and this file is saved to the server. it is saved in a location not available to web users. i have an asp script (below) that sends the pdf file to the user as a binary stream. So that the user specifies which file to upload, the...
by: Pedro Leite | last post by:
Good Afternoon. the code below is properly retreiving binary data from a database and saving it. but instead of saving at client machine is saving at the server machine. what is wrong with my code ?? thank you Pedro Leite From Portugal ------------------------------------
by: tomPee | last post by:
Hi, I've bumbed into a slight problem now, and I just don't seem to know how to fix it. What I want to do is the following: Send over a socket: 1. Number of files to be send (not as an integer, just as a string) then for each file to be send: 2. Length of Filename (again as a string) 3. Filename 4. File as binary data.
by: kboyd | last post by:
Dear all, I'm new to the forum, I'm really sorry if this has appeared elsewhere. I'm not really a programmer and am having major difficulties handling a binary stream which I am trying to read and process in vb.net. The stream is coming in from an FTDI chip and should contain 64 8-bit values. An example of the stream is here...
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.