Click here to Skip to main content
15,890,410 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: show decimal value in percentage in a data grid Pin
pmarfleet30-Nov-07 6:07
pmarfleet30-Nov-07 6:07 
QuestionError UserControl Pin
AnhTin30-Nov-07 3:59
AnhTin30-Nov-07 3:59 
QuestionIs possible that datasource support server side pagging with datareader Pin
puspendra napit30-Nov-07 3:38
puspendra napit30-Nov-07 3:38 
QuestionCurrency Column in Report Problem Pin
macca2430-Nov-07 3:34
macca2430-Nov-07 3:34 
AnswerRe: Currency Column in Report Problem Pin
pmarfleet30-Nov-07 4:48
pmarfleet30-Nov-07 4:48 
QuestionError Message when paging in Datgrid Pin
macca2430-Nov-07 3:33
macca2430-Nov-07 3:33 
AnswerRe: Error Message when paging in Datgrid Pin
Jyoti MCAD1-Dec-07 9:56
Jyoti MCAD1-Dec-07 9:56 
QuestionHtmlTextWriter change settings before sending out Pin
Leo Smith30-Nov-07 2:29
Leo Smith30-Nov-07 2:29 
Yesterday I asked a question on how to retrieve a string of the raw html. Now the problem is that I have changed the data to byte[] and need to write it back to the HtmlTextWriter. The following is a code snippet if I am sending it to a Response value and not a text writer.

<code>
byte[] binBytes = null;
StringWriter str = new StringWriter();
HtmlTextWriter html = new HtmlTextWriter(str);
base.Render(html);

string s = str.ToString();
binBytes = binConverter.ConvertString(s);

System.Web.HttpResponse response = System.Web.HttpContext.Current.Response;
response.Clear();

Response.AddHeader("Content-Type", "binary/octet-stream");
Response.AddHeader("Content-Disposition",
"inline; filename=ConversionResult.bin; size=" + binBytes.Length.ToString());
Response.Flush();
Response.BinaryWrite(binBytes);
Response.Flush();
Response.End();

writer.Write(s); // Writer is the original HtmlTextWriter passed to the Render function
</code>

This snippet creates will creates a second window without and leaves the original window blank. I want to do away with the second window and have it create the modified text in the original window. So the question is how can I change the reply header information from the original encoding format and assign it to a new format (text to binary)?

Thanks,
Leo



Leo T. Smith

Questionhow to check valid sessionID ? Pin
codeproject_buna30-Nov-07 2:22
codeproject_buna30-Nov-07 2:22 
AnswerRe: how to check valid sessionID ? Pin
Frank Kerrigan30-Nov-07 2:46
Frank Kerrigan30-Nov-07 2:46 
QuestionEdit a record in Grid View Pin
.NET- India 30-Nov-07 2:07
.NET- India 30-Nov-07 2:07 
AnswerRe: Edit a record in Grid View Pin
Frank Kerrigan30-Nov-07 2:56
Frank Kerrigan30-Nov-07 2:56 
QuestionCREATE DATABASE permission denied in database 'master'. Pin
Affan Toor30-Nov-07 1:16
Affan Toor30-Nov-07 1:16 
AnswerRe: CREATE DATABASE permission denied in database 'master'. Pin
Vasudevan Deepak Kumar30-Nov-07 1:45
Vasudevan Deepak Kumar30-Nov-07 1:45 
QuestionVersioning for WebServices Pin
kalaiV30-Nov-07 1:07
kalaiV30-Nov-07 1:07 
AnswerRe: Versioning for WebServices Pin
Vasudevan Deepak Kumar30-Nov-07 1:46
Vasudevan Deepak Kumar30-Nov-07 1:46 
GeneralRe: Versioning for WebServices Pin
kalaiV30-Nov-07 2:00
kalaiV30-Nov-07 2:00 
QuestionsessionID availability check in a page Pin
codeproject_buna30-Nov-07 1:03
codeproject_buna30-Nov-07 1:03 
AnswerRe: sessionID availability check in a page Pin
Frank Kerrigan30-Nov-07 2:49
Frank Kerrigan30-Nov-07 2:49 
QuestionFacing problem related to assambly in resources Pin
Amit Sk Sharma30-Nov-07 0:00
Amit Sk Sharma30-Nov-07 0:00 
QuestionCreating Website in SharePoint using C#/ASP.NET Pin
md Nazeem29-Nov-07 23:37
md Nazeem29-Nov-07 23:37 
AnswerRe: Creating Website in SharePoint using C#/ASP.NET Pin
Frank Kerrigan30-Nov-07 3:04
Frank Kerrigan30-Nov-07 3:04 
Questioncreating html control trough sql query Pin
MaruBindiya29-Nov-07 22:24
MaruBindiya29-Nov-07 22:24 
AnswerRe: creating html control trough sql query Pin
Christian Graus29-Nov-07 23:04
protectorChristian Graus29-Nov-07 23:04 
GeneralRe: creating html control trough sql query Pin
MaruBindiya29-Nov-07 23:18
MaruBindiya29-Nov-07 23:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.