elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.


Tema destacado: (TUTORIAL) Aprende a emular Sentinel Dongle By Yapis


  Mostrar Mensajes
Páginas: 1 ... 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 [958] 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 ... 1258
9571  Programación / .NET (C#, VB.NET, ASP) / Re: Visual Basic 2008 Duda en: 20 Marzo 2013, 00:29 am
Creo que a lo que raul338 se refería es que muestres la parte del código de las variables para especificar el tipo de variable que es, aparte del contenido y de las modificaciones que le hagas...

Ya queda menos, Ahora sólo falta que especifiques lo que intentas hacer...

Saludos!
9572  Programación / Scripting / Re: ¿¿Se puede ocultar la pantalla de comando en el siguiente código?? en: 19 Marzo 2013, 21:11 pm
Pero si tienes el código, ¿porque no lo pruebas tu mismo para salir de dudas? xD

Ese code lo único que hace es mostrar una Caja de texto usando VisualBasicScript.

Usa el buscador del foro...

Código
  1. set ws = wscript.createobject("WScript.shell")
  2. ws.run("notepad.exe"), 0, true

Ahora no dispongo de tiempo, debes modificar los argumentos (%1 %2 %3) del BAT para usar ese code VBS.

Saludos!
9573  Foros Generales / Dudas Generales / Re: No puedo leer correos desde la página de Hotmail o.O en: 19 Marzo 2013, 21:03 pm
https://www.mozilla.org/es-ES/thunderbird/ xD

Has probado entrar desde Outlook ? Ahora que están con el transpaso igual la han liado xD

Nunca me ha gustado el Outlook, y lo tengo capado en los Windows que uso sin forma de testearlo xD.
probaré desde la aplicación de Mozilla (que no recordaba el nombre), gracias!
9574  Programación / .NET (C#, VB.NET, ASP) / Re: Librería de Snippets !! (Posteen aquí sus snippets) en: 19 Marzo 2013, 20:57 pm
Esta función es para escribir "hints" (o "cues") en los TextBox por ejemplo.

Código
  1. #Region " Set Control Hint Function "
  2.  
  3.    ' [ Set Control Hint Function ]
  4.    '
  5.    ' Examples :
  6.    ' Set_Control_Hint(TextBox1, "Put text here...")
  7.  
  8.    <System.Runtime.InteropServices.DllImport("user32.dll", CharSet:=System.Runtime.InteropServices.CharSet.Auto)> _
  9.    Private Shared Function SendMessage(ByVal hWnd As IntPtr, ByVal msg As Integer, ByVal wParam As Integer, <System.Runtime.InteropServices.MarshalAs(System.Runtime.InteropServices.UnmanagedType.LPWStr)> ByVal lParam As String) As Int32
  10.    End Function
  11.  
  12.    Private Function Set_Control_Hint(ByVal control As Control, ByVal text As String) As Boolean
  13.        Try
  14.            SendMessage(control.Handle, &H1501, 0, text)
  15.            Return True
  16.        Catch ex As Exception
  17.            Throw New Exception(ex.Message)
  18.        End Try
  19.    End Function
  20.  
  21. #End Region



Enviar POST por PHP:

Código
  1. #Region " Send POST PHP Function "
  2.  
  3.    ' [ Send POST PHP Function ]
  4.    '
  5.    ' Examples :
  6.    ' Dim htmlcode As String = PHP("http://somesite.com/somephpfile.php", "POST", "name=Jim&age=27&pizza=suasage")
  7.  
  8.    Public Function Send_POST_PHP(ByVal URL As String, ByVal Method As String, ByVal Data As String) As String
  9.        Try
  10.            Dim request As System.Net.WebRequest = System.Net.WebRequest.Create(URL)
  11.            request.Method = Method
  12.            Dim postData = Data
  13.            Dim byteArray As Byte() = System.Text.Encoding.UTF8.GetBytes(postData)
  14.            request.ContentType = "application/x-www-form-urlencoded"
  15.            request.ContentLength = byteArray.Length
  16.            Dim dataStream As System.IO.Stream = request.GetRequestStream()
  17.            dataStream.Write(byteArray, 0, byteArray.Length)
  18.            dataStream.Close()
  19.            Dim response As System.Net.WebResponse = request.GetResponse()
  20.            dataStream = response.GetResponseStream()
  21.            Dim reader As New System.IO.StreamReader(dataStream)
  22.            Dim responseFromServer As String = reader.ReadToEnd()
  23.            reader.Close()
  24.            dataStream.Close()
  25.            response.Close()
  26.            Return (responseFromServer)
  27.        Catch ex As Exception
  28.            Dim PHP_Error As String = ErrorToString()
  29.            If PHP_Error = "Invalid URI: The format of the URI could not be determined." Then
  30.                MsgBox("ERROR! Must have HTTP:// before the URL.")
  31.            Else
  32.                Throw New Exception(ex.Message)
  33.            End If
  34.            Return ("ERROR")
  35.        End Try
  36.    End Function
  37.  
  38. #End Region
9575  Foros Generales / Dudas Generales / No puedo leer correos desde la página de Hotmail o.O en: 19 Marzo 2013, 20:48 pm
Bueno pues llevo 2 o 3 días así (y me parece que no soy el único):



¿Le pasa algo al servicio de Microsoft?, me parece algo fuera de lo normal porque he testeado desde Firefox, desde chrome, con una limpieza prévia de cookies porsupuesto, en mi Windows, y en VirtualBox, no me deja pinchar en ningún correo de entrada!
y necesito leer un correo importante pero ahora mismo no se me ocurre ningún soft con el que poder leer los correos de Hotmail, ¿Alguna sugerencia?.
9576  Programación / .NET (C#, VB.NET, ASP) / Re: Librería de Snippets !! (Posteen aquí sus snippets) en: 19 Marzo 2013, 18:52 pm
Grabar audio del PC:

Código
  1. #Region " Rec Sound Function "
  2.  
  3.    ' [ Rec Sound Function ]
  4.    '
  5.    ' Examples :
  6.    ' Rec_Sound("C:\Audio.wav", Rec.Start_Record)
  7.    ' Rec_Sound("C:\Audio.wav", Rec.Stop_Record)
  8.  
  9.    Private Declare Function mciSendString Lib "winmm.dll" Alias "mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As String, ByVal uReturnLength As Integer, ByVal hwndCallback As Integer) As Integer
  10.  
  11.    Public Enum Rec
  12.        Start_Record
  13.        Stop_Record
  14.    End Enum
  15.  
  16.    Private Function Rec_Sound(ByVal Path As String, ByVal Rec As Rec) As Boolean
  17.        Select Case Rec
  18.            Case Rec.Start_Record
  19.                mciSendString("open new Type waveaudio Alias recsound", "", 0, 0)
  20.                mciSendString("record recsound", "", 0, 0)
  21.                Return True
  22.            Case Rec.Stop_Record
  23.                mciSendString("save recsound " & Path & "", "", 0, 0)
  24.                mciSendString("close recsound", "", 0, 0)
  25.                Return True
  26.            Case Else : Return Nothing
  27.        End Select
  28.    End Function
  29.  
  30. #End Region
9577  Programación / Scripting / Re: Necesito ayuda para crear un batch para iniciar la rom de este emulador. en: 19 Marzo 2013, 18:16 pm
Desde un principio te comenté que buscases el nombre real del emulador y visitases la página oficial del emulador para encontrar la documentación que necesitas...

Bueno, el emulador es el "Nebula", página oficial: http://nebula.emulatronia.com , esto te lo digo sólo por si alguna otra vez vuelves a tener conflictos.

El problema es que este emulador no acepta comillas dobles en los argumentos (algo extraño), así que debes usarlo de la siguiente manera:

Código:
Emulator.exe daytona

(Tachán!)

Un saludo!
9578  Programación / Scripting / Re: Base de datos desde archivo de texto. en: 19 Marzo 2013, 18:06 pm
No hay problema...

Este script sólamente comprueba el valor de la última línea.



PD: Las explicaciones están en el código.

Código:
@Echo OFF
SETLOCAL ENABLEDELAYEDEXPANSION

Set /A "Max=100"
Set /A "Interval=10"
Set /A "LastFileSize=0"
Set /A "CurrentFileSize=0"

Set "File=C:\Users\Administrador\Desktop\1.txt"

:Loop

REM Comprueba el tamaño actual del archivo LOG
For %%F in ("%File%") Do (Set /A "CurrentFileSize=%%~zF")

REM Si el tamaño actual no es igual al ultimo tamaño registrado [Es decir, si el LOG se ha actualizado...]
If %CurrentFileSize% NEQ %LastFileSize% (
Set /A "LastFileSize=%CurrentFileSize%"

Echo [%TIME:~0,-3%] Comprobando actualización del LOG...
For /F "Usebackq Tokens=1-3* Delims= " %%A in ("%File%") Do (Set /A "Value=%%C")

REM Si el valor es mayor que X...
If !Value! GTR %MAX% (
Echo [%TIME:~0,-3%] Valor: "!Value!" es mayor que "%MAX%".
Echo [%TIME:~0,-3%] Enviando e-mail...
rem Zulc.exe -receivers="tuemail@hot.com" -remarks="Test remark" -subject="Test subject")
) ELSE (
Echo [%TIME:~0,-3%] Valor: "!Value!" Todo Correcto.
)

) ELSE (
REM De lo contrario...
Echo [%TIME:~0,-3%] Nada que comprobar.
)
(Ping -n %INTERVAL% Localhost >NUL) & (GOTO :LOOP)
9579  Programación / .NET (C#, VB.NET, ASP) / Re: Librería de Snippets !! (Posteen aquí sus snippets) en: 19 Marzo 2013, 17:34 pm
Código:
Minimizar la IDE del VisualStudio cuando la APP está en debug:

[code=vbnet]#Region " Minimize VS IDE when APP is in execution "

    Declare Function ShowWindow Lib "User32.dll" (ByVal hwnd As IntPtr, ByVal nCmdShow As UInteger) As Boolean

    ' Minimize VS IDE when APP is in execution
    Private Sub Minimize_VS_IDE_when_APP_is_in_execution(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
#If DEBUG Then
        Dim Pr() As Process = Process.GetProcesses
        For Each P As Process In Pr
            If P.MainWindowTitle.Contains(My.Application.Info.AssemblyName) Then
                Dim hwnd As IntPtr = P.MainWindowHandle
                ShowWindow(hwnd, 6)
                Exit For
            End If
        Next
#End If
    End Sub

#End Region



Redondear los bordes de cualquier control:

Código
  1. #Region " Round Borders "
  2.  
  3.    ' [ Round Borders ]
  4.    '
  5.    ' Examples :
  6.    ' Round_Border(TextBox1)
  7.    ' Round_Border(PictureBox1, 100)
  8.  
  9.    Private Sub Round_Borders(ByVal vbObject As Object, Optional ByVal RoundSize As Integer = 20)
  10.        Try
  11.            Dim p As New Drawing2D.GraphicsPath()
  12.            p.StartFigure()
  13.            p.AddArc(New Rectangle(0, 0, RoundSize, RoundSize), 180, 90)
  14.            p.AddLine(RoundSize, 0, vbObject.Width - RoundSize, 0)
  15.            p.AddArc(New Rectangle(vbObject.Width - RoundSize, 0, RoundSize, RoundSize), -90, 90)
  16.            p.AddLine(vbObject.Width, RoundSize, vbObject.Width, vbObject.Height - RoundSize)
  17.            p.AddArc(New Rectangle(vbObject.Width - RoundSize, vbObject.Height - RoundSize, RoundSize, RoundSize), 0, 90)
  18.            p.AddLine(vbObject.Width - RoundSize, vbObject.Height, RoundSize, vbObject.Height)
  19.            p.AddArc(New Rectangle(0, vbObject.Height - RoundSize, RoundSize, RoundSize), 90, 90)
  20.            p.CloseFigure()
  21.            vbObject.Region = New Region(p)
  22.        Catch ex As Exception : Throw New Exception(ex.Message)
  23.        End Try
  24.    End Sub
  25.  
  26. #End Region



Decodificar URL:

Código
  1. #Region " URL Decode Function "
  2.  
  3.    ' [ URL Decode Function ]
  4.    '
  5.    ' Examples :
  6.    ' Dim URL As String = URL_Decode("http%3A%2F%2Fwww%2Esomesite%2Ecom%2Fpage%2Easp%3Fid%3D5%26test%3DHello+World")
  7.  
  8.    Public Function URL_Decode(ByVal Source As String) As String
  9.        Dim x As Integer = 0
  10.        Dim CharVal As Byte = 0
  11.        Dim sb As New System.Text.StringBuilder()
  12.        For x = 0 To (Source.Length - 1)
  13.            Dim c As Char = Source(x)
  14.            If (c = "+") Then
  15.                sb.Append(" ")
  16.            ElseIf c <> "%" Then
  17.                sb.Append(c)
  18.            Else
  19.                CharVal = Int("&H" & Source(x + 1) & Source(x + 2))
  20.                sb.Append(Chr(CharVal))
  21.                x += 2
  22.            End If
  23.        Next
  24.        Return sb.ToString()
  25.    End Function
  26.  
  27. #End Region



Codificar URL:

Código
  1. #Region " URL Encode Function "
  2.  
  3.    ' [ URL Encode Function ]
  4.    '
  5.    ' Examples :
  6.    ' Dim URL As String = URL_Encode("http://www.somesite.com/page.asp?id=5&test=Hello World")
  7.  
  8.    Public Function URL_Encode(ByVal Source As String) As String
  9.        Dim chars() As Char = Source.ToCharArray()
  10.        Dim sb As New System.Text.StringBuilder()
  11.        For Each c As Char In chars
  12.            If c Like "[A-Z-a-z-0-9]" Then
  13.                sb.Append(c)
  14.            ElseIf c = " " Then
  15.                sb.Append("+")
  16.            Else
  17.                Dim sHex As String = Hex(Asc(c))
  18.                sHex = "%" & sHex.PadLeft(2, "0")
  19.                sb.Append(sHex)
  20.            End If
  21.        Next
  22.        Erase chars ' Clean Up
  23.        Return sb.ToString()
  24.    End Function
  25.  
  26. #End Region

[/code]
9580  Programación / Desarrollo Web / Re: ¿ Como cambiar el fondo de color ? en: 19 Marzo 2013, 16:02 pm
El color naranja de tu htm es eso, un color sólido.

El gradiante no es un color, es un efecto de varios tonos de colores conjuntos, y los estilos (efectos, gradiantes) se hacen manejando CSS, si usas DreamWeaver los estilos de CSS te los hace en 1 segundo casi sin esfuerzo vaya!

Un saludo!
Páginas: 1 ... 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 [958] 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 ... 1258
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines