|
I am trying to create an Excel file with the XMLTextWriter class. I am successfully able to write the excel file with data from dataset in it. But the problem is that the string data being written in Excel is not visible fully in the cells.
I tried the option of AutoFitWidth="1", But it does not comes into effect for String data. I also got some clue for using System.Drawing.Graphics.MeasureString method. But I am not able to use it in Web project.
Can anyone guide me as to how can I fit the width of the string text in excel cell programatically.
If my mind can conceive it, and my heart can believe it, I know I can achieve it.
|
|
|
|
|
I don't know much about spreadsheetML, but if I recall autofit is a property of the column and not the cell. Are you setting it as a column property?
Sorry, but if that doesn't fix the problem I really don't know what will. I don't normally jump into a topic I don't know that well, but since no one else has answered I thought I'd throw my hat in.
|
|
|
|
|
I've been using XML and schemas for a while now, but have never really read up on it or been shown officially how to use it. Does anyone know of a good book on creating Schemas? Or good concise info on the net about it?
While you're at it, can anyone point me in the direction of how to make up patterns (simple and complicated) in a schema, so that the xml data can be accurately validated against it.
Thanks in advance,
Jugs
|
|
|
|
|
How can I retrieve the data from XML file using SQL query is there any
Data driver like ODBC or other tool , application,….
Please advice
Charbel
|
|
|
|
|
|
HI guys,
I have one query, I have one URL using that URL how can i send XML request and get XML response? is it possible? if it is possible please tell me how? i am so new for this concept so i dont know how work. please help me.. iam working in asp.net with Vb 1.1 so please help me..
Thanking you nad regards,
Praveen Kumar..
Praveen Kumar.R
|
|
|
|
|
|
Hi guys,
I'm using XmlFormView control to display an InfoPath form inside a custom aspx page. In order to load the form I can use XmlLocation which rapresents an Url to the .xml file. Does anyone know if it could be possible to inject Xml from memory (for example from a memory stream) instead of accessing the xml file? In other words I need to have the property XmlFormView.XmlForm setted without setting the XmlLocation property.
Thank you in advance.
Stefano
|
|
|
|
|
Hi
I am doing an application in which I am using a XML file to populate a datagrid.
In that XML file I have one like.....
<>
1.To generate leads efficiently and profitably.
2.To ensure that all details are collected in one call.
3.To provide email and chat support.
4.To manage Work Basket reports as required.
5.To meet targets for both quantity and quality.
<>
When I am trying to populate this column onto datagrid, all these lines or sentences are getting combine and displaying like a paragraph.
I want to know how to format this column to get them in the a new line
Thank u
Chandu
|
|
|
|
|
K V S Chand wrote: populate this column onto datagrid,
What does that mean? Are you using DataBinding?
led mike
|
|
|
|
|
Column means a column in XML.
Yah, I am binding XML data to a DataGrid using dataset.
Thank u
Chandu
|
|
|
|
|
K V S Chand wrote: Column means a column in XML.
There is no such thing as a "column" in XML. If you plan on using text based communications for solving your programming problems don't you think it might be a good idea to learn and use the standard terms for a given technology? Otherwise how do expect to be able to communicate. XML has nodes and elements and attributes, no columns, so I have no idea what you are talking about.
led mike
|
|
|
|
|
i created an xml file using xml serialization for a c# CLASS.
BUT I GOT ALL THE FIELDS FROM THAT CLASS. HOW CAN I REMOVE UN NECESSARY ATTRIBUTES.
CAN ANYBODY HELP ME PLEASE?
KSRS
|
|
|
|
|
First, please don't shout.
Second if it is class that you have created simply apply the [System.Xml.Serialization.XmlIgnoreAttribute] to the properties that you don't want to show.
If it is a framework class, you need to get the data from the XMLSerializer object to an XML document object for manipulation. If this is the case and you have problems with this, please post the specifics.
topcoderjax - Remember, Google is your friend.
|
|
|
|
|
hi iam new to the Xpath
could anyone help me?? i just want to pick up countryname which is element and it has a attribute for the code. i want to pick these values from the XmlDoc
the code here as follows:-
Dim CountryPropExpr As XPath.XPathExpression = Nav.Compile("./CountryName[@Code=""]")
Dim CountryPropIter As XPath.XPathNodeIterator = Nav.Select(CountryPropExpr)
If CountryPropIter IsNot Nothing AndAlso CountryPropIter.Count > 0 Then
Try
Dim CountryNameCode As String = getNodeValue(CountryPropIter.Current.SelectSingleNode("./CountryName[@Code=""]"))
For Each CountryNameCode In CountryPropIter
CountryNameCode = CountryPropIter.Current.Value
Next
Builder.AppendLine("<countryname code="" ""="">")
Catch ex As Exception
Debug.Write(ex.Message)
End Try
End If
when i compile it didn't pickup the values.
Thanks Heaps in Advance
|
|
|
|
|
Please provide a document fragment. Without the XML, there is noway to test the validity of your method call.
"In quiet and silence, the truth is made clear."
|
|
|
|
|
Could someone advise me on the syntax to use to get the IXMLNode whose attribute id="abc" so in the XPath expression used to SelectSinglenode you would specifiy the @id="abc" or whatever the correct syntax is so as to select the Node whose attribute id has the value == "abc".
Thanks.
|
|
|
|
|
Basically, I want to locate and return any Node in the XML document which has an attribute id equal to the id I am searching for.
I have been trying with XPath's such as:
"//*[@id( 'abc' )]"
But alas so far I have not found the correct syntax.
|
|
|
|
|
I managed to get this to work thus:
"//*[@id='" + sURI + "']"
Thanks
|
|
|
|
|
I have a complex XML document and the associated XSD document. But I don't have a XSL document. I want to display the XML in a HTML viewer. Is there any way to create a XSL from the XSD and XML or do you have no option but to create the XSL file to display how you want?
|
|
|
|
|
Andy H wrote: I want to display the XML in a HTML viewer.
What does that mean? If you open an XML file in Firefox or Internet Explorer they will display them for you.
led mike
|
|
|
|
|
In addition to what Mr. led mike said, it may be possible to create XSLT from the XML document's XSD but it won't be worth the effort. To create a HTML document that meet your needs, you must create the XSLT manually or settle with the default XSLT in IE and Firefox.
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|
|
George L. Jackson wrote: or settle with the default XSLT in IE and Firefox.
You can get the XSLT from IE. actually it's in the MSXML3.dll I think.
led mike
|
|
|
|
|
led mike wrote: You can get the XSLT from IE. actually it's in the MSXML3.dll I think.
Well Said led Mike.
Regards,
Satips.
|
|
|
|
|
Thanks Mike! I messed up. It is a resource of MSXML3.DLL and you can view IE's default XSLT via this URN: res://msxml.dll/DEFAULTSS.xsl.
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|