Visual Studio http://blogs.ugidotnet.org/franx_blog/category/Visual Studio.aspx Visual Studio in generale it-IT Francesco Geri Subtext Version 2.6.0.0 Generare la classe proxy da WSDL http://blogs.ugidotnet.org/franx_blog/archive/2015/05/27/102006.aspx Avendo a disposizione l'URL di un servizio web specificato tramite WSDL è possibile generarne la classe proxy tramite il comando wsdl.exe.<br /> <br /> Aprire (ipotizzando di avere VS2012) il menu seguente:<br /> <br /> Programmi\Visual Studio 2012\Visual Studio Tools\Developer Command Prompt for VS2012<br /> <br /> Dal prompt posizionarsi nella cartella in cui si vuole generare il file della classe proxy e digitare il comando:<br /> <br /> &gt; wsdl.exe /language:VB<br /> <br /> Se si usa un url per il WSDL e c'è un proxy per l'accesso a internet, allora:<br /> <br /> &gt; wsdl.exe <url-wsdl> /proxy:<url-proxy> /pd:<dominio> /pu:<username> /pp:<password> /language:VB<br /> <br /> Esempio:<br /> <br /> &gt; wsdl.exe https://pteasb.actalis.it/ArubaSignService/ArubaSignService?WSDL /proxy:http://myServer.ACME.local:8080 /pd:ACME /pu:francescogeri /pp:myPassword123<br /> <br /> </password></username></dominio></url-proxy></url-wsdl><img src="http://blogs.ugidotnet.org/franx_blog/aggbug/102006.aspx" width="1" height="1" /> Francesco Geri http://blogs.ugidotnet.org/franx_blog/archive/2015/05/27/102006.aspx Wed, 27 May 2015 12:14:17 GMT http://blogs.ugidotnet.org/franx_blog/archive/2015/05/27/102006.aspx#feedback http://blogs.ugidotnet.org/franx_blog/comments/commentRss/102006.aspx Problema con l&rsquo;icona della Form MDI child quando &egrave; aperta maximized http://blogs.ugidotnet.org/franx_blog/archive/2013/07/26/101626.aspx <p>Se si apre un form MDI child come maximized si ha un problema nella visualizzazione della sua icona. <br />Basta creare un progetto con una Form MDI container (IsMdiContainer=True), mettere un Menustrip ed inserire il seguente codice per l’apertura della form figlia Form2:</p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Private</span> <span style="color: #0000ff">Sub</span> NewToolStripMenuItem_Click(sender <span style="color: #0000ff">As</span> <span style="color: #0000ff">Object</span>, e <span style="color: #0000ff">As</span> EventArgs) <span style="color: #0000ff">Handles</span> NewToolStripMenuItem.Click</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Dim</span> f <span style="color: #0000ff">As</span> <span style="color: #0000ff">New</span> Form2</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.MdiParent = <span style="color: #0000ff">Me</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.WindowState = FormWindowState.Maximized</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.Show()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">End</span> <span style="color: #0000ff">Sub</span></pre> <!--CRLF--></div> </div> <p>Il risultato sarà:</p> <p><a href="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/Problema-con-licona-della-Form-MDI-child_B5C9/image_4.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/Problema-con-licona-della-Form-MDI-child_B5C9/image_thumb_1.png" width="244" height="200" /></a></p> <p>Anche se in realtà la form Form2 ha una sua icona, per cui il risultato doveva essere:</p> <p><a href="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/Problema-con-licona-della-Form-MDI-child_B5C9/image_6.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/Problema-con-licona-della-Form-MDI-child_B5C9/image_thumb_2.png" width="244" height="200" /></a></p> <p> </p> <p>Per risolvere il problema ho trovato 2 modi (grazie alla stessa <a title="Fonte di questo articolo" href="http://vbcity.com/forums/t/123134.aspx">fonte</a>):</p> <p><strong>Primo metodo <br /></strong>Giocare con il SuspendLayout del menustrip:</p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Private</span> <span style="color: #0000ff">Sub</span> NewToolStripMenuItem_Click(sender <span style="color: #0000ff">As</span> <span style="color: #0000ff">Object</span>, e <span style="color: #0000ff">As</span> EventArgs) <span style="color: #0000ff">Handles</span> NewToolStripMenuItem.Click</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.MenuStrip1.SuspendLayout()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> </pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Dim</span> f <span style="color: #0000ff">As</span> <span style="color: #0000ff">New</span> Form2</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.MdiParent = <span style="color: #0000ff">Me</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.WindowState = FormWindowState.Maximized</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> f.Show()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> </pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.MenuStrip1.Visible = <span style="color: #0000ff">False</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.MenuStrip1.Visible = <span style="color: #0000ff">True</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.MenuStrip1.ResumeLayout()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">End</span> Sub</pre> <!--CRLF--></div> </div> <p> </p> <p><strong>Secondo metodo <br /></strong>Inserire nella Load della form figlia la seguente riga di codice:</p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Me</span>.Icon = <span style="color: #0000ff">New</span> Icon(<span style="color: #0000ff">Me</span>.Icon, <span style="color: #0000ff">Me</span>.Icon.Size)</pre> <!--CRLF--></div> </div> <p>Per cui, nel mio esempio, avrei:</p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Private</span> <span style="color: #0000ff">Sub</span> Form2_Load(sender <span style="color: #0000ff">As</span> <span style="color: #0000ff">Object</span>, e <span style="color: #0000ff">As</span> EventArgs) <span style="color: #0000ff">Handles</span> <span style="color: #0000ff">MyBase</span>.Load</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.Label1.Text = <span style="color: #006080">"Sono la form 2 creata alle "</span> &amp; Now.ToString</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #008000">' Fix del problema icona form figlia</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #0000ff">Me</span>.Icon = <span style="color: #0000ff">New</span> Icon(<span style="color: #0000ff">Me</span>.Icon, <span style="color: #0000ff">Me</span>.Icon.Size)</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">End</span> <span style="color: #0000ff">Sub</span></pre> <!--CRLF--></div> </div><img src="http://blogs.ugidotnet.org/franx_blog/aggbug/101626.aspx" width="1" height="1" /> Francesco Geri http://blogs.ugidotnet.org/franx_blog/archive/2013/07/26/101626.aspx Fri, 26 Jul 2013 14:04:10 GMT http://blogs.ugidotnet.org/franx_blog/archive/2013/07/26/101626.aspx#feedback http://blogs.ugidotnet.org/franx_blog/comments/commentRss/101626.aspx ASPOSE Libraries for .NET http://blogs.ugidotnet.org/franx_blog/archive/2013/03/28/101493.aspx <p>When you need to process some Office file in your project you can use, for example, the Office automation mechanism. But it need to have Office installed on your machine. </p> <p>Otherwise, for example, you can choose a third part library. <br />I think that you can find many libraries over the web, but, for my purposes, in some of the projects I worked on, I used <strong><a href="http://www.aspose.com/">Aspose libraries</a></strong> (home page <a href="http://www.aspose.com/">http://www.aspose.com/</a>).</p> <p>With those libraries you can easily manipulate <strong>Office documents</strong> (<strong>Word</strong>, <strong>Excel</strong>, <strong>PowerPoint</strong>, <strong>Visio </strong>and <strong>Project</strong>!) without needing to have Office installed on your machine. You can open a navigate a document, or modify it or create a new document and fill it. <br />For example you can create a document with a table: <br /></p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #008000">' We call this method to start building the table.</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">builder.StartTable()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">builder.InsertCell()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">builder.Write(<span style="color: #006080">"Row 1, Cell 1 Content."</span>)</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #008000">' Call the following method to end the row and start a new row.</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">builder.EndRow()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #008000">' Signal that we have finished building the table.</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">builder.EndTable()</pre> <!--CRLF--></div> </div> <p> <br />Following image is grabbed from Aspose site:</p> <p><a href="http://www.aspose.com/"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="Capture1" border="0" alt="Capture1" src="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/ASPOSE-Total_C7CF/Capture1_1.png" width="468" height="329" /></a></p> <p> </p> <p> <br />Aspose provides also libraries that allow you to manipulate <strong>PDF documents</strong>. <br />Like Office document, you can open, modify or create from the beginning a PDF document. <br />But you can also easily convert many documents types (Office, Html, Text, images) to the PDF format. The code to convert a document is very simple: <br /></p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Dim</span> doc <span style="color: #0000ff">As</span> <span style="color: #0000ff">New</span> Aspose.Words.Document(strIn)</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">doc.Save(strOut, Aspose.Words.SaveFormat.Pdf)</pre> <!--CRLF--></div> </div> <p> <br />If needed, you can also converto to PDF/A. Other security features are available, like encrypt and decrypt PDF documents or sign it using PKCS#1, PKCS#7 and PKCS#7 detached signature types and with the use of digital certificate. No Adobe Acrobat Automation are required!</p> <p> <br />Aspose libraries are availables also for <strong>OCR</strong> and <strong>Barcodes</strong>. <br />For example, we worked on barcode recognition. Using Barcode libraries you can recognize barcodes from images or PDF, or writes them into the files. And both 1D and 2D barcodes types are supported (you can see all supported barcodes from this url: <a href="http://www.aspose.com/.net/barcode-component/key-features.aspx)">http://www.aspose.com/.net/barcode-component/key-features.aspx)</a>. <br />Following code allows you to reads barcodes on a jpg file: <br /></p> <div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: 'Courier New', courier, monospace; direction: ltr; font-size: 8pt; overflow: hidden; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"> <div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Dim</span> reader <span style="color: #0000ff">As</span> BarCodeReader</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">reader = <span style="color: #0000ff">New</span> BarCodeReader(<span style="color: #006080">"C:\SamplePic\EAN13.jpg"</span>, BarCodeReadType.EAN13)</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Do</span> <span style="color: #0000ff">While</span> reader.Read()</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #008000">' get symbology type</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> Console.WriteLine(<span style="color: #006080">"Symbology Type: "</span> &amp; reader.GetReadType().ToString())</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> <span style="color: #008000">' get code text</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"> Console.WriteLine(<span style="color: #006080">"CodeText: "</span> &amp; reader.GetCodeText())</pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"><span style="color: #0000ff">Loop</span></pre> <!--CRLF--> <pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: 'Courier New', courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px">reader.Close()</pre> <!--CRLF--></div> </div> <p> </p> <p>Other libraries are concerning <strong>SharePoint</strong>, <strong>Cloud </strong>and <strong>JasperReports</strong>.</p> <p> </p> <p>All this componentes are very useful in many cases, and they are available for .NET and are built using managed code and can be installed and deployed as a single .NET assemblies. If you prefere, the libraries are available also for java, but this feature is off topic for us! :) <br />You can buy the single developer kit for your needs, or the full license (Aspose.Total). </p> <p><a href="http://www.aspose.com/.net/total-component.aspx"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/Windows-Live-Writer/ASPOSE-Total_C7CF/image_3.png" width="513" height="214" /></a> <br /></p> <p>You can get the OEM licence for unlimited royalty-free distribution, and I think this is a good solution.</p> <p> </p> <p>The Aspose technical support is very good. You can count on a rich on line documentation with many code examples, dedicated forums with many posts and quick support responses!</p><img src="http://blogs.ugidotnet.org/franx_blog/aggbug/101493.aspx" width="1" height="1" /> Francesco Geri http://blogs.ugidotnet.org/franx_blog/archive/2013/03/28/101493.aspx Thu, 28 Mar 2013 17:53:01 GMT http://blogs.ugidotnet.org/franx_blog/archive/2013/03/28/101493.aspx#feedback http://blogs.ugidotnet.org/franx_blog/comments/commentRss/101493.aspx Visual Inheritance nei controlli Windows Form http://blogs.ugidotnet.org/franx_blog/archive/2013/03/08/101464.aspx <p>Dovendo fare in una stessa applicazione molte form di dialogo per l’immissione o visualizzazione di informazioni ho pensato di creare una form base (scheletro) che fosse impostata con le caratteristiche comuni (font, colore di sfodo) e con i pulsanti ok, applica, annulla. A questo punto tutte le form di dialogo ereditano da questa (invece che da System.Windows.Form.Form) e così si trovano automaticamente i pulsanti e tutto il resto.</p> <p>Per posizionare i pulsanti ho pensato di usare un TableLayoutPanel in modo che ridimensionando le form ereditate i pulsanti si spostino nel punto giusto.</p> <p>Però mi sono accorto che, in Visual Studio, dal Form editor il controllo TableLayoutPanel ed i suoi children risultano in sola lettura. Sostituendo il TableLayoutPanel con un Panel posso invece editare i controlli in esso contenuti.</p> <p>Il problema è che, per poter essere editati nel Form editor, i controlli ereditati devono supportare la Visual Inheritance, ed il TableLayoutPanel non la supporta. </p> <p>La cosa è documentata in questa pagina: <a href="http://msdn.microsoft.com/en-us/library/ms171689%28VS.80%29.aspx" target="_blank">Best Practices for the TableLayoutPanel Control</a>.</p> <p>Ci sono altri controlli che hanno lo stesso problema, come indicato nell’articolo <a href="http://msdn.microsoft.com/en-us/library/1z3efhd2.aspx" target="_blank">Walkthrough: Demonstrating Visual Inheritance</a>. In particolare sono: <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser.aspx">WebBrowser</a> <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.toolstrip.aspx">ToolStrip</a> <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.toolstrippanel.aspx">ToolStripPanel</a> <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.tablelayoutpanel.aspx">TableLayoutPanel</a> <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.flowlayoutpanel.aspx">FlowLayoutPanel</a> <br /><a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridview.aspx">DataGridView</a></p><img src="http://blogs.ugidotnet.org/franx_blog/aggbug/101464.aspx" width="1" height="1" /> Francesco Geri http://blogs.ugidotnet.org/franx_blog/archive/2013/03/08/101464.aspx Fri, 08 Mar 2013 10:29:33 GMT http://blogs.ugidotnet.org/franx_blog/archive/2013/03/08/101464.aspx#feedback http://blogs.ugidotnet.org/franx_blog/comments/commentRss/101464.aspx Problemi con il Microsoft Visual Studio Version Selector su Vista/Win7 http://blogs.ugidotnet.org/franx_blog/archive/2010/05/14/98564.aspx <p>Può capitare con Vista o Windows 7 che facendo doppio click da Esplora Risorse su un file di progetto o di solution di Visual Studio non succeda nulla. Ovvero non parta Visual Studio.</p> <p>Se capita, allora il motivo potrebbe essere la concomitanza di questi 2 fattori:</p> <p>1) La UAC è attiva <br />2) Visual Studio è impostato per partire sempre As Administrator</p> <p>Se è così allora si può fare una delle 2 cose seguenti:</p> <p>- Togliere il flag “As Administrator” a Visual Studio, oppure <br />- Metterlo a “Microsoft Visual Studio Version Selector”</p> <p>L’eseguibile “Microsoft Visual Studio Version Selector” è l’utility di Visual Studio associata all’estensione dei file di progetto e di solution ed ha il compito di capire di che versione di visual studio è il file e di avviare quella versione passandogli il file. <br />Per cui il selector parte, vede che il file sln è di VS2008, ad esempio, cerca quindi di avviare VS2008. Se questo però ha il flag As Administrator allora l’avvio non riesce. <br />Per impostare lo stesso flag sul selector bisogna individuarlo: si trova nella cartella (Drive C o quello che è):</p> <p>[C]:\Program Files (x86)\Common Files\microsoft shared\MSEnv</p> <p>L’eseguibile si chiama VSLauncher.exe, fare click con il tasto destro e aprire le Proprietà. Nel pannello Compatibility impostare il flag Run this program as an administrator:</p> <p> </p> <p><a href="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/WindowsLiveWriter/ProblemiconilMicrosoftVisualStudioVersio_A509/image_2.png"><img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://blogs.ugidotnet.org/images/blogs_ugidotnet_org/franx_blog/WindowsLiveWriter/ProblemiconilMicrosoftVisualStudioVersio_A509/image_thumb.png" width="423" height="537" /></a></p><img src="http://blogs.ugidotnet.org/franx_blog/aggbug/98564.aspx" width="1" height="1" /> Francesco Geri http://blogs.ugidotnet.org/franx_blog/archive/2010/05/14/98564.aspx Fri, 14 May 2010 12:44:00 GMT http://blogs.ugidotnet.org/franx_blog/archive/2010/05/14/98564.aspx#feedback 7 http://blogs.ugidotnet.org/franx_blog/comments/commentRss/98564.aspx