|
AndyInUK wrote: and now i just have to correct the format of the string..
What does that mean?
|
|
|
|
|
basically xml is stored as a string using StringBuilder which ends up with non xml format and hard to read. So one way is that i fix the format manually which is again a pain. So i am asking if there is any second way which can correct the format of the string as xml.
I hope it's clear now.
|
|
|
|
|
So you want pretty XML? Load it into an XmlDocument, then use either WriteTo or WriteContentTo (I forget what the distinction is) to write to an XmlTextWriter. The XmlTextWriter can be configured for indentation. The XmlTextWriter will need to use an underlying stream, just use a MemoryStream for that. You should be able to read the result via a StreamReader.
10110011001111101010101000001000001101001010001010100000100000101000001000111100010110001011001011
|
|
|
|
|
I would take the time to learn about the XmlTextWriter. It made my life so much easier when I had to create an XML file for integration with another system.
Use this to get started ...
Dim writer As New XmlTextWriter(sXMLPath & sXMLName, Nothing)
'Use automatic indentation for readability.
writer.Formatting = Formatting.Indented
'Write the root element
writer.WriteStartElement("REPORT")
writer.WriteStartElement("FORMULA")
writer.WriteElementString("FORMULA_ID", sField0)
writer.WriteElementString("FORMULA_CODE", sField1)
writer.WriteElementString("VERSION", sField2)
writer.WriteElementString("DESCRIPTION", sField3)
writer.WriteEndElement() ' close formula
writer.WriteEndElement() ' close report
'Write the XML to file and close the writer
writer.Close()
|
|
|
|
|
I have a gridview control inside of a panel. The panel has scroll bars set horz and vert. I want all column headings and column text to not word wrap. If I turn off word wrap for column headers and items it still word wraps. How do I get word wrap to work?
|
|
|
|
|
Try putting the grid in a table and applying the style setting:
style='table-layout: fixed;'
10110011001111101010101000001000001101001010001010100000100000101000001000111100010110001011001011
|
|
|
|
|
|
hi friend
i am using chart control of asp.net. it work properly.
i want to save image of chart from page on bottom click? Please help me.
Thanks
Piyush Vardhan Singh
p_vardhan14@rediffmail.com
Eventure Technology
http://holyschoolofvaranasi.blogspot.com
http://holytravelsofvaranasi.blogspot.com
|
|
|
|
|
In my project i need to make a web service that uses massage queuing.
for it i need "web service message queue(wsmq)"
So can any body give me some useful Link about it
Thanks in advance
Raghvendra
|
|
|
|
|
Here[^]
10110011001111101010101000001000001101001010001010100000100000101000001000111100010110001011001011
|
|
|
|
|
hello,
in order to test the stability of my code i tried to crash it and unfortunatly i succeeded.
what i was testing is to see what will happen if i click a 'post button' many times
this page i tested has input arguments along with validation.
is there a solution for this or shall i use the 'ugly way' and disable the button until next postback ?
here's the exception :
Server Error in '/' Application.
--------------------------------------------------------------------------------
Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.]
System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String argument) +159
System.Web.UI.Control.ValidateEvent(String uniqueID, String eventArgument) +108
System.Web.UI.WebControls.DropDownList.LoadPostData(String postDataKey, NameValueCollection postCollection) +55
System.Web.UI.WebControls.DropDownList.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection) +11
System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +353
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1194
.
tnx in advance
avi
|
|
|
|
|
Not a solution for an internet app but you could disable event validation.
...the only way I know is to disable the button.
|
|
|
|
|
yeh... well how can i trap this event ? i want to 'handle' this unhandled exception..
|
|
|
|
|
Or take the 'ryanair' approach - "Clicking this button more than once might result in the purchase of several flights..."
|
|
|
|
|
... or you can say "click only once, its not a shooting range"
|
|
|
|
|
Hai Guys,
In my project need to import contacts from various sites. I need code for importing contacts for hotmail/rediffmail in Asp.net
Can anybody help me out..urgent pls
Thanks
|
|
|
|
|
You may need to access the web services of the various websites to fetch the various contact list.
Either you love IT or leave IT...
|
|
|
|
|
can i have sample code for this please.
|
|
|
|
|
Think youself! Just not difficult. Trust you!
|
|
|
|
|
i have a week number and year
eg: week 34 of 2009
i wanna to know the date of the week
my week day start with Sunday
thanx
|
|
|
|
|
Find either the first Sunday of '09, or the last Sunday of '08 (depending on how you want to count that) and add 34*7 days.
10110011001111101010101000001000001101001010001010100000100000101000001000111100010110001011001011
|
|
|
|
|
In my aplication I've to trace logged in and logged out for an user. I've created a table that contains information about logged in and logged out time of an user. whenever an user logged in i simply add a record in this table and when user logged out i simply update this table. now suppose that when a user close its browser by clicking on cross icon of browser or after a session time out then in this case user logically time out. then in this case how i update table for user logged out?
|
|
|
|
|
Handle the Browser Close using Java script, Open a popup on Browser close and in the code behind, do the server side stuff for update the data and then close the popup.
This will resolve your issue.
|
|
|
|
|
How can I Handle the Browser Close using Java script? plz help me.
|
|
|
|
|
2489128 wrote: How can I Handle the Browser Close using Java script? plz help me.
function DeleteUserLog()
{
if(window.event.clientX < 0 && window.event.clientY <0)
{
window.open("CloseSession.aspx", "OpenWindow_Close_Session",'left=12000,top=1200,width=10,height=1');
}
}
and on CloseSession.aspx page do the staff.
modified on Friday, May 1, 2009 5:42 AM
|
|
|
|