using System.Drawing; private Image Get_IMAGE(Byte[] ImageB) { Image ImageR = null; if (ImageB != null) if (ImageB.Length > 0) { System.IO.MemoryStream ms = new System.IO.MemoryStream(); ms.Write(ImageB, 0, ImageB.GetUpperBound(0) + 1); ImageR = System.Drawing.Image.FromStream(ms); } return ImageR; }
11 febrero 2013
C# - Algoritmos - Convertir Bytes a Imagen (2005, 2008)
10 febrero 2013
C# - Algoritmos - Convertir Imagen a Bytes (2005, 2008)
using System.Drawing; private Byte[] Get_IMAGE(Image ImageR) { Byte[] ImageB = null; if (ImageR != null) try { using (System.IO.MemoryStream ms = new System.IO.MemoryStream()) { ImageR.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg); ImageB = ms.ToArray(); } } catch (Exception) { throw; } return ImageB; }
07 febrero 2013
Firebird - Procedimientos - Llenar un campo tipo BLOB con una imagen
SET TERM ^ ; CREATE PROCEDURE UPDATE_IMAGE( CVE_REG VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8, IMAGE BLOB) RETURNS( RETVAL SMALLINT ) AS BEGIN UPDATE CAT_IMAGES SET CAT_IMAGES.IMAGE = :IMAGE WHERE CAT_IMAGES.CVE_REG = :CVE_REG; SUSPEND; END^ SET TERM ; ^
06 febrero 2013
C# - Algoritmos - Llenar DataSet Manualmente (2005, 2008)
private void Fill_DataSet() { DataSet ds = new DataSet(); ds.Tables.Add("0"); ds.Tables["0"].Columns.Add("Campo_1", Type.GetType("System.String")); ds.Tables["0"].Columns.Add("Campo_2", Type.GetType("System.String")); ds.Tables["0"].Columns.Add("Campo_3", Type.GetType("System.String")); DataRow row = ds.Tables["0"].NewRow(); row["Campo_1"] = "Rafael"; row["Campo_2"] = "Méndez"; row["Campo_3"] = "Mazariego"; ds.Tables["0"].Rows.Add(row); ds.Tables["0"].AcceptChanges(); DataGridView1.DataSource = ds.Tables["0"]; }
02 enero 2013
C# - Algoritmos - Cadenas Aleatorias (2005, 2008)
using System; using System.Text; public string RandomString(int size) { StringBuilder builder = new StringBuilder(); Random random = new Random(); char ch; for (int i = 0; i < size; i++) { ch = Convert.ToChar(Convert.ToInt32(Math.Floor(26 * random.NextDouble() + 65))); builder.Append(ch); } return builder.ToString(); }
26 diciembre 2012
C# - Apps - Mx-Menu - Download
Este es un programa creado en el lenguaje C-Sharp con la finalidad de facilitar la creación de menús desplegables que sean compatibles con las distintas plantillas de Blogger; paralelamente puede ser utilizado para crear menús de paginas webs.
Actualmente solo se facilita un tipo de menú, pero se puede configurar la mayoría de su aspecto, ya sean los colores de fondo, ancho del menú y submenus, colores de fuente, alienación de los submenus, etc. Cabe destacar que el menú es de tipo multinivel, es decir que pueden añadirse la cantidad de subniveles que sean necesarios.
This is a program created in C-Sharp in order to facilitate the creation of menus that are compatible with the different templates Blogger; parallel can be used to create menus for web pages.
Currently only facilitates a type of menu, but you can configure most of the appearance, such as the background colors, menu's width, submenu's widths, font colors, alienation of the submenus, etc. Note that the menu is multi-level, ie the amount of sublevels may be added as necessary .
Donwload: Mx-Menu
Donwload: Net Framework 2.0
25 diciembre 2012
VB.NET - Apps - Download - AutoTecleo - (2005, 2008)
Esta aplicación permite escribir automáticamente lineas de texto en alguna entrada para ello, como puede ser "Bloc de Notas", "Microsoft Word", algún tipo de Chat, la Linea de comandos del DOS, Etc.
Comprobado en Windows 7, salvo que el anti-virus puede malinterpretar este. El programa ejecutable lo pueden encontrar en la ruta: "NombreApp/NombreApp/Bin/Debug/NombreApp.Exe"
Como usarlo?
1. Ejecutar el programa
2. Escribir las lineas de texto que desean Auto-Escribir
3. Establecer numero de veces que se repetirá el mensaje
4. Establecer el intervalo de tiempo entre cada linea
5. Posicionar el cursor en donde se comenzara a Auto-Escribir el mensaje
Comprobado en Windows 7, salvo que el anti-virus puede malinterpretar este. El programa ejecutable lo pueden encontrar en la ruta: "NombreApp/NombreApp/Bin/Debug/NombreApp.Exe"
Como usarlo?
1. Ejecutar el programa
2. Escribir las lineas de texto que desean Auto-Escribir
3. Establecer numero de veces que se repetirá el mensaje
4. Establecer el intervalo de tiempo entre cada linea
5. Posicionar el cursor en donde se comenzara a Auto-Escribir el mensaje
This application can automatically write lines of text on some entry for it, such as "Notepad", "Microsoft Word", some kind of Chat, the DOS command line, Etc.
Tested on Windows 7, except that the anti-virus may misinterpret this. The executable program can be found on the route: "NameApp / NameApp / bin / Debug / NameApp.Exe"
How to use?
1. Run the program
2. Write lines of text to be Auto-Write
3. Set number of times to repeat the message
4. Set the time interval between each line
5. Position the cursor where you started Auto-Write the message
Tested on Windows 7, except that the anti-virus may misinterpret this. The executable program can be found on the route: "NameApp / NameApp / bin / Debug / NameApp.Exe"
How to use?
1. Run the program
2. Write lines of text to be Auto-Write
3. Set number of times to repeat the message
4. Set the time interval between each line
5. Position the cursor where you started Auto-Write the message
Download: NET - 2005 - AutoTecleo - V1.0 - VB
Download: NET - 2008 - AutoTecleo - V1.0 - VB
VB.NET - Apps - Código - AutoTecleo - (2005, 2008)
Public Class frm_Main 'craneodelrey@msn.com Public Send_Keys As Boolean 'Inicia o Detiene el AutoTecleo '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- 'Declaración de la función GetAsyncKeyState que se usa para leer la pulsación de las teclas F7 y F8 '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- <System.Runtime.InteropServices.DllImport("user32.dll", ExactSpelling:=True, CharSet:=System.Runtime.InteropServices.CharSet.Auto)> _ Public Shared Function GetAsyncKeyState(ByVal vkey As Integer) As Short End Function '----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>> Private Sub frm_Main_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.Send_Keys = False Me.TransparencyKey = Color.LightGray End Sub '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- 'Iniciar el AutoTecleo estableciendo Send_Keys = True, luego cambia a un tiempo de espera largo para 'no interferir durante el proceso de AutoTecleo '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- Private Sub tmr_Timer_1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tmr_Timer_1.Tick Dim Key_State As Integer Me.tmr_Timer_1.Interval = 10 Key_State = GetAsyncKeyState(Keys.F7) If Key_State < 0 Then Me.Send_Keys = True Me.tmr_Timer_1.Interval = (60) * (60) * (1000) Me.AutoSendKeys() End If End Sub '----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>> '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- 'Tratar de finalizar e interrumpir el proceso de AutoTecleo estableciendo Send_Keys = False '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- Private Sub tmr_Timer_2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tmr_Timer_2.Tick Dim Key_State As Integer Key_State = GetAsyncKeyState(Keys.F8) If Key_State < 0 Then Me.Send_Keys = False End If End Sub '----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>> '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- 'Función que realiza el AutoTecleo '<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>----<<><<>---- Private Sub AutoSendKeys() Dim Times, Lines, Count, i As Int32 Dim Interval As Decimal Dim Errors As String Dim MessageArray() As String Times = Convert.ToInt32(Me.nud_Times.Value.ToString()) Interval = Convert.ToDecimal(Me.nud_Interval.Value.ToString()) Lines = Me.txt_Message.Lines.Length Count = 0 Errors = "" If (Times <= 0) Then Errors = Errors + "Times > 0" + Chr(13) End If If (Interval <= 0) Then Errors = Errors + "Interval > 0" + Chr(13) End If If (Lines <= 0) Then Errors = Errors + "There aren't Text to Write" + Chr(13) End If If (Errors = "") Then ReDim MessageArray(Lines) For i = 0 To Lines - 1 MessageArray(i) = Me.txt_Message.Lines(i).ToString() Next While (Me.Send_Keys = True And Count < Times) For i = 0 To Lines - 1 If (Me.Send_Keys = True) Then SendKeys.SendWait(MessageArray(i)) If (i < Lines - 1) Then SendKeys.SendWait("{ENTER}") End If System.Threading.Thread.Sleep(Interval * 1000) End If Next Count = Count + 1 End While Me.Send_Keys = False Else MessageBox.Show(Errors) End If Me.tmr_Timer_1.Interval = 10 End Sub '----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>>----<>><>> End Class
30 diciembre 2005
VB.NET - Conexion SQL Server Express - (2005)
Bajar Ejemplos: Link
Como realizar una conexión remota con SQL Server 2005:
http://raziel2099.blogspot.com/2010/03/conexiones-remotas-en-sql-server-2005.html
Suscribirse a:
Entradas (Atom)

