|
by: Tom |
last post by:
I am working with the this object as oppose to the
StreamReader object becuase I need to access a file (to
find the contents) while an external application is
updating the file. When I was working with the
StreamReader object I got a deadlock when I tried reading
the file while my external application was writing to it.
So far I am able to create a FileStream object and open
the file in question (CrawlerBackup.txt).
But I am unable to...
|
by: Kai Bohli |
last post by:
Hi all !
This message has been posted on .net.general, but I reposts it here due to lack of replies.
This is my first day with Visual Studio and C#, and I'm trying to send "raw data" to the printer
port. I found the SendFileToPrinter example below in a knowledge base at MS site
It works, but I need to replace the filestream with a memorystream cause there's no need to write
files and then load them again just to print.
So I rewrote...
|
by: Donovan |
last post by:
I can't believe this is causing me as much difficulty as it is, but I have
an Infragistics UltraTreeview control that I want to persist whatever the
user has in the tree. It has a method SaveAsXml which puts the contents into
a MemoryStream, which I convert to a string for persistance (I know
Infragistics allows me to, but I can't store as a file for various reasons,
so it's not a valid alternative). I'm using this code to put into a string...
|
by: sbparsons |
last post by:
I have a file opened as a FileStream.
I have a StreamReader and StreamWriter object opened, referencing the
FileStream object.
My aim is to read lines from the file until I find the line where there is a
unique comment as a place holder.
I would then like to use the StreamWriter to insert lines after this comment
and save the file.
How do I instruct the StreamWriter to find the line position based on the
|
by: T. Davis |
last post by:
In C#, I am able to successfully stream a TIFF image that comes from a
BLOB field in a database, save it to file, then convert the pages
within TIFF file into jpegs (using GDI+) and display on the web (using
ASP.NET).
However, when I generate the Image object using FromStream (passing in
the MemoryStream containing image bytes), an exception of "A generic
error occurred in GDI+" is thrown when performing the conversion/save
for display....
|
|
by: SQLScott |
last post by:
For some reason I am drawing a blank on this, so I would be extremely
greatful if someone could help me out.
I am trying to get a MemoryStream out of a Byte array. How do I get it back
out?
I have a sub that calls a function:
Dim bByte() As Byte
bByte = ws.SQLGetUserDemographics()
|
by: Terry |
last post by:
In the code below, I open a file using filestream, copy it to a byte
array, and the write that array out to a new file. But when I check
the size of the original file and the new file, the new file has one
less byte than the original file (although the file itself still works
fine). I was hoping someone could explain what is going on (why is
there a byte missing, and what might that byte be).
string originalFile =...
|
by: foreman |
last post by:
Hi there,
Hello everybody. I am a newbie to dot net framework class lib. I
am confused about those classes such as all of the stream classes and
those XXXReader XXXWriter. In fact, I have tried the StreamReader(which
can read in big5 encoding text files well) and besides, I have tried
the BufferedStream to do the same thing. It does work fine except that
It can't interpret the Chinese big5 words well(which becomes messy code
around)....
|
by: Heron |
last post by:
Hi,
Could someone explain me why the following code doesn't work? The
memorystream always remains with length 0.
MemoryStream input = new MemoryStream();
|
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 usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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 synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
|
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.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
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 most users, this new feature is actually very convenient. If you want to control the update process,...
|
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 choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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 into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|