Click here to Skip to main content
15,900,477 members
Home / Discussions / C#
   

C#

 
GeneralRe: How To Create A Shortcut (.lnk) in Code Pin
exhaulted23-Feb-05 20:58
exhaulted23-Feb-05 20:58 
GeneralAutoComplete in .net 2.0 Pin
djkno322-Feb-05 4:18
djkno322-Feb-05 4:18 
GeneralRe: AutoComplete in .net 2.0 Pin
djkno320-Apr-05 2:18
djkno320-Apr-05 2:18 
Generalblackberry Pin
2new22-Feb-05 3:56
2new22-Feb-05 3:56 
GeneralRe: blackberry Pin
Heath Stewart22-Feb-05 12:05
protectorHeath Stewart22-Feb-05 12:05 
GeneralRe: blackberry Pin
2new24-Feb-05 9:00
2new24-Feb-05 9:00 
QuestionHow to make TreeView like navigation bar Pin
lee meng22-Feb-05 2:58
lee meng22-Feb-05 2:58 
Generalformatting number Pin
dhol22-Feb-05 1:56
dhol22-Feb-05 1:56 
Hi
I have doone a program such that using xpath , to read data's from xml and display it on a form.

now for ex:

XPathExpression Expr2;
Expr2 = oXPathNav.Compile("/tmp_day_stats//td_value");

XmlNamespaceManager oxmlNSManager = new XmlNamespaceManager(oXPathNav.NameTable);
oxmlNSManager.AddNamespace("tmp_day_stats", "http://myserver/myschemas/tmp_day_stats");


Expr2.SetContext(oxmlNSManager);


XPathNodeIterator iterator2 = oXPathNav.Select(Expr2);
while (iterator2.MoveNext())
{
this.textBox2.Text.ToString += this.textBox2.Text == "" ? iterator2.Current.Value: "\r\n"+ iterator2.Current.Value;
}

the above program what it does uis that read all the values of td_value from the xml file and display them in the textbox2.

ie, the output is as follows

900909.87887
980126.767
353553.543
776668.6466

now i have to format these numbers as follows

900909.87
980126.76
353553.54
776668.64

ie, after decimal i should have only 2 values to be shown.
how to format it . please help me to get this..


santhosh


GeneralRe: formatting number Pin
leppie22-Feb-05 5:38
leppie22-Feb-05 5:38 
GeneralRe: formatting number Pin
dhol22-Feb-05 16:38
dhol22-Feb-05 16:38 
GeneralGetting the path of an open Word document Pin
Paladin5522-Feb-05 1:41
Paladin5522-Feb-05 1:41 
GeneralRe: Getting the path of an open Word document Pin
Heath Stewart22-Feb-05 12:30
protectorHeath Stewart22-Feb-05 12:30 
GeneralWeb method's parameter Pin
Ed Lee22-Feb-05 1:05
Ed Lee22-Feb-05 1:05 
GeneralRe: Web method's parameter Pin
J4amieC22-Feb-05 1:43
J4amieC22-Feb-05 1:43 
GeneralRe: Web method's parameter Pin
Anonymous22-Feb-05 13:55
Anonymous22-Feb-05 13:55 
GeneralRe: Web method's parameter Pin
J4amieC22-Feb-05 23:30
J4amieC22-Feb-05 23:30 
GeneralUTF8 Encoding - need help or explanation Pin
Radoslav Bielik21-Feb-05 23:56
Radoslav Bielik21-Feb-05 23:56 
GeneralRe: UTF8 Encoding - need help or explanation Pin
Mike Dimmick22-Feb-05 2:21
Mike Dimmick22-Feb-05 2:21 
GeneralRe: UTF8 Encoding - need help or explanation Pin
Radoslav Bielik22-Feb-05 5:08
Radoslav Bielik22-Feb-05 5:08 
GeneralMouse position Pin
The underdog21-Feb-05 23:08
The underdog21-Feb-05 23:08 
GeneralRe: Mouse position Pin
Stefan Troschuetz22-Feb-05 1:45
Stefan Troschuetz22-Feb-05 1:45 
GeneralSending SMS Pin
innocent7321-Feb-05 22:50
innocent7321-Feb-05 22:50 
GeneralSpecialised task manager Pin
clatten21-Feb-05 21:39
clatten21-Feb-05 21:39 
GeneralRe: Specialised task manager Pin
Heath Stewart22-Feb-05 8:22
protectorHeath Stewart22-Feb-05 8:22 
GeneralRe: Specialised task manager Pin
clatten22-Feb-05 12:45
clatten22-Feb-05 12:45 

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.