<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-2126889675011838330</id><updated>2024-10-04T18:57:17.147-07:00</updated><category term="Visual .Net"/><category term="Visual C#"/><category term="Visual C++"/><category term="Visual C++(Consola)"/><title type='text'>Programacion en alta</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>25</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-5778207286323984136</id><published>2012-10-03T16:35:00.001-07:00</published><updated>2012-10-03T16:35:54.333-07:00</updated><title type='text'>BLOG MEJORADO</title><content type='html'>BLOG MEJORADO</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/5778207286323984136/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/10/blog-mejorado.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/5778207286323984136'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/5778207286323984136'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/10/blog-mejorado.html' title='BLOG MEJORADO'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-3684100849723196978</id><published>2012-06-10T13:17:00.002-07:00</published><updated>2012-09-20T15:41:54.168-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++(Consola)"/><title type='text'>Ejercicios 1,2,3</title><content type='html'>En esta parte del blog de&amp;nbsp;programación&amp;nbsp;colocaremos unos&amp;nbsp;prácticos&amp;nbsp;ejercicios los cuales los ayudarán ya que son los ejercicios más básicos con los cuales se comienza a programar.&lt;br /&gt;
A continuación les dejare, problemas que resolveré en un video, para hacer más dinámico el tutorial.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiP27to3X749uMgWDN2BdMu8WqVOhpnlsOgUjJATZBJtr3izHsYcDkVwQpkUUS0MzEH9__B7T24-atwDm5F86X68wU7T4zHbxeZu_tfWqqPDC-3M_1U5lJ9CLAfCRrCHXn8NbAQVZpsFug/s1600/1s1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;332&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiP27to3X749uMgWDN2BdMu8WqVOhpnlsOgUjJATZBJtr3izHsYcDkVwQpkUUS0MzEH9__B7T24-atwDm5F86X68wU7T4zHbxeZu_tfWqqPDC-3M_1U5lJ9CLAfCRrCHXn8NbAQVZpsFug/s640/1s1.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhVGuDB6aUUFhAn3awmqrOYwLGHZpQXDoYBgyO6QkQTH3WI0QydcjyLey0VXWhAY8M9GKyWOGy-Qw8KKhIHFszijOtk3UbRNd2ABtWOLxWr1dVIZW5pX-jLdxLOHEXitDCK3Fatw78WrYo/s1600/2s2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;380&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhVGuDB6aUUFhAn3awmqrOYwLGHZpQXDoYBgyO6QkQTH3WI0QydcjyLey0VXWhAY8M9GKyWOGy-Qw8KKhIHFszijOtk3UbRNd2ABtWOLxWr1dVIZW5pX-jLdxLOHEXitDCK3Fatw78WrYo/s640/2s2.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh1W6KuEaT_kUgppL_w4ALmytLlwCyfIWpsKla2Af8A7UoKQZVGjgj7fMw3m6hpikRhchmOpNpdlXEy2EgSvi5RtJAC-dj5fswycGypo__ezq3FWtebgKYzpi-Lcg7GxqtHcz0G5v4Fbi0/s1600/3s3.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;328&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh1W6KuEaT_kUgppL_w4ALmytLlwCyfIWpsKla2Af8A7UoKQZVGjgj7fMw3m6hpikRhchmOpNpdlXEy2EgSvi5RtJAC-dj5fswycGypo__ezq3FWtebgKYzpi-Lcg7GxqtHcz0G5v4Fbi0/s640/3s3.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgx1x4MvUr-LA1u8DlP9ZxOA_NkIX8qhPZ0VRT4gstpGHc1yVkNl0LNzsDkAu5vjQwpsBD9FU_sCzWKd9Lk-YD1556V5cQEJdCLC47JJRzJuBDnkEOTP4IYAoEE9Xlx8GpH3wPTtpgsjwU/s1600/reto.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;332&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgx1x4MvUr-LA1u8DlP9ZxOA_NkIX8qhPZ0VRT4gstpGHc1yVkNl0LNzsDkAu5vjQwpsBD9FU_sCzWKd9Lk-YD1556V5cQEJdCLC47JJRzJuBDnkEOTP4IYAoEE9Xlx8GpH3wPTtpgsjwU/s640/reto.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/3684100849723196978/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/ejercicios-123.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/3684100849723196978'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/3684100849723196978'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/ejercicios-123.html' title='Ejercicios 1,2,3'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiP27to3X749uMgWDN2BdMu8WqVOhpnlsOgUjJATZBJtr3izHsYcDkVwQpkUUS0MzEH9__B7T24-atwDm5F86X68wU7T4zHbxeZu_tfWqqPDC-3M_1U5lJ9CLAfCRrCHXn8NbAQVZpsFug/s72-c/1s1.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-6437778989062873883</id><published>2012-06-10T13:11:00.001-07:00</published><updated>2012-06-10T13:11:49.562-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++(Consola)"/><title type='text'>Función Printf y Scanf</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiw7JZHVt-6UKIpHkbFMuSq35fffALMWvwSRq2bpYckMExID0O4ltrBwuoeQzSZeYlTYybG7nsiACvTaliPebMUKVeiGCRydnTr7itRt6CTFpLxZ9NGYGXXiJPg2Cc6uNpa7TcC2yYLAGQ/s1600/printf.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;254&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiw7JZHVt-6UKIpHkbFMuSq35fffALMWvwSRq2bpYckMExID0O4ltrBwuoeQzSZeYlTYybG7nsiACvTaliPebMUKVeiGCRydnTr7itRt6CTFpLxZ9NGYGXXiJPg2Cc6uNpa7TcC2yYLAGQ/s640/printf.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
La instrucción printf sirve para poder imprimir mensajes o resultados, los cuales nos pedirán mostrar los problemas o quizás mensajes que quisiéramos que el usuario lee para que nos brinde los datos necesarios para correr el programa. Ahí podemos observar su simbología y dos ejemplos.&lt;/div&gt;
&lt;div&gt;
Digamos si en la consola quiero mostrar el siguiente mensaje: Hola a todos este es mi primer tutorial. La sintaxis sería de la &amp;nbsp;siguiente manera: &amp;nbsp;printf(“Hola a todos este es mi primer tutorial”);&lt;/div&gt;
&lt;div&gt;
Nota importante: siempre después de cada instrucción se pone el ; al final. Como nosotros finalizamos una oración con un punto (.) el programa finaliza su “oración” con el ;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhqGhbGFw8ki2DVfXtAiA7XfrAflvIX6nxYdxuov7csS2PRNf9M1X4uuA68LTG0Vu3gKKd8Kblv-iHwJe_xdl7wUfgyBXIrmgvoaQeKqlFuIwzwVToSo1Favdd1D1k4uXLkudEQyu1lnqo/s1600/scanf.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;384&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhqGhbGFw8ki2DVfXtAiA7XfrAflvIX6nxYdxuov7csS2PRNf9M1X4uuA68LTG0Vu3gKKd8Kblv-iHwJe_xdl7wUfgyBXIrmgvoaQeKqlFuIwzwVToSo1Favdd1D1k4uXLkudEQyu1lnqo/s640/scanf.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
Nota importante: siempre después de cada instrucción se pone el ; al final. Como nosotros finalizamos una oración con un punto (.) el programa finaliza su “oración” con el ;
La instrucción escanf nos sirve para poder hacer el ingreso de datos, y darle los respectivos valores a nuestras variables. Por ejemplo si mi variable es un numero entero llamada variablentera, si nosotros queremos asignarle el valor de 87 a la variable variablentera, pues haríamos lo siguiente:
 scanf(“%d”,&amp;amp;variablentera);
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/6437778989062873883/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/funcion-printf-y-scanf.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6437778989062873883'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6437778989062873883'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/funcion-printf-y-scanf.html' title='Función Printf y Scanf'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiw7JZHVt-6UKIpHkbFMuSq35fffALMWvwSRq2bpYckMExID0O4ltrBwuoeQzSZeYlTYybG7nsiACvTaliPebMUKVeiGCRydnTr7itRt6CTFpLxZ9NGYGXXiJPg2Cc6uNpa7TcC2yYLAGQ/s72-c/printf.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-6566291362339060131</id><published>2012-06-10T12:47:00.001-07:00</published><updated>2012-06-10T12:47:30.196-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++(Consola)"/><title type='text'>Operadores</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Hola y bienvenidos a los cursos de programación en C++ en el modo consola, en este apartado estaremos explicando y mostrando en tablas los distintos tipos de operadores en C++, esperamos que les guste y como siempre les decimos si tienen alguna duda haganla saber y con gusto les ayudaremos.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjB9uC1f4b6lrQekTkI631zu5M2RFxrAJQog3B94H5sBpFbTfAEl1ye-sQ4lITx6pRpgCHKqJlH8boXzzgK4RVvuylvtfadiPCN7Tzlw2-NoCBJADN8-ivjPHgZkWTukpm_mypEw1CAPDs/s1600/1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;246&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjB9uC1f4b6lrQekTkI631zu5M2RFxrAJQog3B94H5sBpFbTfAEl1ye-sQ4lITx6pRpgCHKqJlH8boXzzgK4RVvuylvtfadiPCN7Tzlw2-NoCBJADN8-ivjPHgZkWTukpm_mypEw1CAPDs/s640/1.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Estos son los operadores aritméticos, que
vamos a utilizar en este primer tutorial. En la tabla se muestra la simbología
y su respectiva operación. En el caso del modulo &lt;b&gt;% &lt;/b&gt;, el modulo sirve para hallar el residuo entre dos números
enteros
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjhrgKmc8EYagnLT5TKXcsJ63q1rYfVx8xY8L_BgctCSpesRehj8acYjWNAFbMww5g0T145kq69L-OqUUzOo0ywPQvHLDsAGU1vcr1HVYp_NCDkSUj6aV1KZTbIjhpE0vk5UE2m-E-0nf8/s1600/2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;428&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjhrgKmc8EYagnLT5TKXcsJ63q1rYfVx8xY8L_BgctCSpesRehj8acYjWNAFbMww5g0T145kq69L-OqUUzOo0ywPQvHLDsAGU1vcr1HVYp_NCDkSUj6aV1KZTbIjhpE0vk5UE2m-E-0nf8/s640/2.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;
En esta tabla se pueden apreciar los
operadores de relación, su respectiva simbología, su descripción y unos
ejemplos.
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj3t1sm-soF-kE_LKl06E5aa_sLuHwIGtKZpgD_fNmtIdSnubnCFe42Q03moiCKk9i9kubepCYVt_3KERLsdAXEqVj_tJHrno5-CDhx1kGDF7IjP54vMfR15O6sTKESwlpl_WCiMm8yY5o/s1600/3.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;354&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj3t1sm-soF-kE_LKl06E5aa_sLuHwIGtKZpgD_fNmtIdSnubnCFe42Q03moiCKk9i9kubepCYVt_3KERLsdAXEqVj_tJHrno5-CDhx1kGDF7IjP54vMfR15O6sTKESwlpl_WCiMm8yY5o/s640/3.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Estos son los operadores lógicos, los cuales  son utilizados más para hacer validaciones de datos. Podemos apreciar la simbología del operador y su significado. Y abajo como segunda tabla los respectivos valores que tomarían cuando sean falsas y verdaderas las expresiones.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/6566291362339060131/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/operadores.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6566291362339060131'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6566291362339060131'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/operadores.html' title='Operadores'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjB9uC1f4b6lrQekTkI631zu5M2RFxrAJQog3B94H5sBpFbTfAEl1ye-sQ4lITx6pRpgCHKqJlH8boXzzgK4RVvuylvtfadiPCN7Tzlw2-NoCBJADN8-ivjPHgZkWTukpm_mypEw1CAPDs/s72-c/1.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-1898035977231331692</id><published>2012-06-10T12:37:00.001-07:00</published><updated>2012-06-10T12:53:32.245-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++(Consola)"/><title type='text'>Especificadores</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Hola y bienvenidos nuevamente a los cursos de&amp;nbsp;programación&amp;nbsp;en C++ en el modo consola, en este caso el amigo Carlos nos hizo el favor de proporcionar la información concreta sobre el tema de los especificadores &amp;nbsp;en C++, esperamos que sea de su agrado.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHZpkBDFH2_-BA9jT7O9WRfffjF8XYAypu0qVc5nIfqtYc8Dp-X1Yo6-lURpcC6LhHcCJd2dLZpv_bXJF-ADm7MIWNgrocrWhEk6Mgm5XdeVjX9_YkGa49sFrwkrtRUxxd3-9ZjcXZ5uA/s1600/especificadores.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;382&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHZpkBDFH2_-BA9jT7O9WRfffjF8XYAypu0qVc5nIfqtYc8Dp-X1Yo6-lURpcC6LhHcCJd2dLZpv_bXJF-ADm7MIWNgrocrWhEk6Mgm5XdeVjX9_YkGa49sFrwkrtRUxxd3-9ZjcXZ5uA/s640/especificadores.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Los especificadores de formato nos sirven para que en el momento del ingreso de datos, el programa pueda asignar el valor de la variable que ingresamos a un tipo de formato.  Por ejemplo yo puedo decir tomate, pero el tomate es un vegetal, donde vegetal sería su especificador de formato, o quizás pueda decir mono, pero el mono es un mamífero, donde mamífero sería su especificador de formato. En la tabla se muestra la sintaxis de los especificadores de formato y sus respectivos tipos de datos.&lt;/div&gt;
&lt;h2&gt;
&lt;span style=&quot;color: #76a5af;&quot;&gt;Juegos con los especificadores de formato.&lt;/span&gt;&lt;/h2&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipciLYeagPXZ880Nu9o9T8q5xWlscSI_0-eLk6jNYjSYbRg77mmJEj8id9LeX3V1qEQmzEDK0Nz-3vr6DYqQcdD16Ngsl8iB1mCxScghCat1x-ZNvUM5deSwO3u6BIFZx6-eTo9rUgsZs/s1600/prop.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;226&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipciLYeagPXZ880Nu9o9T8q5xWlscSI_0-eLk6jNYjSYbRg77mmJEj8id9LeX3V1qEQmzEDK0Nz-3vr6DYqQcdD16Ngsl8iB1mCxScghCat1x-ZNvUM5deSwO3u6BIFZx6-eTo9rUgsZs/s640/prop.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #76a5af;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/1898035977231331692/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/especificadores.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1898035977231331692'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1898035977231331692'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/especificadores.html' title='Especificadores'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHZpkBDFH2_-BA9jT7O9WRfffjF8XYAypu0qVc5nIfqtYc8Dp-X1Yo6-lURpcC6LhHcCJd2dLZpv_bXJF-ADm7MIWNgrocrWhEk6Mgm5XdeVjX9_YkGa49sFrwkrtRUxxd3-9ZjcXZ5uA/s72-c/especificadores.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-1722864703542536696</id><published>2012-06-10T12:34:00.002-07:00</published><updated>2012-06-10T19:50:22.149-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++(Consola)"/><title type='text'>Tipos de datos</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Hola y bienvenidos a los nuevos cursos de programación en C++, los cuales serán impartidos por mi amigo Carlos así que ya saben cualquier duda no duden en contactarse para resolver sus dudas o sugerencias.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiBx59Ic-Gxl-xSABlyAZRhixoeLoXFkrY6JlErk79P1gHxEagSBgPkt94r1IDIDgidY135kc1C8Ee-2FZY-dR8Ml1qI8sMpOxs21X6OtXmABn6IBsLOl3ZHi7xcUInEcx1cI_ildXxfmg/s1600/Capture.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;358&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiBx59Ic-Gxl-xSABlyAZRhixoeLoXFkrY6JlErk79P1gHxEagSBgPkt94r1IDIDgidY135kc1C8Ee-2FZY-dR8Ml1qI8sMpOxs21X6OtXmABn6IBsLOl3ZHi7xcUInEcx1cI_ildXxfmg/s640/Capture.PNG&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Estos son los tipos de datos en el lenguaje C, básicamente en pocas palabras estos tipos de datos sirven para que el programa diferencie a las variables, es decir, las clasifique por rasgos particulares. Por ejemplo nosotros cuando escuchamos una canción, simplemente no decimos esa es una canción cualquiera, nosotros la clasificamos por géneros musicales: rock, pop, blues, balada, etc. Pasa lo mismo con el programa cuando nosotros ingresamos información este lo cataloga y lo diferencia por los tipos de datos. Los más usados son los tipos de datos: bool, char, int, longlong, float y double.  Los tipos de datos bool se utilizan para generar valores de afirmación y negación, es decir nos retornara valor verdadero que es 1 o un valor  falso que es 0; esto sirve cuando tenemos que hacer comparaciones: 1&amp;gt;10 si tu le asignas un dato bool, el programa imprimirá 0 porque es falso. Luego los tipo de datos char se utilizan para las letras que ingresamos, al momento de ingresar por ejemplo la letra ‘a’ el programa no la guardará como letra  sino como su código ascii que sería 97. Los datos de tipo int, se les asigna a todos los números enteros pero su rango de valores es [-2,147,483,648 ; 2,147,483,648]. Los datos de tipo longlong  es también para todos los números enteros pero su rango de valores es [-9,223,372,036,854,775,808 ; 9,223,372,036,854,775,808], claramente vemos que la diferencia entre usar un int entre un longlong, radica en el tamaño del numero. Los datos tipo float, se les asigna todos los números reales, donde su rango de valores son números que contengan 7 dígitos. Los datos tipo doublé, se les asigna todos los números reales, donde su rango de valores son números que contengan 15 dígitos, como vemos el double es más grande que el float.&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/1722864703542536696/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/tipos-de-datos.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1722864703542536696'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1722864703542536696'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/tipos-de-datos.html' title='Tipos de datos'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-5473995777102845905</id><published>2012-06-03T12:40:00.004-07:00</published><updated>2012-06-03T12:41:18.388-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>Tipos de datos VB.Net</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmYUlTOYSjfqam1dpGy_1HCtz3zZvFiiCSIdmUIyOjFKX26Jv4htRljkrPGHNfTe78hjSsraDYGq9yVL2DEnbE9rdwP6_mp6R3VyRTn6SHFVA4ecCJY4NvsDFAtsq2QU-zZ8cqYChKstU/s1600/Untitled-1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmYUlTOYSjfqam1dpGy_1HCtz3zZvFiiCSIdmUIyOjFKX26Jv4htRljkrPGHNfTe78hjSsraDYGq9yVL2DEnbE9rdwP6_mp6R3VyRTn6SHFVA4ecCJY4NvsDFAtsq2QU-zZ8cqYChKstU/s1600/Untitled-1.jpg&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div id=&quot;mainSection&quot;&gt;
&lt;div id=&quot;mainBody&quot;&gt;
&lt;div&gt;
&lt;div style=&quot;background-color: #cccccc;&quot;&gt;
&lt;table align=&quot;left&quot; border=&quot;0&quot; cellspacing=&quot;1&quot; style=&quot;width: 687px;&quot;&gt;
          &lt;tbody&gt;
