Code Red > .NET
Some Code Snippety goodness
Glenn R:
Have at it lads and lasses :-D
Bryco:
I use this one a bit
--- Code: ---<?xml version="1.0" encoding="utf-8"?>
<CodeSnippets
xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
<CodeSnippet Format="1.0.0">
<Header>
<Title>
isZero
</Title>
</Header>
<Snippet>
<Declarations>
<Literal>
<ID>dNum</ID>
<ToolTip>Check if number is close enough to zero.</ToolTip>
<Default>1.0</Default>
</Literal>
<Literal Editable="false">
<ID>MathClass</ID>
<Function>SimpleTypeName(System.Math)</Function>
</Literal>
</Declarations>
<Code Language="CSharp">
<![CDATA[if ($MathClass$.Abs($dNum$ )<1.0e-8){$dNum$=0;}]]>
</Code>
</Snippet>
</CodeSnippet>
</CodeSnippets>
--- End code ---
I guess all I needed to post was
<![CDATA[if ($MathClass$.Abs($dNum$ )<1.0e-8){$dNum$=0;}]]>
Glenn R:
How's the C# coming along Bryce?
Glenn R:
Or was it VB.net...?
Kerry:
--- Quote from: Glenn R on October 15, 2007, 11:53:47 PM ---Or was it VB.net...?
--- End quote ---
--- Quote from: Bryco on October 15, 2007, 11:36:40 PM ---I use this one a bit
........... I guess all I needed to post was
<![CDATA[if ($MathClass$.Abs($dNum$ )<1.0e-8) { $dNum$=0 ;} ]]>
--- End quote ---
correct the first time I'd guess :-)
Navigation
[0] Message Index
[#] Next page
Go to full version