<?xml version="1.0" encoding="iso-8859-1" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="http://syndication.webwiz.co.uk/rss_namespace/">
 <channel>
  <title>Forum IALweb : [Risolto] arrotondamento</title>
  <link>http://www.ialweb.it/forum/</link>
  <description>This is an XML content feed of; Forum IALweb : Microsoft Access : [Risolto] arrotondamento</description>
  <copyright>Copyright (c) 2006-2012 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 22 May 2013 13:26:06 +0000</pubDate>
  <lastBuildDate>Sat, 28 Apr 2012 11:52:14 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 10.11</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>www.ialweb.it/forum/RSS_post_feed.asp?TID=16463620</WebWizForums:feedURL>
  <image>
   <title>Forum IALweb</title>
   <url>http://www.ialweb.it/forum/forum_images/web_wiz_forums.png</url>
   <link>http://www.ialweb.it/forum/</link>
  </image>
  <item>
   <title>[Risolto] arrotondamento : le soluzioni sono state oggetto...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361323&amp;title=risolto-arrotondamento#3361323</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=18938">imperiali</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 11:52<br /><br />le soluzioni sono state oggetto di partenza per risolvere il problema che e' si quello di portare il nomero 2,3 a 3 ma e' anche quello di lasciare inalterato il numero 2,2 <br>dopo varie peripezie e con l'aiuto di un collega e' stata realizzata questa soluzione:<br><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Quote" alt="Quote" style="vertical-align: text-bottom;" /> <br>Public Function IP_to_OUT(IP As Single) As Integer<br>&nbsp; Dim intermedio As Integer<br>&nbsp; intermedio = Int(IP) * 3 + (IP * 10) Mod 10<br>&nbsp; IP_to_OUT = intermedio<br>End Function<br><br>Public Function OUT_to_IP2(Out As Integer) As String<br>&nbsp; OUT_to_IP2 = Int(Out / 3) &amp; "." &amp; Out Mod 3<br>End Function<br><br>Public Function IP2_to_OUT(Ip2 As String) As Integer<br>&nbsp; IP2_to_OUT = CInt(Left(Ip2, Len(Ip2) - 2)) * 3 + CInt(Right(Ip2, 1))<br>End Function<br></td></tr></table><br>lo ho lasciato come e' potrebbe servire per qualche spunto<br>poi nella query ho creato un campo con la seguente origine dati<br><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Quote" alt="Quote" style="vertical-align: text-bottom;" /> <br>=out_to_ip2(Somma(ip_to_out(&#091;IP&#093;)))<br></td></tr></table><br>non so se e' ok ma il risultato soddisfa le mie esigenze<br>grazie ancora<br>Maurizio<br>]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 11:52:14 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361323&amp;title=risolto-arrotondamento#3361323</guid>
  </item> 
  <item>
   <title>[Risolto] arrotondamento : Diciamo rendere &amp;#034;edotto&amp;#034;...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361322&amp;title=risolto-arrotondamento#3361322</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=19734">@Alex</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 11:43<br /><br />Diciamo rendere "<font color="#FF0000">edotto</font>" mi pare suoni meglio...&nbsp;<img src="http://www.ialweb.it/forum/smileys/smiley2.gif" border="0" alt="Wink" title="Wink" />]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 11:43:29 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361322&amp;title=risolto-arrotondamento#3361322</guid>
  </item> 
  <item>
   <title>[Risolto] arrotondamento : grazie ragazzi per le vostre solerti...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361320&amp;title=risolto-arrotondamento#3361320</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=18938">imperiali</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 11:14<br /><br />grazie ragazzi per le vostre solerti riposte , ora testo e poi rendo dotto il forum]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 11:14:54 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361320&amp;title=risolto-arrotondamento#3361320</guid>
  </item> 
  <item>
   <title>[Risolto] arrotondamento :   L&amp;#039;arrotondamento per...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361318&amp;title=risolto-arrotondamento#3361318</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=19734">@Alex</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 11:00<br /><br />L'arrotondamento per Eccesso si ottiene sommando il massimo quantitativo necessario per far superare il valore di soglia... quindi si prende l'intero...!<br><br>Es, se vuoi che già con 1° decimale = 3 venga arrotondato allora somma al valore 0.7<br><br>ValoreArrotondato=Int(ValoreOrignale+0.7)...<br><br>Ci sono poi considerazioni relative ei DataYpe che sono affetti dall'arrotondamento dovuto al FloatingPoint ma è altro argomento.<br><br>Questa è una funzione che arrotonda<table width="99%"><tr><td><pre class="BBcode"><br><pre ="bbcode_code"="" style="height:348px;">Function Arrotonda(ByVal NumIn As Variant, _                     Optional AlDecimale As Integer=2, _                   Optional Eccesso As Boolean = True) As Variant  <font color="seagreen">         ' &#091;NumIn&#093;           Numero in ingresso          ' &#091;AlDecimale&#093;      Numero di decimali al quale arrotondare.          ' &#091;Eccesso&#093;         True=Eccesso / False=Difetto     </font>          Dim varNum      As Variant  <font color="seagreen">'Variabile</font>     Dim varIn       As Variant  <font color="seagreen">'Numero valutato</font>     Dim sgnInc      As Single   <font color="seagreen">'Numero di incremento per l'ECCESSO</font>      <font color="seagreen">    'Controllo la validità del Numero</font>         If IsNumeric(NumIn) Then            <font color="seagreen">' Converto in DECIMAL per la precisione(14Byte)</font>                   varIn = CDec(NumIn)         Else                    varIn = 0         End If  <font color="seagreen">     ' Il 5° decimale è per assicurare l'arrotondamento commerciale(4° decimale)         ' Se ECCESSO=True  ---&gt;(+ 0.99999)         ' Se ECCESSO=False ---&gt;(0)</font>             sgnInc = Abs(Eccesso) *<font color="#FF0000"> 0.99999 </font>         varNum = Abs(varIn)      <font color="seagreen">    'Arrotondo e recupero il segno dopo l'arrotondamento</font>     varNum = (Fix(varNum * (10 ^ AlDecimale) + sgnInc) / (10 ^ AlDecimale))          Arrotonda = Sgn(varIn) * varNum End Function<font face="Arial, Helvetica, sans-serif"></pre></td></tr></table></font></pre><br><br><br><br><br>Ora se guardi quel 0.99999 in rosso dovrai sostituirlo con 0.7... la funzione è richiamabile da una Query, ma forse nel tuo caso può bastare il suggerimento iniziale Int(ValoreOrignale+0.7)<br><br>Ciao<br><span style="font-size:10px"><br /><br />Edited by @Alex - 28/Apr/2012 at 11:02</span>]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 11:00:56 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361318&amp;title=risolto-arrotondamento#3361318</guid>
  </item> 
  <item>
   <title>[Risolto] arrotondamento : E se il tot/numero e&amp;#039; x,2...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361316&amp;title=risolto-arrotondamento#3361316</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=19087">fcarboni</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 10:12<br /><br />E se il tot/numero e' x,2 il risultato ti serve con i decimali o il nr intero arrotonato per difetto?<br />In questo caso prova:<br />iif((sum(tuocampo)-int(sum(tuocampo))&gt;0,29;int(sum(tuocampo)+1;int(sum(tuocampo))<br /> ]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 10:12:12 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361316&amp;title=risolto-arrotondamento#3361316</guid>
  </item> 
  <item>
   <title>[Risolto] arrotondamento :  Salve. chiedo un aiuto agli...</title>
   <link>http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361315&amp;title=risolto-arrotondamento#3361315</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ialweb.it/forum/member_profile.asp?PF=18938">imperiali</a><br /><strong>Subject:</strong> 16463620<br /><strong>Posted:</strong> 28/Apr/2012 at 09:39<br /><br />Salve. chiedo un aiuto agli amici in merito ad un arrotondamento per&nbsp; una espressione matematica.<br>ho creato una query ove nella tabella di riferimento vi è un campo numerico ha precisione doppia con decimali 1.<br>la query creata somma il campo, ora il problema sta nel decimale, ossia dovrei far scattare al numero pari il decimale con ,3<br>es:<br>1,3 = 2<br>1,1+2,2 = 4<br>essendo stato sempre schiappa in matem<img src="http://www.ialweb.it/forum/smileys/smiley18.gif" border="0" alt="Ouch" title="Ouch" />.&nbsp; le sto' provando tutte ma senza nessun risultato.<br>chiedo se in rete vi è qualche amico/a<img src="http://www.ialweb.it/forum/smileys/smiley32.gif" border="0" alt="Clap" title="Clap" /> che mi passi un pizzino con la formuletta da nettere nel campo criterio<br>grazie anticiapate <br>Maurizio<br><br><span style="font-size:10px"><br /><br />Edited by imperiali - 28/Apr/2012 at 11:54</span>]]>
   </description>
   <pubDate>Sat, 28 Apr 2012 09:39:47 +0000</pubDate>
   <guid isPermaLink="true">http://www.ialweb.it/forum/forum_posts.asp?TID=16463620&amp;PID=3361315&amp;title=risolto-arrotondamento#3361315</guid>
  </item> 
 </channel>
</rss>