&lt;tr&gt;
              &lt;th align=&quot;center&quot; bgcolor=&quot;#CCCCCC&quot; valign=&quot;middle&quot; width=&quot;93&quot;&gt;&lt;span data-guid=&quot;ed793886c41673a6220a3d4dcba25987&quot; data-source=&quot;Visual Basic type&quot; id=&quot;mt2&quot;&gt;Tipo de Visual Basic&lt;/span&gt;&lt;/th&gt;
              &lt;th align=&quot;center&quot; bgcolor=&quot;#CCCCCC&quot; valign=&quot;middle&quot; width=&quot;112&quot;&gt;&lt;span data-guid=&quot;bcdeeece115c4323c5ae0f37503f58ae&quot; data-source=&quot;Nominal storage allocation&quot; id=&quot;mt4&quot;&gt;Asignación de almacenamiento nominal&lt;/span&gt;&lt;/th&gt;
              &lt;th align=&quot;center&quot; bgcolor=&quot;#CCCCCC&quot; valign=&quot;middle&quot; width=&quot;272&quot;&gt;&lt;span data-guid=&quot;234eb100dda63320b04088a4143a6513&quot; data-source=&quot;Value range&quot; id=&quot;mt5&quot;&gt;Intervalo de valores&lt;/span&gt;&lt;/th&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Boolean&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;En función de la plataforma de implementación&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;True o False&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Byte&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;1 byte&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 255 (sin signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Char (carácter individual)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;2 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 65535 (sin signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Fecha&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;8 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0:00:00 (medianoche) del 1 de enero de 0001 a 11:59:59 p.m. del 31 de diciembre de 9999.&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Decimal&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;16 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a +/-79.228.162.514.264.337.593.543.950.335 (+/-7,9... E+28) † sin separador decimal; 0 a +/-7,9228162514264337593543950335 con 28 posiciones a la derecha del decimal; &lt;br /&gt;
el número distinto de cero más pequeño es +/-0,0000000000000000000000000001 (+/-1E-28)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Double (punto flotante de precisión doble)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;8 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-1,79769313486231570E+308 a -4,94065645841246544E-324  para los valores negativos; &lt;br /&gt;
4,94065645841246544E-324 a 1,79769313486231570E+308 † para los valores positivos&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Integer&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;4 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-2.147.483.648 a 2.147.483.647 (con signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Long (entero largo)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;&lt;span data-guid=&quot;9cc7856411dc703a1f5775ae77a33a96&quot; data-source=&quot;8 bytes&quot; id=&quot;mt30&quot;&gt;8 bytes&lt;/span&gt;&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-9.223.372.036.854.775.808 a 9.223.372.036.854.775.807 (9,2...E+18 †) (con signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Objeto&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;4 bytes en plataforma de 32 bits&lt;br /&gt;
8 bytes en plataforma de 64 bits&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;Cualquier tipo puede almacenarse en una variable de tipo Object&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;SByte&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;1 byte&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-128 a 127 (con signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Short (entero corto)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;2 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-32.768 a 32.767 (con signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;Single (punto flotante de precisión sencilla)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;4 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;-3,4028235E+38 a -1,401298E-45 † para los valores negativos; &lt;br /&gt;
1,401298E-45 a 3,4028235E+38 † para los valores positivos&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;String (longitud variable&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;En función de la plataforma de implementación&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 2.000 millones de caracteres Unicode aprox.&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;UInteger&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;4 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 4.294.967.295 (sin signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;ULong&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;8 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 18.446.744.073.709.551.615 (1,8...E+19 †) (sin signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;User-Defined (estructura)&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;En función de la plataforma de implementación&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;Cada   miembro de la estructura tiene un intervalo de valores determinado por   su tipo de datos y es independiente de los intervalos de valores   correspondientes a los demás miembros.&lt;/td&gt;
            &lt;/tr&gt;
&lt;tr&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#f2f2f2&quot; valign=&quot;top&quot;&gt;UShort&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;2 bytes&lt;/td&gt;
              &lt;td align=&quot;left&quot; bgcolor=&quot;#FFFFFF&quot; valign=&quot;top&quot;&gt;0 a 65.535 (sin signo)&lt;/td&gt;
            &lt;/tr&gt;
&lt;/tbody&gt;
        &lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/5473995777102845905/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/tipos-de-datos-vbnet.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/5473995777102845905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/5473995777102845905'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/06/tipos-de-datos-vbnet.html' title='Tipos de datos VB.Net'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhmYUlTOYSjfqam1dpGy_1HCtz3zZvFiiCSIdmUIyOjFKX26Jv4htRljkrPGHNfTe78hjSsraDYGq9yVL2DEnbE9rdwP6_mp6R3VyRTn6SHFVA4ecCJY4NvsDFAtsq2QU-zZ8cqYChKstU/s72-c/Untitled-1.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-2718999860462132444</id><published>2012-05-19T15:08:00.000-07:00</published><updated>2012-05-19T15:09:31.088-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Switch Case</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/C_Sharp.png&quot; style=&quot;display: none;&quot; /&gt;

&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s1600/Visual_C%252B%252B_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Las instrucciones Switch Case son un sustituto por mucho tiempo si las declaraciones que comparan una variable para varios valores de &quot;integrales&quot; (&quot;integral&quot; los valores son simplemente los valores que se pueden expresar como un número entero, como el valor de un char). El formato básico para el uso de Switch Case se describe a continuación. El valor de la variable dada en el interruptor se compara con el valor después de cada uno de los casos, y cuando un valor coincide con el valor de la variable, el ordenador continúa ejecutando el programa desde ese punto.&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;switch ( [variable] ) {
case this-value:
  //Código a ejecutar si la sentencia es verdadera.&lt;variable&gt;
  //break;
case that-value:
  //Código a ejecutar si la sentencia es verdadera.
  //break;
...
default:
  //Código a ejecutar si las sentencias anteriores no se cumplen.
  //break;
}&lt;/pre&gt;
&lt;div&gt;
Bueno como en todos mis tutoriales de Windows Forms tengo que explicar paso a paso aquí estan los pasos a seguir:&lt;/div&gt;
&lt;div&gt;
1.- Crear el proyecto de Visual C# con Windows Forms.&lt;/div&gt;
&lt;div&gt;
2.- Insertar un TextBox.&lt;/div&gt;
&lt;div&gt;
3.- Insertar un Label.&lt;/div&gt;
&lt;div&gt;
4.- Ir a la ventana de Propiedades y presionar el Rayo que son los eventos y allí buscar el evento llamado KeyPress y dar doble clic sobre el espacio en blanco a un lado del nombre.&lt;/div&gt;
&lt;div&gt;
5.- una vez hecho esta nos colocará automaticamente en el código del KeyPress y ponemos el siguiente código:&lt;/div&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;switch(e-&amp;gt;KeyChar)
 {
  case &#39;a&#39;: 
  case &#39;e&#39;: 
  case &#39;i&#39;:
  case &#39;o&#39;:
  case &#39;u&#39;:
   label1-&amp;gt;Text=(&quot;Vocal&quot;);
   break;

  default:
   label1-&amp;gt;Text=(&quot;Consonante&quot;);&lt;/pre&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;   break;
 }
&lt;/pre&gt;
Bueno como veremos tendremos que poner el Switch que es con el que estamos trabajando en este tutorial y luego veremos que hay un texto encerrado entre parentesis así: 
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;(e-&amp;gt;KeyChar)
&lt;/pre&gt;
Esto nos indica que al presionar el textBox1 o al cambiarle el valor cuando este compilando realizará las siguientes acciones &quot;case&quot; las &quot;case&quot; que se presentan son como un If en el cual decimos que si la letra en el TextBox es &quot;a&quot; o la letra es &quot;e&quot; asi hasta la &quot;u&quot; realizará una accion que se describe despues de los Cases bueno despues de la acción que en este caso le decimos que cambie el texto del label1 por &quot;Vocal&quot; va una instrucción llamada &quot;break&quot;, esta instrucción nos sirve para decirle al programa que pare y que siga con la siguiente linea de código si esto no se cumple.
Luego veremos la instrucción &quot;default:&quot; que es la que le decimos como si fuera el ELSE, en esta instrucción decimos que si no se cumplió todo lo anterior es decir que si la letra no es vocal entonces que mande al label el texto de &quot;Consonante&quot;.
No olvidemos siempre terminar nuestras instrucciones con el punto y coma y las correspondientes llaves &quot;{}&quot;.
Y por último así es como debió de quedar todo nuestro código y su respectiva imagen de como quedó el formulario en ejecución.
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace SWITCH_CASE_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void textBox1_KeyPress(object sender, KeyPressEventArgs e)
        {
            
            switch (e.KeyChar)
            {
                case &#39;a&#39;:
                case &#39;e&#39;:
                case &#39;i&#39;:
                case &#39;o&#39;:
                case &#39;u&#39;:
                    label1.Text = &quot;Vocal&quot;;
                    break;
                default:
                    label1.Text = &quot;Consonante&quot;;
                    break;
            }
        }

        
    }
}
&lt;/pre&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQuTEZKUrw8GTfMHhe5Ui4HyLSAcl4oMVUNe82JWyaYdciZRxQuNeVcS-l4U0NOcJFlhQAJZc3VKrjhsEbocMrz-9gPUVzZzLtgS3X10N9WjcIcftsYYMYd32SVnbfax_EY5-6jfE5boY/s1600/vocal+c%252B%252B.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQuTEZKUrw8GTfMHhe5Ui4HyLSAcl4oMVUNe82JWyaYdciZRxQuNeVcS-l4U0NOcJFlhQAJZc3VKrjhsEbocMrz-9gPUVzZzLtgS3X10N9WjcIcftsYYMYd32SVnbfax_EY5-6jfE5boY/s1600/vocal+c%252B%252B.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
Bueno amigos pues esto ha sido todo por el momento y espero que les haya servido de algo este tutorial, nos vemos en la próxima.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/2718999860462132444/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/switch-case.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2718999860462132444'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2718999860462132444'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/switch-case.html' title='Switch Case'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-386226694005059245</id><published>2012-05-19T14:47:00.003-07:00</published><updated>2012-05-19T15:09:42.700-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Ciclo FOR</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/C_Sharp.png&quot; style=&quot;display: none;&quot; /&gt;

Hola y bienvenidos una vez más a mi nuevo tutorial de C#, en este tutorial como mencione en el anterior hablaremos sobre como crear la instrucción FOR en C# usando&amp;nbsp;Windows&amp;nbsp;Forms.&lt;br /&gt;
&lt;div&gt;
Bueno pues comencemos, como ya hemos visto anteriormente como crear el proyecto de Windows Forms ahora crearemos uno llamado CICLO FOR CSHARP bueno&amp;nbsp;pónganle&amp;nbsp;como quieran ustedes pero yo con este nombre trabajaré porque se ajusta al tema, bueno el&amp;nbsp;FOR&amp;nbsp;es una instrucción muy básica y muy usada en los sistemas de información hasta de las grandes empresas y cabe&amp;nbsp;mencionar&amp;nbsp;que la&amp;nbsp;mayoría&amp;nbsp;de los&amp;nbsp;software&amp;nbsp;lo contienen para el ahorro de código y&amp;nbsp;fácil&amp;nbsp;entendimiento del programa.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
Bueno y como siempre les dejo como es la sintaxis del FOR:&lt;/div&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;For ([asignación]; [condición]; [incremento];)
{
[sentencia];
}
&lt;/pre&gt;
&lt;h2&gt;














&lt;span style=&quot;color: #073763;&quot;&gt;Partes

&lt;/span&gt;&lt;/h2&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;asignación&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;
Obligatorio. Puede ir en otra parte del código del programa para ser compartido pero no debe de faltar una constante con u determinado valor.&lt;br /&gt;
Ejemplo [int i = 0];&lt;br /&gt;
&amp;nbsp;&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condición&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Aquí se define que se realizará en el programa.&lt;br /&gt;
Ejemplo : [i &amp;lt;= 10];&lt;br /&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;incremento&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;
Opcional. Aquí definimos si cada vez que se realice un ciclo se hará un incremento o lo dejará como se encuentra originalmente, pero esto ya no tendría caso.&lt;br /&gt;
Ejemplo: [i++];&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;sentencia&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Aquí debe de ir lo que quiere que se realice al momento de realizar el ciclo FOR.&lt;br /&gt;
Ejemplo: [Mandar mensaje por pantalla].&lt;br /&gt;
&lt;br /&gt;
Ahora el ejemplo de este tutorial será el de agregar de uno en uno hasta llegar a 10 pero en cada incremento que mande un mensaje por pantalla indicando el progreso.&lt;br /&gt;
Bueno una vez que tengamos abierto nuestro Visual Studio haremos los siguiente que se explicará paso a paso como en cada tutorial.&lt;br /&gt;
1.- Crear el proyecto FOR.&lt;br /&gt;
2.- Insertar un control del tipo botón.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj23IOo1dlNxCy2n0SiF1teZLujCLkp_mRfo12LqrpqanR6bO6sYwatHZjCJv6qZWQT39LdWBWq5ssdwgAg-5eDpfb02T_NuhXUmvNZF9JgeGpgj-nppJU8B0mI_Cm043JLjL-kIx7_MqE/s1600/3.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj23IOo1dlNxCy2n0SiF1teZLujCLkp_mRfo12LqrpqanR6bO6sYwatHZjCJv6qZWQT39LdWBWq5ssdwgAg-5eDpfb02T_NuhXUmvNZF9JgeGpgj-nppJU8B0mI_Cm043JLjL-kIx7_MqE/s1600/3.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
3.- Dar doble clic sobre él.&lt;br /&gt;
Una vez que ya le hayamos dado doble clic se nos abrirá el modo código y se nos aparecerá esto:&lt;br /&gt;
&lt;div&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace CICLO_FOR_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            
        }
    }
}

&lt;/pre&gt;
&lt;/div&gt;
4.- Una vez que tengamos esto seguramente se nos colocará el Focus del mouse en el area indicada pero bueno si no es así buscan este código dentro de todo el anterior que mayormente esta hasta el final:
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;private void button1_Click(object sender, EventArgs e)
        {
            
        }
&lt;/pre&gt;
5.- Una vez de que ya hayamos encontrado estas lineas de código procederemos a crear el FOR con el siguiente código en el cual estaré explicando como comentarios para que sirve cada parte de dicho código así que pongan atención para que no se pierdan:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt; 
 int i=0 ; //declaramos la constante fuera de nuestro código para poder usarla después si así lo deseamos.
 for(; i&amp;lt;=10;)
/*declaramos comenzamos el FOR y ponemos paréntesis para decir
que irán un conjunto de procesos, donde le decimos al programa
que la constante se omitirá y por eso se puso el punto y coma
solito, despues decimos que verifique si el numero que en este
caso es el &quot;i&quot; si es igual o menor que 10 y si es así que haga la
sentencia que se encuentra mas abajo.*/
 { // abrimos llaves para indicar un proceso de una o mas lineas.
    MessageBox.Show(&quot;Numero = &quot;+i);
/* decimos que mande a pantalla un mensaje con el texto Numero = y le
 sumamos el valor de &quot;i&quot; con una concatenación que así se le llama el cual une dos
 procesos para aparentar uno sólo */
    i++; // aquí ya le decimos que después de enviar el mensaje se le sume una unidad al valor constante de &quot;i&quot;.
 }// terminamos las llaves para indicar el fin del FOR y listo
&lt;/pre&gt;
Otra forma de ponerlo sería así:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt; 
 for(int i=0 ; i&amp;lt;;=10; i++)// aqui ya sería la forma deal donde colocamos todo en una sola lina de código.
 {
    MessageBox::Show(&quot;Numero = &quot;+i);
 }
&lt;/pre&gt;
He aquí una impresión mas de la imagen del formulario ya en ejecución.
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXs57iL-GmqnTzZDAtbF8Vq5430cdzQ81POabmk3xdlvEzUqT5j3EPmvgZFo7a1lWzlA5emySkFs_vnp_6DD81QwSPYwaI_4JcDpJoHGzTJh42TaqmG0JrulPNpcOPvgnQilVnDSS31t8/s1600/1.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXs57iL-GmqnTzZDAtbF8Vq5430cdzQ81POabmk3xdlvEzUqT5j3EPmvgZFo7a1lWzlA5emySkFs_vnp_6DD81QwSPYwaI_4JcDpJoHGzTJh42TaqmG0JrulPNpcOPvgnQilVnDSS31t8/s1600/1.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Y aquí tienen todo el código de como quedó al final:
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace CICLO_FOR_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            for(int i=0 ; i&amp;lt;=10; i++)// aqui ya sería la forma deal donde colocamos todo en una sola lina de código.
             {
                   MessageBox.Show(&quot;Numero = &quot;+i);
             }
        }
    }
}
&lt;/pre&gt;
Bueno como ya hemos visto lo anterior no es necesario explicar esta parte lo único que cambio es que declaramos la constante y le sumamos la unidad desde esta linea que así debería de ser pero bueno cada quien con sus gustos
Y allí tienen la explicación más detallada que le pude dar y espero que la comprendan y si no es así contáctenme y yo con gusto los ayudaré dejen sus comentarios y likes si este tema les fue de ayuda y les gusto si no también háganlo saber para saber en que puedo mejorar.
Hasta la próxima.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/386226694005059245/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-for.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/386226694005059245'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/386226694005059245'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-for.html' title='Ciclo FOR'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj23IOo1dlNxCy2n0SiF1teZLujCLkp_mRfo12LqrpqanR6bO6sYwatHZjCJv6qZWQT39LdWBWq5ssdwgAg-5eDpfb02T_NuhXUmvNZF9JgeGpgj-nppJU8B0mI_Cm043JLjL-kIx7_MqE/s72-c/3.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-8437387665861785795</id><published>2012-05-19T14:39:00.000-07:00</published><updated>2012-05-19T15:09:47.143-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Ciclo While</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/C_Sharp.png&quot; style=&quot;display: none;&quot; /&gt;

