<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: number to string in VBA Forum</title>
    <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728292#M32028</link>
    <description>StringVal = str(0.062*1000)</description>
    <pubDate>Mon, 07 Aug 2006 19:20:00 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2006-08-07T19:20:00Z</dc:date>
    <item>
      <title>number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728291#M32027</link>
      <description>Im trying to grab certain decimal places of a double and put them into a string. &lt;BR /&gt;
I want to convert 0.315  to 315 as a string, likewise .062 will be 062 and .25, 250, etc. &lt;BR /&gt;
Any idea how this can be done?</description>
      <pubDate>Mon, 07 Aug 2006 19:12:31 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728291#M32027</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T19:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728292#M32028</link>
      <description>StringVal = str(0.062*1000)</description>
      <pubDate>Mon, 07 Aug 2006 19:20:00 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728292#M32028</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T19:20:00Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728293#M32029</link>
      <description>that works except for the case when the number is less than .1.  for example as i said if the number was .062 i would need the string to be 062 not 62, not sure how much that would change this.</description>
      <pubDate>Mon, 07 Aug 2006 19:32:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728293#M32029</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T19:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728294#M32030</link>
      <description>How about this?&lt;BR /&gt;
&lt;BR /&gt;
StringVal = Format((str(0.062 * 1000)), "000")</description>
      <pubDate>Mon, 07 Aug 2006 19:45:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728294#M32030</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T19:45:01Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728295#M32031</link>
      <description>Give this a try&lt;BR /&gt;
Sub GrabDecimalOnly()&lt;BR /&gt;
Dim dblNum As Double&lt;BR /&gt;
Dim decStr As String&lt;BR /&gt;
dblNum = 0.062&lt;BR /&gt;
decStr = Mid(CStr(dblNum), 3, 4)&lt;BR /&gt;
MsgBox decStr&lt;BR /&gt;
End Sub&lt;BR /&gt;
&lt;BR /&gt;
Fatty&lt;BR /&gt;
&lt;BR /&gt;
~'J'~

Message was edited by: Fatty</description>
      <pubDate>Mon, 07 Aug 2006 19:50:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728295#M32031</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T19:50:27Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728296#M32032</link>
      <description>Hi,&lt;BR /&gt;
&lt;BR /&gt;
Try this:&lt;BR /&gt;
   x = your numeric value&lt;BR /&gt;
  If Instr CStr(x),".") &amp;gt; 0 then&lt;BR /&gt;
      MsgBox Left$(Split(CStr(x), ".")(1) &amp;amp; "000", 3)&lt;BR /&gt;
 Else&lt;BR /&gt;
      MsgBox  "000"&lt;BR /&gt;
End If&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
&lt;BR /&gt;
Laurie Comerford&lt;BR /&gt;
CADApps&lt;BR /&gt;
www.cadapps.com.au&lt;BR /&gt;
&lt;SRYABININ&gt; wrote in message news:5261068@discussion.autodesk.com...&lt;BR /&gt;
Im trying to grab certain decimal places of a double and put them into a &lt;BR /&gt;
string.&lt;BR /&gt;
I want to convert 0.315  to 315 as a string, likewise .062 will be 062 and &lt;BR /&gt;
.25, 250, etc.&lt;BR /&gt;
Any idea how this can be done?&lt;/SRYABININ&gt;</description>
      <pubDate>Mon, 07 Aug 2006 20:57:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728296#M32032</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T20:57:30Z</dc:date>
    </item>
    <item>
      <title>Re: number to string</title>
      <link>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728297#M32033</link>
      <description>all the different variations seem to do the trick, thanks guys</description>
      <pubDate>Mon, 07 Aug 2006 23:49:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vba-forum/number-to-string/m-p/1728297#M32033</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-08-07T23:49:37Z</dc:date>
    </item>
  </channel>
</rss>

