Questions tagged [stringwriter]

StringWriter class could refer to java.io.StringWriter (part of the the standard java io library ) or to System.IO.StringWriter (part of .NET framework)

StringWriter class could refer to java.io.StringWriter (part of the the standard java io library ) or to System.IO.StringWriter (part of .NET framework)

76 questions
1
vote
2 answers

Get parts of a string - C# .NET Core 3.1

I have a string line from a log: 2020-09-07 14:41:17.268 +01:00 [Information] Hello, Serilog! I would like to pull out the word Information from the string, however, this will change as it could be debug, or any other known logging level. I would…
user1574598
  • 3,771
  • 7
  • 44
  • 67
1
vote
2 answers

Pulling XML child inner node from XML to Java Object using JAXB

I have been trying to pull a child node from an XML which I received from a SOAP as string. I can retrieve the parent node but couldn't retrieve the child node. I also surf the internet to see if I can get an answer but all to no avail. I saw some…
Prodigy
  • 2,094
  • 24
  • 30
1
vote
2 answers

Is there anything (any way) to concatenate java Strings faster than StringWriter?

I am pulling a bunch of simple data and constructing a big (1kB - 2kB) String. I'm new to this language, but after reading, this seems likely the fastest (i.e. least amount of copying): String tmpTable = "" +…
Erik Bennett
  • 1,049
  • 6
  • 15
1
vote
1 answer

Variable Preventing More Text Being Appended To String?

I am so lost at the moment as to why I cannot get something so simple to work! I am decrypting a value & appending it to a string, E.g. MessageBox.Show("TEST 1: " & DecryptedValue & " WHY AM I BEING STRIPPED???") The problem is, anything after the…
Chris
  • 512
  • 1
  • 16
  • 33
1
vote
2 answers

Write chinese characters from one file to another

I have a file with Chinese characters text inside, I want to copy those text over to another file. But the file output messes with the chinese characters. Notice that in my code I am using "UTF8" as my encoding already: BufferedReader br = new…
ianrey palo
  • 61
  • 1
  • 10
1
vote
1 answer

asp telerik treeView throws an exception when trying to renderControl

I am working on a TreeView and have to execute the renderControl() method. When it fires, it gives an exception: InvalidOperationException: Page cannot be null. Please ensure that this operation is being performed in the context of an ASP.NET…
Fallenreaper
  • 10,222
  • 12
  • 66
  • 129
1
vote
3 answers

Android Out of Memory Error: How to solve this?

I have an application, and I am trying to set up a fairly large SQLite database (one table with roughly 5000 rows) into it. I have built the DB classes and everything, and my app works when I tested on a smaller scale (400 rows), but now when I want…
Qasim
  • 1,686
  • 4
  • 27
  • 51
0
votes
4 answers

How to write some text to an excel file in c#

I am adding the grid table to the excel and adding a header to the excel. string subject = lbl_Subj.Text; Response.Clear(); Response.Buffer = true; Response.ClearHeaders(); Response.AddHeader("Cache-Control", "no-store,…
Mark
  • 2,720
  • 15
  • 56
  • 87
0
votes
2 answers

Fetch Millions of Records using CopyManager throwing OutOfMemoryError

When I tried running my code in tables with rows in thousands, it worked fine but as a performance testing, I tried it with tables having millions of records and then I encountered this issue. I have tried the above approach. I can try an alternate…
0
votes
1 answer

C# 10 (De)Serialize XML property value AND attributes using StringWriter, StringReader and XmlSerializer

How do I (de)serialize the following xml element: Hello World!!!\n I define the following class to take care of the attributes: [Serializable] public class OtherInfo { …
Kok How Teh
  • 3,298
  • 6
  • 47
  • 85
0
votes
1 answer

Writing RestAssured logs to StringWriter always seems to cut the last lines of the result

I am running RestAssured tests and I wanted to read info about the request from the logs ( to use in reports). I have a superclass with the following code which the test classes extent. The superclass: import java.io.PrintStream; import…
0
votes
1 answer

How to remove first two columns and hyperlinks from repeater exported excel

I am exporting data to excel from repeater control, which contains some hyperlinks in multiple columns and link buttons in first two columns. I want to remove all hyperlinks as well as remove or hide first two columns, when I export the data to…
shekhar
  • 13
  • 6
0
votes
0 answers

Changing values in XML when looping not saving the new values on next loop

Hey all I am having an issue with the code below due to me not being able to grasp what I am missing. I know the issue is that every call to searchXML() it just reads the original file that does not have the edits in it. But I am at a loss as to how…
StealthRT
  • 10,108
  • 40
  • 183
  • 342
0
votes
0 answers

how to send multiple emails at one session using JAVA

i have a XML, where with that XML i mocked up test data by passing it in excel, i stuck up in getting the multiple mocked up string formatted files to send it to queue as a string. this is my string formatted mocked up file stored in…
0
votes
2 answers

StringWriter processes strange characters on csv generated

I'm having troubles using StringWriter on our application. I do a rest call over a nosql db and it returns a list of dynamics. I use StringWriter to write a csv file that contains a header and records from my list. I also tried to extend the…