Hola de nuevo y bienvenidos a mi nuevo tutorial de C#, en este tutorial les enseñaré a como usar el ciclo While que al iwal que el Ciclo FOR da una vuelta en busca de valores y cosas a realizar no se si me explique bien bueno el caso es que quiero que entiendan de que el ciclo While realiza la misma función que el ciclo FOR pero con algunas diferencias de entrada del código, en este caso las variables se deben de declarar primero y despues se pone lo que se quiera realizar.
Bueno como siempre aquí tienen la sintaxis de este ciclo:&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;[variables] 
while([condición])
{
[sentencias]
[incremento]
}&lt;span style=&quot;color: #0c343d;&quot;&gt;
&lt;/span&gt;&lt;/pre&gt;
&lt;h2&gt;





&lt;span style=&quot;color: #073763;&quot;&gt;Partes&lt;/span&gt;&lt;/h2&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;variables &lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. En este caso colocaremos todas las variables que usaremos en el ciclo while.&lt;br /&gt;
Ejemplo: [int i = 0].&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condición&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. En esta parte colocaremos la condición que necesitamos.&lt;br /&gt;
Ejemplo: [while (i&amp;lt;=10)].&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;sentencias&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. Aquí pondremos lo que queremos que se realice al comenzar el ciclo.&lt;br /&gt;
Ejemplo: [mandar mensaje por pantalla]&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;incremento&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. En esta parte colocaremos el incremento del ciclo como lo que hicimos con el ciclo FOR.&lt;br /&gt;
Ejemplo: [i++].&lt;br /&gt;
&lt;br /&gt;
Ahora el ejemplo de este tutorial será el de agregar de 1 unidad en 1 unidad hasta llegar a 10 pero en cada incremento que mande un mensaje por pantalla indicando el progreso.&lt;br /&gt;
Bueno una vez que tengamos abierto nuestro Visual Studio haremos los siguiente que se explicará paso a paso como en cada tutorial.&lt;br /&gt;
&lt;br /&gt;
1.- Crear el proyecto llamado CICLO WHILE CSHARP.&lt;br /&gt;
2.- Insertar un control del tipo botón.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
3.- Dar doble clic sobre el botón.&lt;br /&gt;
Una vez que ya le hayamos dado doble clic se nos abrirá el modo código y se nos aparecerá esto:&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace CICLO_WHILE_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
        }
    }
}
&lt;/pre&gt;
4.- Una vez que tengamos esto seguramente se nos colocará el Focus del mouse en el area indicada pero bueno si no es así buscan este código dentro de todo el anterior que mayormente esta hasta el final: 
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;private void button1_Click(object sender, EventArgs e)
        {
        }
&lt;/pre&gt;
5.- Una vez de que ya hayamos encontrado estas lineas de código procederemos a crear el ciclo con el siguiente código en el cual estaré explicando con comentarios para que sirve cada parte de dicho código así que pongan atención para que no se pierdan: 
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;int x = 0; //declaramos las variables que vamos a usar en este tutorial
    while (x&amp;lt;=10)/*comenzamos a crear el ciclo while de esta forma como dije
         antes el ciclo while comienza con las palabras while y seguida
         de unos parentesis en los cuales asignamos la condición a realizar  */
     {      //abrimos las llaves  para indicar que dentro de ellas irán las sentencias que usaremos
      MessageBox.Show(&quot;X es igual a : &quot; + x);
      /*Aqui ya estamos en la sentencia en donde decimos que mande un mensaje por pantalla
        diciendo &quot;X es igual a : &quot;  y le decimos que imprimaa un lado el valor de X que 
        se encuentre en estos momentos */
      x++;  //Hacemos el incremento a  la variable 
     }// terminamos el ciclo
&lt;/pre&gt;
Y bueno como este código en realidad es un desastre por los comentarios he aquí el código limpio.
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;int x = 0;   
     while (x&amp;lt;=10)
     {
      MessageBox.Show(&quot;X es igual a : &quot; + x);
      x++;  
     }
&lt;/pre&gt;
Bueno aquí les dejó como debió de quedar todo el código y su imagen para que lo vean en ejecución.
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace CICLO_WHILE_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {

     int x = 0;   
     while (x&amp;lt;=10)
     {
      MessageBox.Show(&quot;X es igual a : &quot; + x);
      x++;  
     }


        }
    }
}
&lt;/pre&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjBRX6M4wPkP-5yLmxdajhSS8Fr32VaIBYRAaLJmmekPriEWK__va90d8M3RaKXMUT6JO2WHMLPkt8a85frahHcgFS86zn55d_bmO_P9h90EfWpxTw3XkbeXiXPhiO8lElM-zrlDMD2Dw/s1600/mm.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjBRX6M4wPkP-5yLmxdajhSS8Fr32VaIBYRAaLJmmekPriEWK__va90d8M3RaKXMUT6JO2WHMLPkt8a85frahHcgFS86zn55d_bmO_P9h90EfWpxTw3XkbeXiXPhiO8lElM-zrlDMD2Dw/s1600/mm.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Bueno pues eso ha sido todo por el momento y espero que les haya servido de algo esperen el proximo tutorial. Si tienen dudas o sugerencias no duden en hacerlas llegar. Y denle like si les gusto el tema.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/8437387665861785795/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-while_19.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/8437387665861785795'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/8437387665861785795'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-while_19.html' title='Ciclo While'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s72-c/form.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-7344009455906610624</id><published>2012-05-19T14:04:00.000-07:00</published><updated>2012-05-19T15:09:14.193-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Instrucción If Else</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/C_Sharp.png&quot; style=&quot;display: none;&quot; /&gt;
Hola y bienvenidos a el nuevo tutorial de C#, en este tutorial les enseñare a como empezar en C# y crear el primer IF ELSE bueno primero antes que nada y como todos mis tutoriales les mostraré cual es la estructura de un IF ELSE en C#.&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;If [ expresión ]
   {
    [ sentencias ];
   }
Else If [ expresión ]
   {
    [ sentencias ];
   }
Else
   { 
    [ sentencias ];
   }
&lt;/pre&gt;
&lt;span style=&quot;color: red;&quot;&gt;Nota :&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #e06666;&quot;&gt;Las llaves sólo son usadas cuando son dos o mas sentencias a ejecutar cuando es sólo una sentencia no es necesario ponerlas &quot;{}&quot;  y cómo hemos dicho anteriormente es necesario poner el punto y coma despues de cada sentencia &quot;;&quot;.&lt;/span&gt;&lt;br /&gt;
&lt;h2&gt;
&lt;span style=&quot;color: #073763;&quot;&gt;Partes que conforman el IF ELSE&lt;/span&gt;&lt;/h2&gt;
&lt;i style=&quot;background-color: white;&quot;&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&amp;nbsp;expresión:&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Expresión. Es la parte en la que decimos que queremos verificar por ejemplo si un número es menor que otro etc. (if num1 &amp;gt; 18)&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&amp;nbsp;sentencias :&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. Una o más instrucciones siguientes If que se ejecutan si la condición se evalúa como True, aquí iran las declaraciones o lo que querramos que se realice si la sentencia resulta ser verdadera.
 else if &lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condition (Condición ELSE IF) :&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. Una o más instrucciones siguientes Else If ... Then que se ejecutan si elseifcondition se evalúa como True, esto nos da a conocer de que si la sentencia ELSE IF resulta ser verdadera o TRUE en ingles entonces realizará una serie de cosas, pero estas declaraciones no son obligatorias si queremos podemos dejar en blanco dichas declaraciones.&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&amp;nbsp;else(Declaraciones ELSE) :&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. Una o más instrucciones que se ejecutan si ninguna condición o la expresión anteriorelseifcondition se evalúa como True, este nos indica que si no se cumplió nada de lo anterior entonces realizará lo que esté despues de esta linea de código.&lt;br /&gt;
&lt;br /&gt;
Bueno ahora procederemos a crear un ejemplo de esta instrucción, el ejemplo que crearemos trata de saber si una persona es o no mayor de edad, bueno en primer lugar seguiremos estos sencillos pasos que como siempre tratare de explicar lo mejor posible:&lt;br /&gt;
1.- Abrimos el visual y creamos un proyecto de C#.&lt;br /&gt;
2.- Ponemos el nombre de IF ELSE.&lt;br /&gt;
3.- Agregamos un control del tipo botón.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
4.- Damos doble clic sobre el botón y veremos el siguiente código.
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace IF_ELSE_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
          
        }
    }
}
&lt;/pre&gt;
5.- Ahora dentro del siguiente código: 
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;private void button1_Click(object sender, EventArgs e)
        {
    
        }
&lt;/pre&gt;
Pondremos esto: 
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;private void button1_Click(object sender, EventArgs e)
        {
            int edad;
            edad = 17;
            if (edad &amp;gt;= 18)
            {
                MessageBox.Show(&quot;Eres mayor de edad&quot;);
            }
            else
                MessageBox.Show(&quot;Eres menor de edad&quot;);
        }
&lt;/pre&gt;
6.- Una vez echo esto así nos debióde quedar el código completo:
&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace IF_ELSE_CSHARP
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            int edad;
            edad = 17;
            if (edad &amp;gt;= 18)
            {
                MessageBox.Show(&quot;Eres mayor de edad&quot;);
            }
            else
                MessageBox.Show(&quot;Eres menor de edad&quot;);
        }
    }
}
&lt;/pre&gt;
Bueno ahora explicaré que pasó, lo único que hicimos fue declarar una variable llamada edad y posteriormente asignarle el valor de 17, luego de esto hacemos el IF diciendo que si la edad es mayor o igual a 18 entonces que mande un mensaje en pantalla diciendo que es mayor de edad y si esto el falso que mande un mensaje en pantalla diciendo que es menor de edad.&lt;br /&gt;
Así es como nos debió de quedar el mensajito por pantalla.
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgGroLCjA3ZjuaBrHAaEIuj5zvpw1TLz3tbOHnJM1pm2akHOhmTv_62ngVmZLJxACvXDlezKZN2esVbHcz0XjHep2ivQNDhY1nKoJHg5lzYM1QBu3CHIdIDo_3TZORdPck0Kpmh7MFPmMs/s1600/menor.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgGroLCjA3ZjuaBrHAaEIuj5zvpw1TLz3tbOHnJM1pm2akHOhmTv_62ngVmZLJxACvXDlezKZN2esVbHcz0XjHep2ivQNDhY1nKoJHg5lzYM1QBu3CHIdIDo_3TZORdPck0Kpmh7MFPmMs/s1600/menor.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Bueno esto es todo por el momento en realidad la instrucción IF ELSE es una de las mas sencillas y espero que la hayan comprendido, si no es así dejen sus comentarios y yo los sacaré de las dudas que tengan.
Y hasta el próximo tutorial.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/7344009455906610624/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-if-else_19.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7344009455906610624'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7344009455906610624'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-if-else_19.html' title='Instrucción If Else'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s72-c/form.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-6341528587508435386</id><published>2012-05-19T12:30:00.000-07:00</published><updated>2012-05-19T15:19:03.125-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Ciclo While</title><content type='html'>&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;
Hola de nuevo y bienvenidos a mi nuevo tutorial de C++, en este tutorial les enseñaré a como usar el ciclo While que al iwal que el Ciclo FOR da una vuelta en busca de valores y cosas a realizar no se si me explique bien bueno el caso es que quiero que entiendan de que el ciclo While realiza la misma función que el ciclo FOR pero con algunas diferencias de entrada del código, en este caso las variables se deben de declarar primero y despues se realiza lo que se quiera realizar.bueno como siempre aquí tienen la sintaxis de este código.&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;[variables]
while([condición])
{
[sentencias]
[incremento]
}
&lt;/pre&gt;
&lt;h2&gt;




&lt;span style=&quot;color: #0c343d;&quot;&gt;Partes&lt;/span&gt;&lt;/h2&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;variables&amp;nbsp;&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;
Obligatorio. En este caso colocaremos todas las variables que usaremos en el ciclo while.&lt;br /&gt;
Ejemplo: [int i = 0].&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condición&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. En esta parte colocaremos la condición que necesitamos.&lt;br /&gt;
Ejemplo: [while (i&amp;lt;=10)].&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;sentencias&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. Aquí pondremos lo que queremos que se realice al comenzar el ciclo.&lt;br /&gt;
Ejemplo: [mandar mensaje por pantalla]&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;incremento&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Opcional. En esta parte colocaremos el incremento del ciclo como lo que hicimos con el ciclo FOR.&lt;br /&gt;
Ejemplo: [i++].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Ahora el ejemplo de este tutorial será el de agregar de 1 unidad en 1 unidad hasta llegar a 10 pero en cada incremento que mande un mensaje por pantalla indicando el progreso.&lt;br /&gt;
Bueno una vez que tengamos abierto nuestro Visual Studio haremos los siguiente que se explicará paso a paso como en cada tutorial.&lt;br /&gt;
1.- Crear el proyecto llamado WHILE.&lt;br /&gt;
2.- Insertar un control del tipo botón.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
3.- Dar doble clic sobre el botón.&lt;br /&gt;
Una vez que ya le hayamos dado doble clic se nos abrirá el modo código y se nos aparecerá esto:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace WHILEC {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;SuspendLayout();
   // 
   // button1
   // 
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(85, 82);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
     }
 };
}
&lt;/pre&gt;
4.- Una vez que tengamos esto seguramente se nos colocará el Focus del mouse en el area indicada pero bueno si no es así buscan este código dentro de todo el anterior que mayormente esta hasta el final:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
     }
&lt;/pre&gt;
5.- Una vez de que ya hayamos encontrado estas lineas de código procederemos a crear el ciclo con el siguiente código en el cual estaré explicando con comentarios para que sirve cada parte de dicho código así que pongan atención para que no se pierdan:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;int x = 0; //declaramos las variables que vamos a usar en este tutorial
    while (x&amp;lt;=10)/*comenzamos a crear el ciclo while de esta forma como dije
         antes el ciclo while comienza con las palabras while y seguida
         de unos parentesis en los cuales asignamos la condición a realizar  */
     {      //abrimos las llaves  para indicar que dentro de ellas irán las sentencias que usaremos
      MessageBox::Show(&quot;X es igual a : &quot; + x);
      /*Aqui ya estamos en la sentencia en donde decimos que mande un mensaje por pantalla
        diciendo &quot;X es igual a : &quot;  y le decimos que imprimaa un lado el valor de X que 
        se encuentre en estos momentos */
      x++;  //Hacemos el incremento a  la variable 
     }// terminamos el ciclo
&lt;/pre&gt;
Y bueno como este código en realidad es un desastre por los comentarios he aquí el código limpio.
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;int x = 0;   
     while (x&amp;lt;=10)
      MessageBox::Show(&quot;X es igual a : &quot; + x);
      x++;  
     }
&lt;/pre&gt;
6.- Compilamos
He aquí una impresión de pantalla de como nos debió de haber quedado ya ejecutando:
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjBRX6M4wPkP-5yLmxdajhSS8Fr32VaIBYRAaLJmmekPriEWK__va90d8M3RaKXMUT6JO2WHMLPkt8a85frahHcgFS86zn55d_bmO_P9h90EfWpxTw3XkbeXiXPhiO8lElM-zrlDMD2Dw/s1600/mm.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjBRX6M4wPkP-5yLmxdajhSS8Fr32VaIBYRAaLJmmekPriEWK__va90d8M3RaKXMUT6JO2WHMLPkt8a85frahHcgFS86zn55d_bmO_P9h90EfWpxTw3XkbeXiXPhiO8lElM-zrlDMD2Dw/s1600/mm.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Bueno pues eso ha sido todo por el momento y espero que les haya servido de algo esperen el proximo tutorial.
Si tienen dudas o sugerencias no duden en hacerlas llegar.
Y denle like si les gusto el tema.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/6341528587508435386/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-while.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6341528587508435386'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6341528587508435386'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/ciclo-while.html' title='Ciclo While'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-135511496061830083</id><published>2012-05-18T23:05:00.000-07:00</published><updated>2012-05-19T11:47:07.496-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Ciclo FOR</title><content type='html'>Hola y bienvenidos una vez más a mi nuevo tutorial de C++, en este tutorial como mencione en el anterior hablaremos sobre como crear la instrucción FOR en C++ usando&amp;nbsp;Windows&amp;nbsp;Forms&amp;nbsp;no consola ya que bueno yo me estoy especializando en&amp;nbsp;Windows&amp;nbsp;Forms&amp;nbsp;y lo veo más&amp;nbsp;cómodo&amp;nbsp;de usar y para enseñarles pero es bueno saber un poco de consola igual ya si desean me dicen y les hago unos tutos usando consola.&lt;img atyle=&quot;display:none;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;&lt;br /&gt;
&lt;div&gt;
Bueno pues comencemos, como ya hemos visto anteriormente como crear el proyecto de Windows Forms ahora crearemos uno llamado FOR bueno&amp;nbsp;pónganle&amp;nbsp;como quieran ustedes pero yo con este nombre trabajaré porque se ajusta al tema, bueno el&amp;nbsp;FOR&amp;nbsp;es una instrucción muy básica y muy usada en los sistemas de información hasta de las grandes empresas y cabe&amp;nbsp;mencionar&amp;nbsp;que la&amp;nbsp;mayoría&amp;nbsp;de los&amp;nbsp;software&amp;nbsp;lo contienen para el ahorro de código y&amp;nbsp;fácil&amp;nbsp;entendimiento del programa.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
Bueno y como siempre les dejo como es la sintaxis del FOR:&lt;/div&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;For ([asignación]; [condición]; [incremento];)
{
[sentencia];
}
&lt;/pre&gt;
&lt;h2&gt;











&lt;span style=&quot;color: #073763;&quot;&gt;Partes

&lt;/span&gt;&lt;/h2&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;asignación&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;
Obligatorio. Puede ir en otra parte del código del programa para ser compartido pero no debe de faltar una constante con u determinado valor.&lt;br /&gt;
Ejemplo [int i = 0];&lt;br /&gt;
&amp;nbsp;&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condición&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Aquí se define que se realizará en el programa.&lt;br /&gt;
Ejemplo : [i &amp;lt;= 10];&lt;br /&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;incremento&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;
Opcional. Aquí definimos si cada vez que se realice un ciclo se hará un incremento o lo dejará como se encuentra originalmente, pero esto ya no tendría caso.&lt;br /&gt;
Ejemplo: [i++];&lt;br /&gt;
&lt;i&gt;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;sentencia&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Aquí debe de ir lo que quiere que se realice al momento de realizar el ciclo FOR.&lt;br /&gt;
Ejemplo: [Mandar mensaje por pantalla].&lt;br /&gt;
&lt;br /&gt;
Ahora el ejemplo de este tutorial será el de agregar de uno en uno hasta llegar a 10 pero en cada incremento que mande un mensaje por pantalla indicando el progreso.&lt;br /&gt;
Bueno una vez que tengamos abierto nuestro Visual Studio haremos los siguiente que se explicará paso a paso como en cada tutorial.&lt;br /&gt;
1.- Crear el proyecto FOR.&lt;br /&gt;
2.- Insertar un control del tipo botón.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj23IOo1dlNxCy2n0SiF1teZLujCLkp_mRfo12LqrpqanR6bO6sYwatHZjCJv6qZWQT39LdWBWq5ssdwgAg-5eDpfb02T_NuhXUmvNZF9JgeGpgj-nppJU8B0mI_Cm043JLjL-kIx7_MqE/s1600/3.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj23IOo1dlNxCy2n0SiF1teZLujCLkp_mRfo12LqrpqanR6bO6sYwatHZjCJv6qZWQT39LdWBWq5ssdwgAg-5eDpfb02T_NuhXUmvNZF9JgeGpgj-nppJU8B0mI_Cm043JLjL-kIx7_MqE/s1600/3.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
3.- Dar doble clic sobre él.&lt;br /&gt;
Una vez que ya le hayamos dado doble clic se nos abrirá el modo código y se nos aparecerá esto:&lt;br /&gt;
&lt;div&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace FOR {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;SuspendLayout();
   // 
   // button1
   // 
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(83, 94);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
                           }
 };
}
&lt;/pre&gt;
&lt;/div&gt;
4.- Una vez que tengamos esto seguramente se nos colocará el Focus del mouse en el area indicada pero bueno si no es así buscan este código dentro de todo el anterior que mayormente esta hasta el final:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
                   }
&lt;/pre&gt;
5.- Una vez de que ya hayamos encontrado estas lineas de código procederemos a crear el FOR con el siguiente código en el cual estaré explicando como comentarios para que sirve cada parte de dicho código así que pongan atención para que no se pierdan:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt; 
 int i=0 ; //declaramos la constante fuera de nuestro código para poder usarla después si así lo deseamos.
 for(; i&amp;lt;=10;)
/*declaramos comenzamos el FOR y ponemos paréntesis para decir
que irán un conjunto de procesos, donde le decimos al programa
que la constante se omitirá y por eso se puso el punto y coma
solito, despues decimos que verifique si el numero que en este
caso es el &quot;i&quot; si es igual o menor que 10 y si es así que haga la
sentencia que se encuentra mas abajo.*/
 { // abrimos llaves para indicar un proceso de una o mas lineas.
    MessageBox::Show(&quot;Numero = &quot;+i);
/* decimos que mande a pantalla un mensaje con el texto Numero = y le
 sumamos el valor de &quot;i&quot; con una concatenación que así se le llama el cual une dos
 procesos para aparentar uno sólo */
    i++; // aquí ya le decimos que después de enviar el mensaje se le sume una unidad al valor constante de &quot;i&quot;.
 }// terminamos las llaves para indicar el fin del FOR y listo
&lt;/pre&gt;
Otra forma de ponerlo sería así:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt; 
 for(int i=0 ; i&amp;lt;;=10; i++)// aqui ya sería la forma deal donde colocamos todo en una sola lina de código.
 {
    MessageBox::Show(&quot;Numero = &quot;+i);
 }
&lt;/pre&gt;
He aquí una impresión mas de la imagen del formulario ya en ejecución.
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXs57iL-GmqnTzZDAtbF8Vq5430cdzQ81POabmk3xdlvEzUqT5j3EPmvgZFo7a1lWzlA5emySkFs_vnp_6DD81QwSPYwaI_4JcDpJoHGzTJh42TaqmG0JrulPNpcOPvgnQilVnDSS31t8/s1600/1.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXs57iL-GmqnTzZDAtbF8Vq5430cdzQ81POabmk3xdlvEzUqT5j3EPmvgZFo7a1lWzlA5emySkFs_vnp_6DD81QwSPYwaI_4JcDpJoHGzTJh42TaqmG0JrulPNpcOPvgnQilVnDSS31t8/s1600/1.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Bueno como ya hemos visto lo anterior no es necesario explicar esta parte lo único que cambio es que declaramos la constante y le sumamos la unidad desde esta linea que así debería de ser pero bueno cada quien con sus gustos
Y allí tienen la explicación más detallada que le pude dar y espero que la comprendan y si no es así contáctenme y yo con gusto los ayudaré dejen sus comentarios y likes si este tema les fue de ayuda y les gusto si no también háganlo saber para saber en que puedo mejorar.
Hasta la próxima.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/135511496061830083/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-for.html#comment-form' title='2 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/135511496061830083'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/135511496061830083'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-for.html' title='Ciclo FOR'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-7869444227911989343</id><published>2012-05-16T09:33:00.001-07:00</published><updated>2012-05-16T09:39:14.248-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Instrucción Switch Case</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s1600/Visual_C%252B%252B_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Las instrucciones Switch Case son un sustituto por mucho tiempo si las declaraciones que comparan una variable para varios valores de &quot;integrales&quot; (&quot;integral&quot; los valores son simplemente los valores que se pueden expresar como un número entero, como el valor de un char). El formato básico para el uso de Switch Case se describe a continuación. El valor de la variable dada en el interruptor se compara con el valor después de cada uno de los casos, y cuando un valor coincide con el valor de la variable, el ordenador continúa ejecutando el programa desde ese punto.&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;switch ( &lt;variable&gt; ) {
case this-value:
  //Código a ejecutar si la sentencia es verdadera.&lt;variable&gt;
  //break;
case that-value:
  //Código a ejecutar si la sentencia es verdadera.
  //break;
...
default:
  //Código a ejecutar si las sentencias anteriores no se cumplen.
  //break;
}
&lt;/pre&gt;
&lt;h3&gt;





DEV C++&amp;nbsp;&lt;/h3&gt;
La condición de una instrucción switch es un valor. El caso, dice que si tiene el valor de lo que sea después de ese caso, entonces no lo sigue el de colon. La ruptura se utiliza para salir de las sentencias case. Break es una palabra clave que sale de un bloque de código, generalmente rodeadas por llaves, que es encuentra, en este caso, ruptura impide que el programa de caer a través y ejecutar el código en todas las declaraciones de otros casos. Una cosa importante a tener en cuenta sobre la sentencia switch es que los valores caso sólo podrá ser constantes expresiones integrales. Lamentablemente, no es legal usar el caso como éste:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;int a = 10;
int b = 10;
int c = 20;

switch ( a ) {
case b:
  // Code
  break;
case c:
  // Code
  break;
default:
  // Code
  break;
}
&lt;/pre&gt;
El caso por defecto es opcional, pero es conveniente incluirlo ya que maneja todos los casos inesperados. Instrucciones Switch Case sirven como una forma sencilla de escribir mucho si las declaraciones cuando se cumplen los requisitos. A menudo se puede utilizar para procesar la entrada de un usuario.

Bueno ahora un pequeño ejemplo del Switch Case:

Si una expresión coincidente, el control no esté impedido por caso, posterior o etiquetas predeterminadas. La sentencia break se utiliza para detener la ejecución y transferir el control a la instrucción después de la sentencia switch. Sin una instrucción break, cada palabra de la etiqueta caso coincide con el extremo del interruptor, incluyendo el valor predeterminado, se ejecuta. Por ejemplo:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;// switch_statement1.cpp
#include &lt;stdio.h&gt;

int main() {
   char *buffer = &quot;Any character stream&quot;;
   int capa, lettera, nota;
   char c;
   capa = lettera = nota = 0;

   while ( c = *buffer++ )   // Walks buffer until NULL
   {
      switch ( c )
      {
         case &#39;A&#39;:
            capa++;
            break;
         case &#39;a&#39;:
            lettera++;
            break;
         default:
            nota++;
      }
   }
   printf_s( &quot;\nUppercase a: %d\nLowercase a: %d\nTotal: %d\n&quot;,
      capa, lettera, (capa + lettera + nota) );
}
&lt;/stdio.h&gt;&lt;/pre&gt;
En el ejemplo anterior, Capa se incrementa si c es una mayúscula A. La sentencia Break después de la Capa + + termina la ejecución del cuerpo de la instrucción switch y el control pasa al bucle While. Sin la sentencia Break, lettera nota y también se incrementa. Un objetivo similar es servida por la sentencia Break para el caso de la &#39;a&#39;. Si c es una minúscula, lettera se incrementa y la sentencia break termina el cuerpo de la instrucción Switch. Si c no es una A o A, la declaración por defecto se ejecuta.

Un bloque interior de una instrucción switch puede contener definiciones con inicializaciones, siempre que son alcanzables - es decir, sin anular por todos los caminos de ejecución posibles. Los nombres introducidos con estas declaraciones tienen un ámbito local. Por ejemplo:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;// switch_statement2.cpp
// C2360 expected
#include &lt;iostream&gt;
using namespace std;
int main(int argc, char *argv[])
{
   switch( tolower( *argv[1] ) )
   {
       // Error. Unreachable declaration.
       char szChEntered[] = &quot;Character entered was: &quot;;
   
   case &#39;a&#39; :
       {
       // Declaration of szChEntered OK. Local scope.
       char szChEntered[] = &quot;Character entered was: &quot;;
       cout &amp;lt;&amp;lt; szChEntered &amp;lt;&amp;lt; &quot;a\n&quot;;
       }
       break;
   
   case &#39;b&#39; :
       // Value of szChEntered undefined.
       cout &amp;lt;&amp;lt; szChEntered &amp;lt;&amp;lt; &quot;b\n&quot;;
       break;
   
   default:
       // Value of szChEntered undefined.
       cout &amp;lt;&amp;lt; szChEntered &amp;lt;&amp;lt; &quot;neither a nor b\n&quot;;
       break;
   }
}
&lt;/iostream&gt;&lt;/pre&gt;
Una sentencia switch se pueden anidar. En tales casos, las etiquetas de caso o por defecto a la declaración más cercano interruptor que les rodea.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;





Visual C++ con Windows Forms:&lt;/h3&gt;
&lt;div&gt;
Bueno como en todos mis tutoriales de Windows Forms tengo que explicar paso a paso aquí estan los pasos a seguir:&lt;/div&gt;
&lt;div&gt;
1.- Crear el proyecto de Visual C++ con Windows Forms.&lt;/div&gt;
&lt;div&gt;
2.- Insertar un TextBox.&lt;/div&gt;
&lt;div&gt;
3.- Insertar un Label.&lt;/div&gt;
&lt;div&gt;
4.- Ir a la ventana de Propiedades y presionar el Rayo que son los eventos y allí buscar el evento llamado KeyPress y dar doble clic sobre el espacio en blanco a un lado del nombre.&lt;/div&gt;
&lt;div&gt;
5.- una vez hecho esta nos colocará automaticamente en el código del KeyPress y ponemos el siguiente código:&lt;/div&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;switch(e-&amp;gt;KeyChar)
 {
  case &#39;a&#39;: 
  case &#39;e&#39;: 
  case &#39;i&#39;:
  case &#39;o&#39;:
  case &#39;u&#39;:
   label1-&amp;gt;Text=(&quot;Vocal&quot;);
   break;

  default:
   label1-&amp;gt;Text=(&quot;Consonante&quot;);
 }
&lt;/pre&gt;
Bueno como veremos tendremos que poner el Switch que es con el que estamos trabajando en este tutorial y luego veremos que hay un texto encerrado entre parentesis así: 
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;(e-&amp;gt;KeyChar)
&lt;/pre&gt;
Esto nos indica que al presionar el textBox1 o al cambiarle el valor cuando este compilando realizará las siguientes acciones &quot;case&quot; las &quot;case&quot; que se presentan son como un If en el cual decimos que si la letra en el TextBox es &quot;a&quot; o la letra es &quot;e&quot; asi hasta la &quot;u&quot; realizará una accion que se describe despues de los Cases bueno despues de la acción que en este caso le decimos que cambie el texto del label1 por &quot;Vocal&quot; va una instrucción llamada &quot;break&quot;, esta instrucción nos sirve para decirle al programa que pare y que siga con la siguiente linea de código si esto no se cumple.
Luego veremos la instrucción &quot;default:&quot; que es la que le decimos como si fuera el ELSE, en esta instrucción decimos que si no se cumplió todo lo anterior es decir que si la letra no es vocal entonces que mande al label el texto de &quot;Consonante&quot;.
No olvidemos siempre terminar nuestras instrucciones con el punto y coma y las correspondientes llaves &quot;{}&quot;.
Y por último así es como debió de quedar todo nuestro código y su respectiva imagen de como quedó el formulario en ejecución.
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace SWITCHCASE {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }

 private: System::Windows::Forms::TextBox^  textBox1;
 private: System::Windows::Forms::Label^  label1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;textBox1 = (gcnew System::Windows::Forms::TextBox());
   this-&amp;gt;label1 = (gcnew System::Windows::Forms::Label());
   this-&amp;gt;SuspendLayout();
   // 
   // textBox1
   // 
   this-&amp;gt;textBox1-&amp;gt;Location = System::Drawing::Point(85, 90);
   this-&amp;gt;textBox1-&amp;gt;Name = L&quot;textBox1&quot;;
   this-&amp;gt;textBox1-&amp;gt;Size = System::Drawing::Size(100, 20);
   this-&amp;gt;textBox1-&amp;gt;TabIndex = 1;
   this-&amp;gt;textBox1-&amp;gt;KeyPress += gcnew System::Windows::Forms::KeyPressEventHandler(this, &amp;amp;Form1::textBox1_KeyPress);
   // 
   // label1
   // 
   this-&amp;gt;label1-&amp;gt;AutoSize = true;
   this-&amp;gt;label1-&amp;gt;Location = System::Drawing::Point(113, 129);
   this-&amp;gt;label1-&amp;gt;Name = L&quot;label1&quot;;
   this-&amp;gt;label1-&amp;gt;Size = System::Drawing::Size(35, 13);
   this-&amp;gt;label1-&amp;gt;TabIndex = 2;
   this-&amp;gt;label1-&amp;gt;Text = L&quot;label1&quot;;
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;label1);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;textBox1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);
   this-&amp;gt;PerformLayout();

  }
#pragma endregion
 private: System::Void textBox1_KeyPress(System::Object^  sender, System::Windows::Forms::KeyPressEventArgs^  e) {
 switch(e-&amp;gt;KeyChar)
 {
  case &#39;a&#39;: 
  case &#39;e&#39;: 
  case &#39;i&#39;:
  case &#39;o&#39;:
  case &#39;u&#39;:
   label1-&amp;gt;Text=(&quot;Vocal&quot;);
   break;

  default:
   label1-&amp;gt;Text=(&quot;Consonante&quot;);
 }
    }
 };
}
&lt;/pre&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQuTEZKUrw8GTfMHhe5Ui4HyLSAcl4oMVUNe82JWyaYdciZRxQuNeVcS-l4U0NOcJFlhQAJZc3VKrjhsEbocMrz-9gPUVzZzLtgS3X10N9WjcIcftsYYMYd32SVnbfax_EY5-6jfE5boY/s1600/vocal+c%252B%252B.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQuTEZKUrw8GTfMHhe5Ui4HyLSAcl4oMVUNe82JWyaYdciZRxQuNeVcS-l4U0NOcJFlhQAJZc3VKrjhsEbocMrz-9gPUVzZzLtgS3X10N9WjcIcftsYYMYd32SVnbfax_EY5-6jfE5boY/s1600/vocal+c%252B%252B.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
Bueno amigos pues esto ha sido todo por el momento y espero que les haya servido de algo este tutorial, nos vemos en la próxima.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/7869444227911989343/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-switch-case.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7869444227911989343'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7869444227911989343'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-switch-case.html' title='Instrucción Switch Case'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgzdg5Bick6-s6OwGlkf-eXxHV9ZUvGV8kjPKRwKzG-qA9LuhsxXXPppQ1mmwfRFG3aqzNTUadG98uAQnc9E-rxzX-qRWWi117eQ7WTgzxglinMuqjNyIsvUonMeaI43056P6ZPRw-eqTg/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-816812590547385460</id><published>2012-05-15T22:06:00.000-07:00</published><updated>2012-05-15T22:23:28.615-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Instrucción If Else</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Hola y bienvenidos a el nuevo tutorial de C++, en este tutorial les enseñare a como empezar en C++ y crear el primer IF ELSE en C++ bueno primero antes que nada y como todos mis tutoriales les mostraré cual es la estructura de un IF ELSE en C++&lt;br /&gt;
&lt;pre class=&quot;brush:cpp &quot;&gt;If [ expresión ]
   {
    [ sentencias ];
   }
Else If [ expresión ]
   {
    [ sentencias ];
   }
Else
   { 
    [ sentencias ];
   }
&lt;/pre&gt;
&lt;div style=&quot;color: red;&quot;&gt;
Nota :&lt;/div&gt;
&lt;div style=&quot;color: red;&quot;&gt;
&lt;span style=&quot;color: #f4cccc;&quot;&gt;&lt;span style=&quot;color: #e06666;&quot;&gt;Las llaves sólo son usadas cuando son dos o mas sentencias a ejecutar cuando es sólo una sentencia no es necesario ponerlas &quot;{}&quot;&amp;nbsp; y cómo hemos dicho anteriormente es necesario poner el punto y coma despues de cada sentencia &quot;&lt;/span&gt;;&quot;.&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: red;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: white; color: #6fa8dc; font-family: &#39;PT Sans Narrow&#39;, &#39;Trebuchet MS&#39;, Arial, Verdana; font-size: 24px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 1.2em; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 0px; orphans: 2; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;













&lt;span style=&quot;color: #0b5394;&quot;&gt;Partes que conforman el IF ELSE&lt;/span&gt;&lt;/h3&gt;
&lt;i&gt;&lt;span style=&quot;background-color: white; color: #6fa8dc; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;expresión:&lt;/span&gt;&lt;/i&gt;&lt;br /&gt;
Obligatorio. Expresión. Es la parte en la que decimos que queremos verificar por ejemplo si un número es menor que otro etc. (if num1 &amp;gt; 18)&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #444444; display: inline ! important; float: none; font-family: Arial,Tahoma,Verdana; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #6fa8dc; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #6fa8dc; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;sentencias :&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
Opcional. Una o más instrucciones siguientes If que se ejecutan si la condición se evalúa como True, aquí iran las declaraciones o lo que querramos que se realice si la sentencia resulta ser verdadera.&lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #444444; display: inline ! important; float: none; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #6fa8dc; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;else if condition (Condición ELSE IF) :&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
Opcional. Una o más instrucciones siguientes Else If ... Then que se ejecutan si elseifcondition se evalúa como True, esto nos da a conocer de que si la sentencia ELSE IF resulta ser verdadera o TRUE en ingles entonces realizará una serie de cosas, pero estas declaraciones no son obligatorias si queremos podemos dejar en blanco dichas declaraciones. &lt;br /&gt;
&lt;span style=&quot;background-color: white; color: #3d85c6; font-family: Arial,Tahoma,Verdana; font-size: small; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 18px; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;&amp;nbsp;else(Declaraciones ELSE) :&lt;span class=&quot;Apple-converted-space&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
Opcional. Una o más instrucciones que se ejecutan si ninguna condición o la expresión anteriorelseifcondition se evalúa como True, este nos indica que si no se cumplió nada de lo anterior entonces realizará lo que esté despues de esta linea de código.&lt;br /&gt;
Bueno ahora procederemos a crear un ejemplo de esta instrucción, el ejemplo que crearemos trata de saber si una persona es o no mayor de edad, bueno en primer lugar seguiremos estos sencillos pasos que como siempre tratare de explicar lo mejor posible:&lt;br /&gt;
1.- Abrimos el visual y creamos un proyecto de C++.&lt;br /&gt;
2.- Ponemos el nombre de IF ELSE.&lt;br /&gt;
3.- Agregamos un botón.&lt;br /&gt;
4.- Damos doble clic sobre el botón y veremos el siguiente código.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once
#pragma once

namespace IFELSE {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;
 private: System::Windows::Forms::TextBox^  textBox1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;textBox1 = (gcnew System::Windows::Forms::TextBox());
   this-&amp;gt;SuspendLayout();
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(102, 103);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   this-&amp;gt;textBox1-&amp;gt;Location = System::Drawing::Point(89, 77);
   this-&amp;gt;textBox1-&amp;gt;Name = L&quot;textBox1&quot;;
   this-&amp;gt;textBox1-&amp;gt;Size = System::Drawing::Size(100, 20);
   this-&amp;gt;textBox1-&amp;gt;TabIndex = 1;
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;textBox1);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);
   this-&amp;gt;PerformLayout();

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
     
    }
 };
}
&lt;/pre&gt;
6.- Ahora dentro del siguiente código:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
    }
&lt;/pre&gt;
Pondremos esto:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;int edad;
edad = 18;
if (edad &amp;gt;=18)
MessageBox::Show(&quot;Eres mayor de edad&quot;, &quot;Mensaje&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);
else
MessageBox::Show(&quot;Eres menor de edad&quot;, &quot;Mensaje&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);
&lt;/pre&gt;
7.- Una vez echo esto así nos debióde quedar el código completo:&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace IFELSE {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;

 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;SuspendLayout();
   // 
   // button1
   // 
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(102, 103);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
     int edad;
     edad = 18;
     if (edad &amp;gt;=18)
      MessageBox::Show(&quot;Eres mayor de edad&quot;, &quot;Mensaje&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);
     else
      MessageBox::Show(&quot;Eres menor de edad&quot;, &quot;Mensaje&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);
    }
 };
}
&lt;/pre&gt;
Bueno ahora explicaré que pasó, lo único que hicimos fue declarar una variable llamada edad y posteriormente asignarle el valor de 18, luego de esto hacemos el IF diciendo que si la edad es mayor o igual a 18 entonces que mande un mensaje en pantalla diciendo que es mayor de edad y si esto el falso que mande un mensaje en pantalla diciendo que es menor de edad.&lt;br /&gt;
Así es como nos debió de quedar el mensajito por pantalla.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZFSz3FLRgFSHEIsGBU5WlTwKYqpC88ry8J-q3n94S4OPmz-tpXIFenY2C3lfx25WDs6VzgU9-S-fqBkbJJ2SFfHBIQMhzopFh3n2aSzoDIXceI3egL3fEW0NsnAMsJI_IDyWqHsaeNdo/s1600/cas.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjZFSz3FLRgFSHEIsGBU5WlTwKYqpC88ry8J-q3n94S4OPmz-tpXIFenY2C3lfx25WDs6VzgU9-S-fqBkbJJ2SFfHBIQMhzopFh3n2aSzoDIXceI3egL3fEW0NsnAMsJI_IDyWqHsaeNdo/s1600/cas.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;br /&gt;
Bueno esto es todo por el momento en realidad la instrucción IF ELSE es una de las mas sencillas y espero que la hayan comprendido, si no es así dejen sus comentarios y yo los sacaré de las dudas que tengan.&lt;br /&gt;
Y hasta el próximo tutorial.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/816812590547385460/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-if-else.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/816812590547385460'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/816812590547385460'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-if-else.html' title='Instrucción If Else'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-6847554428644517972</id><published>2012-05-15T19:14:00.002-07:00</published><updated>2012-05-15T19:14:57.399-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>While...End While</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; style=&quot;display: none;&quot; /&gt;
&amp;nbsp;Bueno en éste tutorial como dijimos en el anterior hablaremos sobre como usar el ciclo While...End While y como en todos mis tutoriales primero les dejo como esta conformado el ciclo o como es el cuerpo como le dicen muchos, bueno esta conformado de la siguiente manera:&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;While condition
    [ statements ]
    [ Exit While ]
    [ statements ]
End While
&lt;/pre&gt;
&lt;h3 style=&quot;color: #6fa8dc;&quot;&gt;



Partes:
&lt;/h3&gt;
&lt;div style=&quot;background-color: #999999; width: 600px;&quot;&gt;
&lt;table&gt;
    &lt;tbody&gt;
&lt;tr&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot; width=&quot;63&quot;&gt;&lt;span data-guid=&quot;b4dad0fe5fbef2c0e24d9db1cc69e5a2&quot; data-source=&quot;Term&quot; id=&quot;mt2&quot;&gt;Término&lt;/span&gt;&lt;/td&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot; width=&quot;576&quot;&gt;&lt;span data-guid=&quot;30618b3b44fa316257d07e387759fae5&quot; data-source=&quot;Definition&quot; id=&quot;mt3&quot;&gt;Definición&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
&lt;tr&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot;&gt;condition&lt;/td&gt;
        &lt;td bgcolor=&quot;#FFFFFF&quot;&gt;&lt;span data-guid=&quot;50edf5403c0e270490508221b859330b&quot; data-source=&quot;Required.&quot; id=&quot;mt4&quot;&gt;Obligatorio.&lt;/span&gt;&amp;nbsp;&lt;span data-guid=&quot;db1e81d2112f771b0d4d7d780810e569&quot; data-source=&quot;&amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;Boolean&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt; expression.&quot; id=&quot;mt5&quot;&gt;Expresión&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;Boolean&lt;/span&gt;.&lt;/span&gt;&amp;nbsp;&lt;span data-guid=&quot;d6e88c30c574779f655ad2f3f206571f&quot; data-source=&quot;If &amp;lt;span class=&#39;parameter&#39;&amp;gt;condition&amp;lt;/span&amp;gt; is &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;Nothing&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;, Visual Basic treats it as &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;False&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;.&quot; id=&quot;mt6&quot;&gt;Si&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;condition&lt;/span&gt;&amp;nbsp;es&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;Nothing&lt;/span&gt;, Visual Basic la trata como&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;False&lt;/span&gt;.&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
&lt;tr&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot;&gt;statements&lt;/td&gt;
        &lt;td bgcolor=&quot;#FFFFFF&quot;&gt;&lt;span data-guid=&quot;16c952cba827b0f636670d0a0b4b6619&quot; data-source=&quot;Optional.&quot; id=&quot;mt7&quot;&gt;Opcional.&lt;/span&gt;&amp;nbsp;&lt;span data-guid=&quot;5d039dc0e5987a38d5fdeecdca0b29c7&quot; data-source=&quot;One or more statements following &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;While&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;, which run every time &amp;lt;span class=&#39;parameter&#39;&amp;gt;condition&amp;lt;/span&amp;gt; is &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;True&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;.&quot; id=&quot;mt8&quot;&gt;Una o más instrucciones a continuación de&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;While&lt;/span&gt;, que se ejecutan cada vez que&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;condition&lt;/span&gt;&amp;nbsp;es&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;True&lt;/span&gt;.&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
&lt;tr&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot;&gt;Exit While&lt;/td&gt;
        &lt;td bgcolor=&quot;#FFFFFF&quot;&gt;&lt;span data-guid=&quot;16c952cba827b0f636670d0a0b4b6619&quot; data-source=&quot;Optional.&quot; id=&quot;mt9&quot;&gt;Opcional.&lt;/span&gt;&amp;nbsp;&lt;span data-guid=&quot;8520c17a244e28aeaab186a519f3c895&quot; data-source=&quot;Transfers control out of the &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;While&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt; block.&quot; id=&quot;mt10&quot;&gt;Transfiere el control fuera del bloque&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;While&lt;/span&gt;.&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
&lt;tr&gt;
        &lt;td bgcolor=&quot;#CCCCCC&quot;&gt;End While&lt;/td&gt;
        &lt;td bgcolor=&quot;#FFFFFF&quot;&gt;&lt;span data-guid=&quot;50edf5403c0e270490508221b859330b&quot; data-source=&quot;Required.&quot; id=&quot;mt11&quot;&gt;Obligatorio.&lt;/span&gt;&amp;nbsp;&lt;span data-guid=&quot;f3be4d5ee8c6caaca590d3da94860d09&quot; data-source=&quot;Terminates the definition of the &amp;lt;span&amp;gt;&amp;lt;span class=&#39;input&#39;&amp;gt;While&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt; block.&quot; id=&quot;mt12&quot;&gt;Termina la definición del bloque&amp;nbsp;&lt;span xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;While&lt;/span&gt;.&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
&lt;/tbody&gt;
  &lt;/table&gt;
&lt;/div&gt;
La estructura While...End While la usamos si deseamos repetir un conjunto de instrucciones un número indefinido de veces, siempre que una condición sea verdadera(True).&lt;br /&gt;
&lt;br /&gt;
Si la condition es True, se ejecutan todas las statements hasta que se encuentra la instrucción End While Después, el control vuelve a la instrucción While y se comprueba de nuevo condition. Si condition aún es True, se repite el proceso. Si es False, el control pasa a la instrucción que sigue a la instrucción End While.&lt;br /&gt;
&lt;h3&gt;


&amp;nbsp;Ejemplo : &lt;/h3&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Dim countador As Integer = 0
While countador &amp;lt; 20
    countador += 1
End While
MsgBox(&quot;El blucle while hizo &quot; &amp;amp; CStr(countador) &amp;amp; &quot; vueltas&quot;)
&lt;/pre&gt;
&lt;br /&gt;
Bueno este es un pequeño ejemplo, uno de los mas sencillos y uno de los mas faciles de entender espero que lo hayan comprendido en realidad lo único que hace es crear un contador al cual se le asigna el valor de 0 y de alli agarra y le dice que cree el ciclo que mientras el contador sea menor a 20 se le agregará una unidad mas al contador es decir que en la primera vuelta el contador será de 0 y en la segunda su valor será 1 y asi hasta llegar a los 20 y cuando pase esto se mandará un mensaje en pantalla diciendo &quot;El bucle while hizo 20 vueltas.
Bueno hasta aquí lo dejaré por el momento no olviden comentar si algo no les quedó muy claro.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/6847554428644517972/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/whileend-while.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6847554428644517972'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6847554428644517972'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/whileend-while.html' title='While...End While'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-1633049045438651101</id><published>2012-05-15T17:02:00.001-07:00</published><updated>2012-05-15T18:01:23.745-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>Instrucción For Each...Next</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; style=&quot;display: none;&quot; /&gt;
Hola de nuevo amigos, bueno en este tutorial les enseñare a como usar la intrucción For Each...Next en Visual Basic, espero que no se desesperen sólo porque sólo ando subiendo tutoriales de Visual Basic .Net lo que pasa es que primero me encargare de subor por lo menos unos 10 temas de Visual Basic, Luego seguirá Visual C++ y por último subiré de C# pero si tengo algun tiempo disponible subiré del que más rapido se me venga a la mente un tema, espero que comprendan que trabajo sólo y por eso no puedo subir mas de 100 tutoriales en un día sólo eso si prometo que diariamente habrán unos 3 tutoriales.&lt;br /&gt;
Bueno continuando con el tutorial de For Each...Next les presentaré como se conforma el cuerpo de un For Each...Next, bueno la estructura es la siguiente :&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;For Each element [ As datatype ] In group
    [ statements ]
    [ Exit For ]
    [ statements ]
Next [ element ]&lt;/pre&gt;
&lt;h2 style=&quot;color: #6fa8dc;&quot;&gt;
Partes&lt;/h2&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;element&lt;/span&gt;&lt;/span&gt;&lt;/dt&gt;
&lt;dd&gt;Se requiere en la instrucción&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;For Each&lt;/b&gt;. Es opcional en la instrucción&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;Next&lt;/b&gt;. Variable. Se utiliza para recorrer en iteración los elementos de la colección.&lt;/dd&gt;&lt;/dl&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;datatype&lt;/span&gt;&lt;/span&gt;&lt;/dt&gt;
&lt;dd&gt;Es obligatorio, a menos que&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;element&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;no se haya declarado ya. Tipo de datos de&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;element&lt;/span&gt;.&lt;/dd&gt;&lt;/dl&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;group&lt;/span&gt;&lt;/span&gt;&lt;/dt&gt;
&lt;dd&gt;Obligatorio. Variable de objeto. Hace referencia a la colección sobre la que se debe repetir la ejecución de&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;statements&lt;/span&gt;.&lt;/dd&gt;&lt;/dl&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;statements&lt;/span&gt;&lt;/span&gt;&lt;/dt&gt;
&lt;dd&gt;Opcional. Una o más instrucciones entre&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;For Each&lt;/b&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;y&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;Next&lt;/b&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;que se ejecutan en cada elemento de&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;parameter&quot; style=&quot;font-family: Verdana,Arial,Helvetica,sans-serif; font-size: 13px; font-style: italic; margin: 0px;&quot;&gt;group&lt;/span&gt;.&lt;/dd&gt;&lt;/dl&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;Exit For&lt;/span&gt;&lt;/i&gt;&lt;/dt&gt;
&lt;dd&gt;Opcional. Transfiere el control fuera del bucle&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;For Each&lt;/b&gt;.&lt;/dd&gt;&lt;/dl&gt;
&lt;dl style=&quot;-webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; color: black; font-family: &#39;Segoe UI&#39;, Verdana, Arial; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;
&lt;dt style=&quot;color: #6fa8dc;&quot;&gt;&lt;i&gt;&lt;span class=&quot;nonLinkTerms&quot;&gt;Next&lt;/span&gt;&lt;/i&gt;&lt;/dt&gt;
&lt;dd&gt;Obligatorio. Termina la definición del bucle&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;For Each&lt;/b&gt;. &lt;/dd&gt;&lt;/dl&gt;
La entrada al bloque For Each se produce si hay al menos un elemento en grupo. Una vez que se ha entrado en el bucle, todas las instrucciones en el bucle se ejecutan para el primer elemento en&lt;br /&gt;
grupo. Después, mientras haya más elementos en grupo, las instrucciones en el bucle&amp;nbsp; continúan ejecutándose para cada elemento. Cuando no hay más elementos en el grupo, se sale del bucle&amp;nbsp; y la ejecución continúa con la instrucción que sigue a la instrucción Next.Se pueden colocar en el bucle cualquier número de instrucciones Exit For. La instrucción Exit For se utiliza a menudo en la evaluación de alguna condición (por ejemplo, If...Then) y transfiere elcontrol a la instrucción que sigue inmediatamente a la instrucción Next.Puede anidar bucles For Each...Next, colocando un bucle For Each...Next dentro de otro. Sinembargo, cada elemento del bucle debe ser único.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;NOTA:&lt;/b&gt; Si omite elemento en una instrucción Next, la ejecución continúa como si se hubiera incluido. Si se encuentra una instrucción Next antes de su instrucción For correspondiente, seproducirá un error.No se puede utilizar la instrucción For Each...Next con una matriz de tipos definidos por el usuarioporque un tipo Variant no puede contener un tipo definido por el usuario&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;EJEMPLO:&lt;/b&gt;&lt;br /&gt;
En el siguiente ejemplo creamos un objeto llamado Nombres. En este agregamos tres nombres yluego, leemos cada nombre almacenado utilizando un bucle For Each…Next.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Dim Nombre as New Collection           &#39; Creamos un objeto.
Dim Leido as Variant                   &#39;Variable donde se almacenarán los elementos leidos

&#39;Agregamos datos a la colección.
Nombres.Add &quot;Carlos&quot;
Nombres.Add &quot;Pablo&quot;
Nombres.Add &quot;Jose&quot;

&#39;Leemos cada uno de los elementos agregados.
For Each Leido In Nombres
MsgBox(Leido)                          &#39; Mostramos los elementos leidos en un mensaje.
Next
&lt;/pre&gt;

Bueno pues por el momento ha sido todo, esperen el próximo tutorial While instrucción.
A una cosa más no olviden que pueden descargar algunos códigos en la pestaña de descargas.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/1633049045438651101/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-for-eachnext.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1633049045438651101'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/1633049045438651101'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/instruccion-for-eachnext.html' title='Instrucción For Each...Next'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-949392867722254941</id><published>2012-05-15T14:17:00.000-07:00</published><updated>2012-05-15T20:17:52.411-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>Select Case - End Select Structure</title><content type='html'>&lt;img src=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; style=&quot;display: none;&quot; /&gt;
&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt;En el tutorial anterior&lt;/span&gt;&lt;span class=&quot;&quot;&gt;, hemos&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;aprendido&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt;a controlar&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;el flujo del programa&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;con el&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;IF y&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;la estructura&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;ElseIf&lt;/span&gt;&lt;span class=&quot;hps&quot;&gt;.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;En este tutorial&lt;/span&gt;&lt;span class=&quot;&quot;&gt;, ustedes aprenderemos o&lt;/span&gt;&lt;span class=&quot;hps&quot;&gt;tra manera de controlar&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;el flujo del programa&lt;/span&gt;&lt;span class=&quot;hps&quot;&gt; con SELECT CASE&lt;/span&gt;&lt;span class=&quot;hps&quot;&gt;.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Sin embargo,&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;la estructura de&lt;/span&gt;&lt;span class=&quot;hps&quot;&gt;l SELECT CASE&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;es ligeramente diferente a la del IF ELSE&lt;/span&gt;. &lt;span class=&quot;hps&quot;&gt;La diferencia es que&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;la estructura del SELECT CASE&lt;/span&gt;, básicamente, sólo &lt;span class=&quot;hps&quot;&gt;tomar la decisión en&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;una&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;expresión o&lt;/span&gt; &lt;span class=&quot;hps atn&quot;&gt;dimensión (&lt;/span&gt;por ejemplo, &lt;span class=&quot;hps&quot;&gt;la calificación del examen&lt;/span&gt;), mientras que el &lt;span class=&quot;hps&quot;&gt;IF&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;...&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;sentencia ELSEIF&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;estructura de control&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;puede evaluar&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;sólo una expresión&lt;/span&gt;, cada uno &lt;span class=&quot;hps&quot;&gt;....&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;IF&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;sentencia ELSEIF&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;puede&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;también&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;calcular las dimensiones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;totalmente diferentes.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Select Case&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;es el preferido cuando&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;existen&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;muchas condiciones diferentes&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;porque el uso de&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Si&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;...&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Entonces ..&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;ElseIf&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;declaraciones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;podría llegar a ser&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;demasiado complicado&lt;/span&gt;&lt;span class=&quot;&quot;&gt;.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;&quot;&gt;Espero darme a comprender bueno esto quiere decir que el IF ELSE si se usa pero cuando son pocas cosas que se van a a comprobar pero cuando son demasiadas cosas a evaluar es mejor usar el SELECT CASE por motivos de su minimo código.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;&quot;&gt;El formato de dicha función es la siguiente :&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;long_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;    Select Case test expression

       Case expression list 1
            Block of one or more VB statements
       Case expression list 2
            Block of one or more VB Statements
       Case expression list 3
            Block of one or more VB statements
       Case expression list 4
           Block of one or more VB statements
       Case Else
            Block of one or more VB Statements
    End Select

&lt;/pre&gt;
Bueno como podemos observar la sintaxis del código es totalmente diferente pero realiza casi la misma función que el IF ELSE.&lt;br /&gt;
Bueno aquí unos ejemplos para analizar:&lt;br /&gt;
1.- Para empezar vamos a crear un ejemplo el cual llamaremos &quot;&lt;span class=&quot;long_text short_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt;Las calificaciones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;de los exámenes&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;long_text short_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt;, este ejemplo constará del siguiente código en un botón de Visual Basic que por cierto ya no debería ser nada nuevo para ustedes.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;long_text short_text&quot; id=&quot;result_box&quot; lang=&quot;es&quot;&gt;&lt;span class=&quot;hps&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Dim grado As String
Private Sub Button1_Click( )
grado=txtgrado.Text
Select Case Grado
  Case  &quot;A&quot;
       Label1.Text=&quot;Alumno altamente distinguido&quot;
  Case &quot;A-&quot;
      Label2.Text=&quot;Alumno distinguido&quot;
  Case &quot;B&quot;
        Label3.Text=&quot;Bueno&quot;
  Case &quot;C&quot;
        Label4.Text=&quot;Regular&quot;
  Case Else
        Label5.Text=&quot;Reprobado&quot;
  End Select &lt;/pre&gt;
Bueno por ahora sólo pondremos un ejemplo espero que sea suficiente porque en realidad es casi lo mismo que el IF ELSE y también por falta de dispocición de tiempo, si desean otros ejemplos o incluso ejercicios para que realicen y yo conteste si estan bien o mal no duden en contactarme en la parte de arriba del blog se encuentr mi Twitter, Facebook y para que se suscriban al blog.
Esperen el proximo tutorial hablaremos sobre cómo hacer un ciclo FOR.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/949392867722254941/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/select-case-end-select-structure.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/949392867722254941'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/949392867722254941'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/select-case-end-select-structure.html' title='Select Case - End Select Structure'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-7165150682498742967</id><published>2012-05-14T15:49:00.002-07:00</published><updated>2012-05-14T18:11:42.165-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>IF ELSE VB.Net</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-8Lop5EhxeqqvEQ4hua9ggwhqR89oLTzzNPtC5ETFpdFIozUuLdCt6xHR5eqARv3jy7gsb3nswyKi3Dlh96Z9RcyY1XT018lFHr70AWxNaLyAOxxDQAd7rne7-WwM6_vqaiuMsQGVXGM/s1600/Logo_VB.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-8Lop5EhxeqqvEQ4hua9ggwhqR89oLTzzNPtC5ETFpdFIozUuLdCt6xHR5eqARv3jy7gsb3nswyKi3Dlh96Z9RcyY1XT018lFHr70AWxNaLyAOxxDQAd7rne7-WwM6_vqaiuMsQGVXGM/s1600/Logo_VB.PNG&quot; style=&quot;display: none;&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
En este tutorial les enseñaré&amp;nbsp;a como usar el IF ELSE, esta sentencia es una de las mas usadas y una que un programador debe de saberse a la perfección, bueno pues comencemos&lt;br /&gt;
&lt;div style=&quot;color: #6fa8dc;&quot;&gt;
(Información basada en la pagina de &lt;a href=&quot;http://msdn.microsoft.com/en-us/library/752y8abs%28v=vs.80%29.aspx&quot; target=&quot;_blank&quot;&gt;MSDN&lt;/a&gt; de Microsoft) &lt;/div&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;If condition [ Then ]
    [ statements ]
[ ElseIf elseifcondition [ Then ]
    [ elseifstatements ] ]
[ Else
    [ elsestatements ] ]
End If
-or-
If condition Then [ statements ] [ Else [ elsestatements ] ]
&lt;/pre&gt;
&lt;br /&gt;
&lt;h3 style=&quot;color: #6fa8dc;&quot;&gt;



















&lt;span style=&quot;color: #0b5394;&quot;&gt;Partes que conforman el IF ELSE&lt;/span&gt;&lt;/h3&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;condition (Condición) :&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Obligatorio.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Expresión.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Se debe evaluar como&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;verdadero o falso&lt;/span&gt;, o &lt;span class=&quot;hps&quot;&gt;un tipo de datos&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;que es&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;implícitamente convertible&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;a Boolean, es la condición a realizar en nuestra sentencia.&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;Then(Entonces) : &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Se requiere&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;en la forma&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;de una sola línea&lt;/span&gt;, opcional &lt;span class=&quot;hps&quot;&gt;en forma&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;de varias líneas&lt;/span&gt;, éste nos servirá para decirle al programa que si se realiza dicha condición &quot;Entonces&quot; realizará lo que esté despues de este código.&lt;br /&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&amp;nbsp;statements (Declaraciones) : &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Opcional&lt;/span&gt;. &lt;span class=&quot;hps&quot;&gt;Una o más instrucciones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;siguientes&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;If ... Then&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;que se ejecutan&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;si la condición&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;se evalúa como True&lt;/span&gt;, aquí iran las declaraciones o lo que querramos que se realice si la sentencia resulta ser verdadera.&lt;br /&gt;
&amp;nbsp;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;elseifcondition (Condición ELSEIF) : &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Obligatorio si&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;ElseIf&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;está presente&lt;/span&gt;. &lt;span class=&quot;hps&quot;&gt;Expresión.&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Se debe evaluar como&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;verdadero o falso&lt;/span&gt;, o &lt;span class=&quot;hps&quot;&gt;un tipo de datos&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;que es&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;implícitamente convertible&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;a Boolean, esta sentencia es sólo un complemento que podemos agregar a nuestro código diciendo que si se realiza una condicion dentro de la misma se realizará otra condición por ejemplo:&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Si tienes una mascota y si ésta mascota es un perro entonces. &lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&lt;span style=&quot;color: #6fa8dc;&quot;&gt;elseifstatements (Declaraciones ELSEIF) : &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Opcional&lt;/span&gt;. &lt;span class=&quot;hps&quot;&gt;Una o más instrucciones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;siguientes&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;ElseIf&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;... Then&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;que&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;se ejecutan si&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;elseifcondition&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;se evalúa como True&lt;/span&gt;, esto nos da a conocer de que si la sentencia ELSEIF resulta ser verdadera o TRUE en ingles entonces realizará una serie de cosas, pero estas declaraciones no son obligatorias si queremos podemos dejar en blanco dichas declaraciones. &lt;br /&gt;
&lt;span style=&quot;color: #3d85c6;&quot;&gt;&amp;nbsp;elsestatements(Declaraciones ELSE) : &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Opcional&lt;/span&gt;. &lt;span class=&quot;hps&quot;&gt;Una o más instrucciones&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;que se ejecutan&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;si ninguna condición&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;o la expresión anterior&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;elseifcondition&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;se evalúa como True&lt;/span&gt;, este nos indica que si no se cumplió nada de lo anterior entonces realizará lo que esté despues de esta linea de código.&lt;br /&gt;
&lt;span style=&quot;color: #6fa8dc;&quot;&gt;&amp;nbsp;End If &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Termina el bloque&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;If ... Then ...&lt;/span&gt; &lt;span class=&quot;hps&quot;&gt;Else, mejor dicho finaliza toda la sentencia IF ELSE y derivados.&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Bueno una vez que sepamos esta información tan corta y sencilla de entender procederemos a hacer un ejemplo de dicho if else en Visual .Net (VB.Net).&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Nuestro ejemplo que haremos en este tutorial tratará de hacer que el programa nos diga si un número es par o impar, bueno este ejemplo lo puse gracias a un amigo que me planteó el problema y como es principiante no sabía por eso decidí hacer el IF ELSE con este ejemplo.&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Bueno comencemos...&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;Como anteriormente ya hemos aprendido a como crear un proyecto de Visual Basic ya no tendremos tantos problemas, bueno ahora lo que tenemos que hacer es asignarle un nombre a nuestro proyecto en mi caso le colocaré el nombre de &quot;IF ELSE&quot;, pero ustedes pongan el que quieran, una vez que ya tengamos creado el proyecto y que ya tengamos la pantalla en donde está el foemulario haremos lo siguiente:&lt;/span&gt;
&lt;span class=&quot;hps&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;&lt;b&gt;1.-&lt;/b&gt; Agregamos un botón a nuestro formulario.&lt;/span&gt;
&lt;span class=&quot;hps&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;&lt;b&gt;2.-&lt;/b&gt; Damos doble clic sobre el botón para redireccionarnos en la vista de código.&lt;/span&gt;
&lt;span class=&quot;hps&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;&lt;b&gt;3.-&lt;/b&gt; Declararemos una variable llamada (Num1) de la siguiente manera : &lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Dim Num1 as Integer
&lt;/pre&gt;
De esta manera le estamos diciendo al programa que cree una variable llamada Num1 y que sea del tipo numerica (Integer).&lt;br /&gt;
&lt;b&gt;4.-&lt;/b&gt; Ahora colocaremos todo éste código debajo del anterior:&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;        Num1 = 3 &#39;Le decimos al programa que el valor del Num1 será (2)
        If (Num1 / 2) = Int((Num1 / 2)) Then &#39; Se hace la verificación si se puede dividir el numero entre sí
            MessageBox.Show(&quot;El número es par&quot;) &#39;Mandamos un mensaje diciendo que es par
        Else &#39; Si no se cumple la condición realiza lo siguiente
            MessageBox.Show(&quot;El número es impar&quot;) &#39;Mandamos un mensaje diciendo que es impar
        End If &#39;Terminamos la sentencia IF ELSE
&lt;/pre&gt;
&lt;b&gt;5.-&lt;/b&gt; Bueno una vez que tengamos claro esto así es como nos debe de quedar todo el código fuente del programa de visual basic.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt; 
Public Class Form1

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
        Dim Num1 As Integer
        Num1 = 3
        If (Num1 / 2) = Int((Num1 / 2)) Then
            MessageBox.Show(&quot;El número es par&quot;)
        Else
            MessageBox.Show(&quot;El número es impar&quot;)
        End If
    End Sub
End Class
&lt;/pre&gt;
&lt;b&gt;&lt;/b&gt; Bueno ahora que ya sabemos hacer este tipo de IF vamos a ver como le hacemos con un IF dentro de otro IF.&lt;br /&gt;
Ahora cambiaremos el problema el problema será el siguiente:&lt;br /&gt;
Problema:&lt;br /&gt;
Hacer un programa que verifique si un animal es un gato y si es gato que mande un mensaje en pantalla diciendo el resultado y si no es gato que mande otro mensaje.&lt;br /&gt;
Para comenzar así como lo de hace un momento haremos los siguientes pasos :&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;&lt;b&gt;1.-&lt;/b&gt; Agregamos un botón a nuestro formulario.&lt;/span&gt;
&lt;span class=&quot;hps&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;hps&quot;&gt;&lt;b&gt;2.-&lt;/b&gt; Damos doble clic sobre el botón para redireccionarnos en la vista de código.&lt;/span&gt;&lt;br /&gt;
3.- Declaramos la variable gato y la variable raza de la siguiente manera:&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Dim Gato, Raza as String
&lt;/pre&gt;
De esta manera le estamos diciendo al programa que cree dos variables, una llamada Gato y una llamada Raza y las dos del tipo de Texto o String.&lt;br /&gt;
&lt;b&gt;4.-&lt;/b&gt; Ahora colocaremos todo éste código debajo del anterior:&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Gato = &quot;Gary&quot;
        Raza = &quot;Quien sabe&quot;
        If (Gato = &quot;Gary&quot;) Then
            If Raza = &quot;Quien sabe&quot; Then
                MessageBox.Show(&quot;El gato es &quot; &amp;amp; Gato &amp;amp; &quot; de la raza &quot; &amp;amp; Raza)
            ElseIf Raza = &quot;Callejera&quot; Then
                MessageBox.Show(&quot;El gato es &quot; &amp;amp; Gato &amp;amp; &quot; de la raza &quot; &amp;amp; Raza)
            End If
        Else
            MessageBox.Show(&quot;No existe dicho gato&quot;)
        End If
&lt;/pre&gt;
5.- Bueno una vez que tengamos claro esto así es como nos debe de quedar todo el código fuente del programa de visual basic con los dos ejemplos que ya hemos creado.
&lt;br /&gt;
&lt;pre class=&quot;brush:vbnet&quot;&gt;Public Class Form1

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
        Dim Num1 As Integer
        Num1 = 3
        If (Num1 / 2) = Int((Num1 / 2)) Then
            MessageBox.Show(&quot;El número es par&quot;)
        Else
            MessageBox.Show(&quot;El número es impar&quot;)
        End If
    End Sub

    Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Button2.Click
        Dim Gato, Raza As String
        Gato = &quot;Gary&quot;
        Raza = &quot;Quien sabe&quot;
        If (Gato = &quot;Gary&quot;) Then
            If Raza = &quot;Quien sabe&quot; Then
                MessageBox.Show(&quot;El gato es &quot; &amp;amp; Gato &amp;amp; &quot; de la raza &quot; &amp;amp; Raza)
            ElseIf Raza = &quot;Callejera&quot; Then
                MessageBox.Show(&quot;El gato es &quot; &amp;amp; Gato &amp;amp; &quot; de la raza &quot; &amp;amp; Raza)
            End If
        Else
            MessageBox.Show(&quot;No existe dicho gato&quot;)
        End If
    End Sub
End Class
&lt;/pre&gt;
Buenoya que tenemos esto nos daremos cuenta que hay IF´s dentro de otros IF´s en el cual podemos jugar con el valor de las variables gato y raza y se nos mandarán distintos mensajes esto queda de tarea para que analicen.&lt;br /&gt;
Bueno espero que les haya gustado este tutorial y hasta la proxima, no olviden dejar sus comentarios de agradecimientos y si les gusto denle like o suscribanse que no cuesta nada o si quieren algo más para mejorar los tutoriales digánlo para que yo vea que puedo hacer por ustedes.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/7165150682498742967/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/if-else-vbnet.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7165150682498742967'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/7165150682498742967'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/if-else-vbnet.html' title='IF ELSE VB.Net'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi-8Lop5EhxeqqvEQ4hua9ggwhqR89oLTzzNPtC5ETFpdFIozUuLdCt6xHR5eqARv3jy7gsb3nswyKi3Dlh96Z9RcyY1XT018lFHr70AWxNaLyAOxxDQAd7rne7-WwM6_vqaiuMsQGVXGM/s72-c/Logo_VB.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-4586808635970990114</id><published>2012-05-14T15:02:00.000-07:00</published><updated>2012-05-14T15:02:28.180-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Hola mundo</title><content type='html'>&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s1600/C_Sharp.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s200/C_Sharp.png&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
Bueno para empezar bien estos tutoriales en el blog comencemos con lo principal que es el &quot;Hola Mundo&quot; para esto necesitamos crear un nuevo proyecto al cual llamaremos &quot;Hola mundo&quot;, para esto si somos principiantes seguiremos los siguientes pasos:&lt;br /&gt;
1.- Vamos a la parte de abajo de la pestaña Archivo y damos clic en el botón que dice crear nuevo proyecto.&lt;br /&gt;
&lt;br /&gt;
2.- Ahora verificamos que salga esta ventana(Dar clic para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhW5Qb2UQh48gKwqhT9L1QhlO9x09ENF-BsrD725mn_yFqin8d2cbap6gknNYZXurwUdyNTALlIrkMxR_fbhs6K1sPzct796Vpkm4uDBcyqMzWGvsgQl2eSYaxWe9BfyGeTKOT_W1E3AOc/s1600/m.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;228&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhW5Qb2UQh48gKwqhT9L1QhlO9x09ENF-BsrD725mn_yFqin8d2cbap6gknNYZXurwUdyNTALlIrkMxR_fbhs6K1sPzct796Vpkm4uDBcyqMzWGvsgQl2eSYaxWe9BfyGeTKOT_W1E3AOc/s320/m.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
3.- Esta ventana deberá de contener las siguientes propiedades:&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Verificar que esté seleccionada la opción de Visual C#.&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Seleccionar la opción que dice Aplicación de Windows Forms. &lt;br /&gt;
&amp;nbsp;&amp;nbsp; -En el nombre colocar &quot;Hola mundo&quot;.&lt;br /&gt;
4.-Presionar el botón &quot;Aceptar&quot;.&lt;br /&gt;
5.-Esperamos que cargue el programa y obtendremos una nueva ventana como esta(Dar clic en la imagen para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiE97qCXAxHHV75ljy7QPN97G8tTlWeJngzllpYz6aynE9mhWnHJ-K0zFcWVL-HiyhI8lr2tlQ_b8HhT7kTge48JQPwbJgjdOmnVoE2GkJ7hsL4a3GZXy2dF0pCjattIoyeuBLrEg7Hais/s1600/full.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;228&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiE97qCXAxHHV75ljy7QPN97G8tTlWeJngzllpYz6aynE9mhWnHJ-K0zFcWVL-HiyhI8lr2tlQ_b8HhT7kTge48JQPwbJgjdOmnVoE2GkJ7hsL4a3GZXy2dF0pCjattIoyeuBLrEg7Hais/s320/full.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
6.-Ahora procedemos a arrastrar un botón del cuadro de herramientas que se encuentra a la derecha y lo ponemos en el formulario de tal manera que quede de esta forma:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
7.- Una vez que tengamos ya hecho nuestro formulario procedemos a codificar el &quot;Hola mundo&quot;, para esto damos doble clic sobre el botón y veremos que aparecerá la parte del programador en donde podremos poner todo nuestro código.&lt;br /&gt;
8.- En ésta parte del programador podremos darnos cuenta de que tenemos este código:&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Hola_mundo
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {

        }
    }
}
&lt;/pre&gt;
9.- Bueno una vez que tengamos este código procederemos a poner entre estas líneas:&lt;br /&gt;
&lt;pre class=&quot;brush : csharp&quot;&gt;private void button1_Click(object sender, EventArgs e)
        {
            
        }
&lt;/pre&gt;
Ponemos esto :

&lt;br /&gt;
&lt;pre class=&quot;brush:csharp&quot;&gt;MessageBox.Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons.OK, MessageBoxIcon.Information);&lt;/pre&gt;
&lt;br /&gt;
&lt;div style=&quot;background: white; color: black; font-family: inherit;&quot;&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;10.- Bueno ahora explicare paso a paso para que sirve cada parte de este código.&lt;/span&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;MessageBox : Indica que mandara un mensaje por pantalla.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Show : Indica que dicho elemento podrá hacerse visible para el usuario.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&quot;&quot; : Las comillas mayormente funcionan para poner campos con texto.&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Aquí decimos que cree un MessageBox que se visualizará en pantalla con el comando Show el cual contendrá un texto en su interior diciendo &quot;Hola mundo&quot;, y un texto en la cabecera diciendo &quot;Hola&quot;, También hacemos referencia a que este mensaje contendrá un sólo botón llamado OK y que el tipo de mensaje será un mensaje de información.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;11.-Ahora así es como nos debió de quedar todo nuestro código:&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush : csharp&quot;&gt;using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Hola_mundo
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            MessageBox.Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons.OK, MessageBoxIcon.Information);
        }
    }
}

&lt;/pre&gt;
12.- Y ahora por último presionamos F5 o damos en el botoncito verde llamado Compilar y se comenzará a compilar el proyecto una vez finalizado el compilado se nos mostrará en pantalla el formulario y al presionar el botón se realizará la acción del mensaje, el mensaje nos debería de quedar así:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Bueno al parecer esto ha sido todo por el momento espero que les haya servido de algo esta información.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Para descargar el código y el formulario ya terminados dar clic en el siguiente botón:&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;style type=&quot;text/css&quot;&gt;
  .boton
  {
   
   width:120px;
   height:40px;
  }
.contacto input[type=&#39;submit&#39;]{
 border: 1px solid #CED5D7;
 box-shadow:0 0 0 3px #EEF5F7;
 padding: 8px 16px;
 border-radius: 10px;
 font-weight: bold;
 text-shadow: 1px 1px 0px white;
 
 background: #b9b9b9; 
 background: -moz-linear-gradient(top, #f2f2f2 0%, #b9b9b9 100%);
 background: -webkit-linear-gradient(top, #e4f1f6 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:hover{
 background: #edfcff; 
 background: -moz-linear-gradient(top, #f2f2f2 10%, #b9b9b9 90%);
 background: -webkit-linear-gradient(top, #edfcff 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:active{
 background: #cfe6ef; 
 background: -moz-linear-gradient(top, #f2f2f2 40%, #b9b9b9 60%);
 background: -webkit-linear-gradient(top, #cfe6ef 0%,#edfcff 100%);
}
  
&lt;/style&gt;
&lt;br /&gt;
&lt;div class=&quot;contacto&quot;&gt;
&lt;a href=&quot;http://www.mediafire.com/download.php?p8oc6uf5zsoo4yc&quot; target=&quot;_blank&quot;&gt;&lt;input class=&quot;boton&quot; name=&quot;boton&quot; type=&quot;submit&quot; value=&quot;Descargar&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;font-family: inherit;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/4586808635970990114/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/hola-mundo_14.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/4586808635970990114'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/4586808635970990114'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/hola-mundo_14.html' title='Hola mundo'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s72-c/C_Sharp.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-2066796023647937787</id><published>2012-05-14T14:25:00.002-07:00</published><updated>2012-05-14T14:26:26.185-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C#"/><title type='text'>Introducción a Visual C#</title><content type='html'>&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s1600/C_Sharp.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s200/C_Sharp.png&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&lt;br /&gt;Hola, Bienvenido a mi blog espero que te sea de ayuda algo que postee, en  este blog hablare sobre Visual C# o&amp;nbsp;CSharp&amp;nbsp;como quieran llamarle,&amp;nbsp;podrán distinguir los  distintos lenguajes de programación con tan sólo verificar la imagen de  presentación que son especificas para cada lenguaje, en este blog  abarcaremos temas tan sencillos como la creación del primer programa en C# el cual será el &quot;Hola mundo&quot; que es con el que todo programador  debe comenzar así después podremos ver creación de If Else, For, While,  Conexión a bases de datos desde Access, MySql, Oracle y otros Sistemas  Gestores de Bases de Datos; Espero contar con sus comentarios por si  tienen alguna duda, no olviden comentar si desean un post en especial y  con gusto lo posteare, denle likes para que el blog crezca y sea cada  vez mejor y así me den mas ánimos de seguir aportando un poco de mis  conocimientos a ustedes que tienen ganas de aprender, espero contar con  su apoyo criticas y sugerencias por favor háganlas saber así como ustedes comprenderán no toleraré insultos ni nada por el estilo traten de  mantener la amistad, espero entiendan.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/2066796023647937787/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/introduccion-visual-c_14.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2066796023647937787'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2066796023647937787'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/introduccion-visual-c_14.html' title='Introducción a Visual C#'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhoWTGL9uyUk6_yZVbERgpisqapJP6fPHqIazvVtPcOMc5W65d4ieNCI_0S6_2i2Z_PQT_8_6QnF1fKZhmBA1HNOm5YUqW1pqFXASW0SpNCdokqpOqBUTQYgFGN9QsdlxTjywPlQG4hp4U/s72-c/C_Sharp.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-6231231675225346309</id><published>2012-05-14T08:21:00.000-07:00</published><updated>2012-05-14T09:26:57.729-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Hola mundo</title><content type='html'>&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C%252B%252B_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s200/Visual_C%252B%252B_Icon.png&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;Bueno para empezar bien estos tutoriales en el blog comencemos con lo
 principal que es el &quot;Hola Mundo&quot; para esto necesitamos crear un nuevo 
proyecto al cual llamaremos &quot;Hola mundo&quot;, para esto si somos 
principiantes seguiremos los siguientes pasos:&lt;br /&gt;
1.- Vamos a la parte de abajo de la pestaña Archivo y damos clic en el botón que dice crear nuevo proyecto.&lt;br /&gt;
&lt;br /&gt;
2.- Ahora verificamos que salga esta ventana(Dar clic para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpei8kuLsDvlFeH8YRr4sjIzkFZD0Ya-QXOcoc4PDVgho2YDz3LqRiJ_yzahrdDvz-dm5KYe7t_UmPtnD56QuATYj1OEGOkN8ZG-ODllA3Pvj2guNkGG9jMzJxgcxxfKG-sqbVqHvMrC4/s1600/C++.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;228&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpei8kuLsDvlFeH8YRr4sjIzkFZD0Ya-QXOcoc4PDVgho2YDz3LqRiJ_yzahrdDvz-dm5KYe7t_UmPtnD56QuATYj1OEGOkN8ZG-ODllA3Pvj2guNkGG9jMzJxgcxxfKG-sqbVqHvMrC4/s320/C++.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjYCq9gGS84mnlr2dUN8D5y_6pNWE9xSU-1Y2KdUKIAlcPMkRhMMpMUXEmSjlH27NtB062D1KdO0qBxmFDaIFA5l9k81ojne4ou7esfco0zm1ZsqedI_F6p_-KidMZCnVYaJwBCd59xKn4/s1600/fomr.PNG&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;
3.- Esta ventana deberá de contener las siguientes propiedades:&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Verificar que esté seleccionada la opción de Visual C++&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Seleccionar la opcion que dice Aplicación de Windows Forms. &lt;br /&gt;
&amp;nbsp;&amp;nbsp; -En el nombre colocar &quot;Hola mundo&quot;.&lt;br /&gt;
4.-Presionar el botón &quot;Aceptar&quot;.&lt;br /&gt;
5.-Esperamos
 que cargue el programa y obtendremos una nueva ventana como esta(Dar 
click en la imagen para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj8kQJstF5gVxT-jn-r1fftp-jzjrG8q-wZw0uTtvNTj_5O4MExvTWkLGjiw_WCoGp_YFgnTl9JvltxedZXak3TYtCbP1qMcCiV7brOWP_vzTO6FeLDVb9ICUDBlzzq92SEO9mn1VYnZbc/s1600/full.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj8kQJstF5gVxT-jn-r1fftp-jzjrG8q-wZw0uTtvNTj_5O4MExvTWkLGjiw_WCoGp_YFgnTl9JvltxedZXak3TYtCbP1qMcCiV7brOWP_vzTO6FeLDVb9ICUDBlzzq92SEO9mn1VYnZbc/s320/full.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
6.-Ahora
 procedemos a arrastrar un botón del cuadro de herramientas que se 
encuentra a la derecha y lo ponemos en el formulario de tal manera que 
quede de esta forma:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
7.-
 Una vez que tengamos ya hecho nuestro formulario procedemos a codificar
 el &quot;Hola mundo&quot;, para esto damos doble click sobre el botón y veremos 
que aparecera la parte del programador en donde podremos poner todo 
nuestro código.&lt;br /&gt;
8.- En ésta parte del programador podremos darnos cuenta de que tenemos este código:&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace Holamundo {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;SuspendLayout();
   // 
   // button1
   // 
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(105, 101);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
    }
 };
}&lt;/pre&gt;
9.- Bueno una vez que tengamos esto dentro de éstas lineas de código :&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt; private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
    }
 };&lt;/pre&gt;
Pondremos lo siguiente:
&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;MessageBox::Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);&lt;/pre&gt;
&lt;div style=&quot;color: red;&quot;&gt;
&lt;span style=&quot;font-size: large;&quot;&gt;Importante!!!&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: #ea9999;&quot;&gt;
No se nos olvide poner el &quot;;&quot; al final de cada instrucción si no queremos tener errores de compilación&lt;/div&gt;
&lt;div style=&quot;color: #ea9999;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background: none repeat scroll 0% 0% white; color: black; font-family: inherit;&quot;&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;10.- Bueno ahora explicaré paso a paso para que sirve cada parte de este código.&lt;/span&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;MessageBox : Indica que mandara un mensage por pantalla.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&quot;::&quot; (Dos puntos dobles)&amp;nbsp; : Estas comillas dobles nos sirven para separar funciones como lo hace el &quot;.&quot; en VB.Net o C#. &lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Show : Indica que dicho elemento podrá hacerse visible para el usuario.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&quot;&quot; : Las comillas mayormente funcionan para poner campos con texto.&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Aqui decimos que cree un MessageBox que se 
visualizará en pantalla con el comando Show el cual contendrá un texto 
en su interior diciendo &quot;Hola mundo&quot;, y un texto en la cabecera diciendo
 &quot;Hola&quot;, Tambien hacemos referencia a que este mensage contendra un sólo
 botón llamado OK y que el tipo de mensage sera un mensage de 
información.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;11.-Ahora así es como nos debió de quedar todo nuestro código:&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:cpp&quot;&gt;#pragma once

namespace Holamundo {

 using namespace System;
 using namespace System::ComponentModel;
 using namespace System::Collections;
 using namespace System::Windows::Forms;
 using namespace System::Data;
 using namespace System::Drawing;

 /// &lt;summary&gt;
 /// Resumen de Form1
 /// &lt;/summary&gt;
 public ref class Form1 : public System::Windows::Forms::Form
 {
 public:
  Form1(void)
  {
   InitializeComponent();
   //
   //TODO: agregar código de constructor aquí
   //
  }

 protected:
  /// &lt;summary&gt;
  /// Limpiar los recursos que se estén utilizando.
  /// &lt;/summary&gt;
  ~Form1()
  {
   if (components)
   {
    delete components;
   }
  }
 private: System::Windows::Forms::Button^  button1;
 protected: 

 private:
  /// &lt;summary&gt;
  /// Variable del diseñador requerida.
  /// &lt;/summary&gt;
  System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
  /// &lt;summary&gt;
  /// Método necesario para admitir el Diseñador. No se puede modificar
  /// el contenido del método con el editor de código.
  /// &lt;/summary&gt;
  void InitializeComponent(void)
  {
   this-&amp;gt;button1 = (gcnew System::Windows::Forms::Button());
   this-&amp;gt;SuspendLayout();
   // 
   // button1
   // 
   this-&amp;gt;button1-&amp;gt;Location = System::Drawing::Point(105, 101);
   this-&amp;gt;button1-&amp;gt;Name = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;Size = System::Drawing::Size(75, 23);
   this-&amp;gt;button1-&amp;gt;TabIndex = 0;
   this-&amp;gt;button1-&amp;gt;Text = L&quot;button1&quot;;
   this-&amp;gt;button1-&amp;gt;UseVisualStyleBackColor = true;
   this-&amp;gt;button1-&amp;gt;Click += gcnew System::EventHandler(this, &amp;amp;Form1::button1_Click);
   // 
   // Form1
   // 
   this-&amp;gt;AutoScaleDimensions = System::Drawing::SizeF(6, 13);
   this-&amp;gt;AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
   this-&amp;gt;ClientSize = System::Drawing::Size(284, 261);
   this-&amp;gt;Controls-&amp;gt;Add(this-&amp;gt;button1);
   this-&amp;gt;Name = L&quot;Form1&quot;;
   this-&amp;gt;Text = L&quot;Form1&quot;;
   this-&amp;gt;ResumeLayout(false);

  }
#pragma endregion
 private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
     MessageBox::Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons::OK, MessageBoxIcon::Information);
    }
 };
}&amp;nbsp;&lt;/pre&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;12.- Y ahora por último presionamos F5 o damos en el 
botoncito verde llamado Compilar y se comenzará a compilar el proyecto 
una vez finalizado el compilado se nos mostrará en pantalla el 
formulario y al presionar el botón se realizará la accion del mensaje, 
el mensage nos debería de quedar así:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Bueno al parecer esto ha sido todo por el momento espero que les haya servido de algo esta información.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Para descargar el código y el formulario ya terminados dar click en el siguiente botón:&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;style type=&quot;text/css&quot;&gt;
  .boton
  {
   
   width:120px;
   height:40px;
  }
.contacto input[type=&#39;submit&#39;]{
 border: 1px solid #CED5D7;
 box-shadow:0 0 0 3px #EEF5F7;
 padding: 8px 16px;
 border-radius: 10px;
 font-weight: bold;
 text-shadow: 1px 1px 0px white;
 
 background: #b9b9b9; 
 background: -moz-linear-gradient(top, #f2f2f2 0%, #b9b9b9 100%);
 background: -webkit-linear-gradient(top, #e4f1f6 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:hover{
 background: #edfcff; 
 background: -moz-linear-gradient(top, #f2f2f2 10%, #b9b9b9 90%);
 background: -webkit-linear-gradient(top, #edfcff 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:active{
 background: #cfe6ef; 
 background: -moz-linear-gradient(top, #f2f2f2 40%, #b9b9b9 60%);
 background: -webkit-linear-gradient(top, #cfe6ef 0%,#edfcff 100%);
}
  
&lt;/style&gt;
&lt;br /&gt;
&lt;div class=&quot;contacto&quot;&gt;
&lt;a href=&quot;http://www.mediafire.com/download.php?n5lrp8e2e5a525e&quot; target=&quot;_blank&quot;&gt;&lt;input class=&quot;boton&quot; name=&quot;boton&quot; type=&quot;submit&quot; value=&quot;Descargar&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;font-family: inherit;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/6231231675225346309/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/hola-mundo.html#comment-form' title='2 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6231231675225346309'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/6231231675225346309'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/hola-mundo.html' title='Hola mundo'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C%252B%252B_Icon.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-3207343505999626313</id><published>2012-05-14T07:18:00.000-07:00</published><updated>2012-05-14T14:29:43.093-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual C++"/><title type='text'>Introducción a Visual C++</title><content type='html'>&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s1600/Visual_C++_Icon.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;200&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s200/Visual_C++_Icon.png&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;Hola,
 Bienvenido a mi blog espero que te sea de ayuda algo que postee, en 
este blog hablare sobre Visual C++ con Visual Studio podrán distinguir los 
distintos lenguajes de programcion con tan sólo verificar la imagen de 
presentacion que son especificas para cada lenguaje, en este blog 
abarcaremos temas tan sencillos como la creacion del primer programa en C++ el cual será el &quot;Hola mundo&quot; que es con el que todo programador 
debe comenzar así despues podremos ver creación de If Else, For, While, 
Conección a bases de datos desde Access, MySql, Oracle y otros Sistemas 
Gestores de Bases de Datos; Espero contar con sus comentarios por si 
tienen alguna duda, no olviden comentar si desean un post en especial y 
con gusto lo posteare, denle likes para que el blog crezca y sea cada 
vez mejor y asi me den mas animos de seguir aportando un poco de mis 
conocimientos a ustedes que tienen ganas de aprender, espero contar con 
su apoyo criticas y sugerencias porfavor haganlas saber asi como ustedes
 comprenderan no toleraré insultos ni nada por el estilo traten de 
mantener la amistad, espero entiendan.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/3207343505999626313/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/introduccion-visual-c.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/3207343505999626313'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/3207343505999626313'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/introduccion-visual-c.html' title='Introducción a Visual C++'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhERMKFWGVhod-LsMus0P9ZcFwBonk6Viig_mI5oxupJuUfIWsqaiEP4LHbN8FcKXZvNU_AdlbOkK0TVlLZbHinrrZ9OkR1_M3Qsbob-W43enVxfudjkNmeYAlxd5pc5S0tTVrCaLqmEG0/s72-c/Visual_C++_Icon.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-2882654906229549348</id><published>2012-05-09T21:19:00.000-07:00</published><updated>2012-05-14T14:59:23.483-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>Hola mundo</title><content type='html'>&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;193&quot; src=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Bueno para empezar bien estos tutoriales en el blog comencemos con lo principal que es el &quot;Hola Mundo&quot; para esto necesitamos crear un nuevo proyecto al cual llamaremos &quot;Hola mundo&quot;, para esto si somos principiantes seguiremos los siguientes pasos:&lt;br /&gt;
1.- Vamos a la parte de abajo de la pestaña Archivo y damos clic en el botón que dice crear nuevo proyecto.&lt;br /&gt;
&lt;br /&gt;
2.- Ahora verificamos que salga esta ventana(Dar clic para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjYCq9gGS84mnlr2dUN8D5y_6pNWE9xSU-1Y2KdUKIAlcPMkRhMMpMUXEmSjlH27NtB062D1KdO0qBxmFDaIFA5l9k81ojne4ou7esfco0zm1ZsqedI_F6p_-KidMZCnVYaJwBCd59xKn4/s1600/fomr.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;225&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjYCq9gGS84mnlr2dUN8D5y_6pNWE9xSU-1Y2KdUKIAlcPMkRhMMpMUXEmSjlH27NtB062D1KdO0qBxmFDaIFA5l9k81ojne4ou7esfco0zm1ZsqedI_F6p_-KidMZCnVYaJwBCd59xKn4/s320/fomr.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
3.- Esta ventana deberá de contener las siguientes propiedades:&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Verificar que esté seleccionada la opción de Visual Basic.&lt;br /&gt;
&amp;nbsp;&amp;nbsp; -Seleccionar la opcion que dice Aplicación de Windows Forms. &lt;br /&gt;
&amp;nbsp;&amp;nbsp; -En el nombre colocar &quot;Hola mundo&quot;.&lt;br /&gt;
4.-Presionar el botón &quot;Aceptar&quot;.&lt;br /&gt;
5.-Esperamos que cargue el programa y obtendremos una nueva ventana como esta(Dar click en la imagen para ver en tamaño original):&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiE97qCXAxHHV75ljy7QPN97G8tTlWeJngzllpYz6aynE9mhWnHJ-K0zFcWVL-HiyhI8lr2tlQ_b8HhT7kTge48JQPwbJgjdOmnVoE2GkJ7hsL4a3GZXy2dF0pCjattIoyeuBLrEg7Hais/s1600/full.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;228&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiE97qCXAxHHV75ljy7QPN97G8tTlWeJngzllpYz6aynE9mhWnHJ-K0zFcWVL-HiyhI8lr2tlQ_b8HhT7kTge48JQPwbJgjdOmnVoE2GkJ7hsL4a3GZXy2dF0pCjattIoyeuBLrEg7Hais/s320/full.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
6.-Ahora procedemos a arrastrar un botón del cuadro de herramientas que se encuentra a la derecha y lo ponemos en el formulario de tal manera que quede de esta forma:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4YiAHQea2kDEkT7n65rl7PMosrpW4yVKqLyILwKWhP_VMbRlO4M5p7BHnN6GLNywc-IzdV-iM7ZwpycgRg2NRbdUORfU0ZjXaadi3yRLtS3z9d843THzYCXKZ6LXnG5kKI4GmJWg7go/s1600/form.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
7.- Una vez que tengamos ya hecho nuestro formulario procedemos a codificar el &quot;Hola mundo&quot;, para esto damos doble click sobre el botón y veremos que aparecera la parte del programador en donde podremos poner todo nuestro código.&lt;br /&gt;
8.- En ésta parte del programador podremos darnos cuenta de que tenemos este código:&lt;br /&gt;
&lt;pre class=&quot;brush:vb&quot;&gt;Public Class Form1

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click

    End Sub
End Class
&lt;/pre&gt;
9.- Bueno una vez que tengamos esto dentro de la subclase que es Private Sub y End Sub pondremos el siguiente código.&lt;br /&gt;
&lt;pre class=&quot;brush:vb&quot;&gt;MessageBox.Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons.OK, MessageBoxIcon.Information)                
&lt;/pre&gt;
&lt;pre style=&quot;background: white; color: black; font-family: Consolas; font-size: 13px;&quot;&gt;&amp;nbsp;&lt;/pre&gt;
&lt;div style=&quot;background: white; color: black; font-family: inherit;&quot;&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;10.- Bueno ahora explicare paso a paso para que sirve cada parte de este código.&lt;/span&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;MessageBox : Indica que mandara un mensage por pantalla.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Show : Indica que dicho elemento podrá hacerse visible para el usuario.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&quot;&quot; : Las comillas mayormente funcionan para poner campos con texto.&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Aquí decimos que cree un MessageBox que se visualizará en pantalla con el comando Show el cual contendrá un texto en su interior diciendo &quot;Hola mundo&quot;, y un texto en la cabecera diciendo &quot;Hola&quot;, También hacemos referencia a que este mensaje contendrá un sólo botón llamado OK y que el tipo de mensaje será un mensaje de información.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;11.-Ahora así es como nos debió de quedar todo nuestro código:&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:vb&quot;&gt;Public Class Form1

    Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
        MessageBox.Show(&quot;Hola mundo&quot;, &quot;Hola&quot;, MessageBoxButtons.OK, MessageBoxIcon.Information)

    End Sub
End Class
&lt;/pre&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;12.- Y ahora por último presionamos F5 o damos en el botoncito verde llamado Compilar y se comenzará a compilar el proyecto una vez finalizado el compilado se nos mostrará en pantalla el formulario y al presionar el botón se realizará la acción del mensaje, el mensaje nos debería de quedar así:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhCdV4-CkyfI0kqUIOiHRhfZJGSVRnfYpWqM1wtmVPV0wcUqj-2nd-JSnmEu4KwcHZjdDzYY8_qy3YUGvwz0Nt_juNQfX3nN4n40JhYpPZEsVDmAQ8Ko43FfnMN9dEQR8PdU5xmRrlPJug/s1600/msg.PNG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Bueno al parecer esto ha sido todo por el momento espero que les haya servido de algo esta información.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-size: small;&quot;&gt;Para descargar el código y el formulario ya terminados dar clic en el siguiente botón:&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;style type=&quot;text/css&quot;&gt;
  .boton
  {
   
   width:120px;
   height:40px;
  }
.contacto input[type=&#39;submit&#39;]{
 border: 1px solid #CED5D7;
 box-shadow:0 0 0 3px #EEF5F7;
 padding: 8px 16px;
 border-radius: 10px;
 font-weight: bold;
 text-shadow: 1px 1px 0px white;
 
 background: #b9b9b9; 
 background: -moz-linear-gradient(top, #f2f2f2 0%, #b9b9b9 100%);
 background: -webkit-linear-gradient(top, #e4f1f6 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:hover{
 background: #edfcff; 
 background: -moz-linear-gradient(top, #f2f2f2 10%, #b9b9b9 90%);
 background: -webkit-linear-gradient(top, #edfcff 0%,#cfe6ef 100%); 
}
.contacto input[type=&#39;submit&#39;]:active{
 background: #cfe6ef; 
 background: -moz-linear-gradient(top, #f2f2f2 40%, #b9b9b9 60%);
 background: -webkit-linear-gradient(top, #cfe6ef 0%,#edfcff 100%);
}
  
&lt;/style&gt;
&lt;br /&gt;
&lt;div class=&quot;contacto&quot;&gt;
&lt;a href=&quot;http://www.mediafire.com/download.php?e5yrtj5a7iq6mgc&quot; target=&quot;_blank&quot;&gt;&lt;input class=&quot;boton&quot; name=&quot;boton&quot; type=&quot;submit&quot; value=&quot;Descargar&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;font-family: inherit;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/2882654906229549348/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/bueno-para-empezar-bien-estos.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2882654906229549348'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/2882654906229549348'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/bueno-para-empezar-bien-estos.html' title='Hola mundo'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjYCq9gGS84mnlr2dUN8D5y_6pNWE9xSU-1Y2KdUKIAlcPMkRhMMpMUXEmSjlH27NtB062D1KdO0qBxmFDaIFA5l9k81ojne4ou7esfco0zm1ZsqedI_F6p_-KidMZCnVYaJwBCd59xKn4/s72-c/fomr.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2126889675011838330.post-4139652503683450251</id><published>2012-05-07T17:18:00.001-07:00</published><updated>2012-05-14T14:30:32.982-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Visual .Net"/><title type='text'>Introducción a Visual .Net</title><content type='html'>&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;http://4.bp.blogspot.com/-dMNKXFEo0fE/T6sT7cr06ZI/AAAAAAAAAJU/FzP2yB-eCvM/s1600/logochico.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;193&quot; src=&quot;http://devilsoftwarex.webcindario.com/Blogger/Logo_VB.PNG&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Hola, Bienvenido a mi blog espero que te sea de ayuda algo que postee, en este blog hablare sobre VB.Net con Visual Studio podrán distinguir los distintos lenguajes de programcion con tan sólo verificar la imagen de presentacion que son especificas para cada lenguaje, en este blog abarcaremos temas tan sencillos como la creacion del primer programa en VB.Net el cual será el &quot;Hola mundo&quot; que es con el que todo programador debe comenzar así despues podremos ver creación de If Else, For, While, Conección a bases de datos desde Access, MySql, Oracle y otros Sistemas Gestores de Bases de Datos; Espero contar con sus comentarios por si tienen alguna duda, no olviden comentar si desean un post en especial y con gusto lo posteare, denle likes para que el blog crezca y sea cada vez mejor y asi me den mas animos de seguir aportando un poco de mis conocimientos a ustedes que tienen ganas de aprender, espero contar con su apoyo criticas y sugerencias porfavor haganlas saber asi como ustedes comprenderan no toleraré insultos ni nada por el estilo traten de mantener la amistad, espero entiendan.</content><link rel='replies' type='application/atom+xml' href='http://programandoenalta.blogspot.com/feeds/4139652503683450251/comments/default' title='Enviar comentarios'/><link rel='replies' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/programacion-en-vbnet.html#comment-form' title='0 comentarios'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/4139652503683450251'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2126889675011838330/posts/default/4139652503683450251'/><link rel='alternate' type='text/html' href='http://programandoenalta.blogspot.com/2012/05/programacion-en-vbnet.html' title='Introducción a Visual .Net'/><author><name>Horacio Espinosa</name><uri>http://www.blogger.com/profile/16216761764164114684</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>