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

 

 


Tema destacado: Curso de javascript por TickTack


  Mostrar Mensajes
Páginas: 1 ... 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 [937] 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 ... 1236
9361  Informática / Software / Re: Configuracion de Google Chrome en: 19 Marzo 2013, 13:02 pm
@OmarHack

Son Bots, esos usuarios son registros con nombres aleatórios y los mensajes se postean automáticamente del mismo modo, con scripts o software dedicado.

PD: Te lo comento para que no malgastes el tiempo hablándole a una máquina!

PD2: El spam dudo que séa ilegal en ningún país, prohibido sí (y sólo a criterio del Administrador de "X" página, no al criterio de ninguna ley), ilegal no.
En España tenemos algo que se llama "Libertad de expresión", spam virtual, spam visual, spam oral, y spam táctil, en fín los tiempos de Franco quedaron atrás...

Saludos!
9362  Programación / .NET (C#, VB.NET, ASP) / Re: Compatibilidad de fuentes TrueType personalizadas... en: 19 Marzo 2013, 11:18 am
Bueno, ya he encontrado la manera de hacerlo:

Código
  1. Public Class Main
  2.    Dim MyFont As New CustomFont(My.Resources.kakakaka)
  3.  
  4.    Private Sub Main_Disposed(sender As Object, e As System.EventArgs) Handles Me.Disposed
  5.        MyFont.Dispose()
  6.    End Sub
  7.  
  8.    Private Sub Main_Load(sender As System.Object, e As System.EventArgs) Handles Me.Load
  9.        Me.Label1.Font = New Font(MyFont.Font, 12.0!)
  10.    End Sub
  11. End Class

Saludos!
9363  Programación / .NET (C#, VB.NET, ASP) / [TUTORIAL] Instalar controles de terceros en VS2012 desde la consola de Windows. en: 19 Marzo 2013, 10:33 am
Hola!

Desde que empecé a aprender VisualStudio siempre tuve interés por poder instalar controles de una manera automatizada, ya que suelo hacer mis própios instaladores personalizados, y mis tests  con la IDE de VS en máquinas virtuales, y allí tengo que instalar cada control que necesito manuálmente...

Actualmente hay varias (pocas) aplicaciones que nos ayudan a instalar controles de forma automática, el gran problema es que todas están desactualizadas para poder instalar un control en la versión 11 de VisualStudio (VS2012), hasta ahora...

Un usuario al que le estoy muy agradecido ha renovado el source de un antiguo proyecto (TCI), es una utilidad CommandLine para poder instalar controles en cualquier versión de VS, y la verdad es que es magnifica, se instalan en pocos segundos.

Aquí tienen el source:
http://www.imagingshop.com/download/toolbox-integration.zip

Y aquí la utilidad compilada:
http://elektrostudios.tk/DTE.zip

Instrucciones de uso:
Código:
DteToolboxInstaller.exe [install|uninstall] [vs2005|vs2008|vs2010|vs2012] [tab name] [assembly path]

Por ejemplo, si quieren instalar el control "SampleControl.dll" que va incluido en el zip, en la ToolBar de VS2012, hay que usarlo de esta manera:
Código:
DteToolboxInstaller.exe install vs2012 "Nombre del TAB" "SampleControl.dll"

Artículo completo: http://www.componentowl.com/articles/visual-studio-toolbox-control-integration#integration-dte

Espero que a muchos les sirva...

Un saludo!
9364  Programación / .NET (C#, VB.NET, ASP) / Re: Calcular el tiempo restante en: 18 Marzo 2013, 19:49 pm
Ya está solucionado...

Cambiar:
Código:
RemainingTime = Now().Subtract(EndTime)

Por:
Código:
RemainingTime = EndTime.Subtract(Now)

Saludos.
9365  Programación / .NET (C#, VB.NET, ASP) / [SOLUCIONADO] Calcular el tiempo restante en: 18 Marzo 2013, 18:34 pm
Lo del tiempo transcurrido lo tengo manejado ya, pero para mostrar el tiempo restante me estoy haciendo un lío...

Código
  1.    Dim time_out as integer = 60000 ' 'Milisegundos
  2.  
  3.    Dim StartTime As DateTime ' Tiempo inicio
  4.    Dim EndTime As DateTime ' Tiempo final
  5.  
  6.    Dim ElapsedTime As TimeSpan ' Tiempo transcurrido
  7.    Dim RemainingTime As TimeSpan ' Tiempo restante

He conseguido mostrar el tiempo restante pero de una manera extraña, el problema es que, aparte de que los valores se muestran negativos, el valor de la hora y el minutero deberían ser "00"... ya que sólo estoy intentando medir el tiempo restante de una operación de "10000" MS (10 segs)

Output:


Este es el code que uso, ¿Como lo arreglo?
Código
  1. #Region " Elapsed Time Function "
  2.  
  3.    Public Function Print_Elapsed_Time()
  4.        If StartTime.ToString = "01/01/0001 0:00:00" Then
  5.            StartTime = Now
  6.            StartTime = StartTime.AddSeconds(-1)
  7.        End If
  8.        ElapsedTime = Now().Subtract(StartTime)
  9.        Return String.Format("{0:00}:{1:00}:{2:00}", CInt(Math.Floor(ElapsedTime.TotalHours)) Mod 60, CInt(Math.Floor(ElapsedTime.TotalMinutes)) Mod 60, CInt(Math.Floor(ElapsedTime.TotalSeconds)) Mod 60)
  10.    End Function
  11. #End Region
  12.  
  13. #Region " Remaining Time Function "
  14.  
  15.    Public Function Print_Remaining_Time()
  16.        If EndTime.ToString = "01/01/0001 0:00:00" Then
  17.            EndTime = Now
  18.            EndTime = EndTime.AddMilliseconds(Time_Out - 1000)
  19.        End If
  20.        RemainingTime = Now().Subtract(EndTime)
  21.        Return String.Format("{0:00}:{1:00}:{2:00}", CInt(Math.Floor(RemainingTime.TotalHours)) Mod 60, CInt(Math.Floor(RemainingTime.TotalMinutes)) Mod 60, CInt(Math.Floor(RemainingTime.TotalSeconds)) Mod 60)
  22.    End Function
  23.  
  24. #End Region
9366  Programación / .NET (C#, VB.NET, ASP) / Re: Ayuda con esta excepción! (my.settings) en: 18 Marzo 2013, 18:02 pm
Ya lo he arreglado, lo que pasa es que tenia unas carpetas con el mismo nombre de proyecto en el directorio Roaming, pero el VS debería preveer estas cosas...

Saludos!
9367  Informática / Software / Re: Configuracion de Google Chrome en: 18 Marzo 2013, 14:12 pm

xD



Código:
"...\AppData\Local\Google\Chrome\User Data"

Si no quieres complicarte, también puedes usar aplicaciones para hacer backups de Chrome, como esta: http://google-chrome-backup.en.softonic.com/

Saludos.
9368  Programación / .NET (C#, VB.NET, ASP) / [SOLUCIONADO] Ayuda con esta excepción! (my.settings) en: 18 Marzo 2013, 14:00 pm
Tengo un problema con el namespace My.Settings cuando intento modificar un valor y guardar las settings (Me sucede con cualquier propiedad...):

Código
  1.    Private Sub Button1_Click(Sender As Object, e As MouseEventArgs) Handles Button1.Click
  2.        My.Settings.Remember_Settings = True
  3.        My.Settings.Save()
  4.    End Sub

Me salta este error:



Esta es la excepción:
Código:
System.Configuration.ConfigurationErrorsException was unhandled
  BareMessage=Configuration system failed to initialize
  HResult=-2146232062
  Line=0
  Message=Configuration system failed to initialize
  Source=System.Configuration
  StackTrace:
       at System.Configuration.ClientConfigurationSystem.OnConfigRemoved(Object sender, InternalConfigEventArgs e)
       at System.Configuration.Internal.InternalConfigRoot.RemoveConfigImpl(String configPath, BaseConfigurationRecord configRecord)
       at System.Configuration.BaseConfigurationRecord.GetSectionRecursive(String configKey, Boolean getLkg, Boolean checkPermission, Boolean getRuntimeObject, Boolean requestIsHere, Object& result, Object& resultRuntimeObject)
       at System.Configuration.BaseConfigurationRecord.GetSection(String configKey)
       at System.Configuration.ConfigurationManager.GetSection(String sectionName)
       at System.Configuration.ClientSettingsStore.ReadSettings(String sectionName, Boolean isUserScoped)
       at System.Configuration.LocalFileSettingsProvider.GetPropertyValues(SettingsContext context, SettingsPropertyCollection properties)
       at System.Configuration.SettingsBase.GetPropertiesFromProvider(SettingsProvider provider)
       at System.Configuration.SettingsBase.SetPropertyValueByName(String propertyName, Object propertyValue)
       at System.Configuration.SettingsBase.set_Item(String propertyName, Object value)
       at System.Configuration.ApplicationSettingsBase.set_Item(String propertyName, Object value)
       at Volium.My.MySettings.set_Remember_Settings(Boolean value) in C:\Projects\Volium\Volium\My Project\Settings.Designer.vb:line 137
       at Volium.Form1.CheckBox_Remember_Settings_CheckedChanged(Object sender, EventArgs e) in C:\Projects\Volium\Volium\Form1.vb:line 96
       at System.Windows.Forms.CheckBox.set_CheckState(CheckState value)
       at System.Windows.Forms.CheckBox.OnClick(EventArgs e)
       at System.Windows.Forms.CheckBox.OnMouseUp(MouseEventArgs mevent)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ButtonBase.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
       at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
       at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
       at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun()
       at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel()
       at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String[] commandLine)
       at Volium.My.MyApplication.Main(String[] Args) in 17d14f5c-a337-4978-8281-53493378c1071.vb:line 81
       at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
       at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()
  InnerException: System.Configuration.ConfigurationErrorsException
       BareMessage=Unrecognized configuration section userSettings/WindowsApplication1.My.MySettings.
       Filename=C:\Users\Administrador\AppData\Local\Microsoft\Volium.vshost.exe_Url_irr03xswjdrhsokru05hku4eejmnb511\1.0.0.0\user.config
       HResult=-2146232062
       Line=4
       Message=Unrecognized configuration section userSettings/WindowsApplication1.My.MySettings. (C:\Users\Administrador\AppData\Local\Microsoft\Volium.vshost.exe_Url_irr03xswjdrhsokru05hku4eejmnb511\1.0.0.0\user.config line 4)
       Source=System.Configuration
       StackTrace:
            at System.Configuration.ConfigurationSchemaErrors.ThrowIfErrors(Boolean ignoreLocal)
            at System.Configuration.BaseConfigurationRecord.ThrowIfParseErrors(ConfigurationSchemaErrors schemaErrors)
            at System.Configuration.ClientConfigurationSystem.OnConfigRemoved(Object sender, InternalConfigEventArgs e)
       InnerException:
9369  Programación / .NET (C#, VB.NET, ASP) / Re: Librería de Snippets !! (Posteen aquí sus snippets) en: 18 Marzo 2013, 11:26 am
· String a hexadecimal:

Código
  1. #Region " String To Hex Function "
  2.  
  3.    ' [ String To Hex Function ]
  4.    '
  5.    ' Examples :
  6.    ' Dim Hex_str As String = String_To_Hex("Elektro H@cker")
  7.  
  8.    Private Function String_To_Hex(ByVal Source_String As String) As String
  9.        Dim Hex_StringBuilder As New System.Text.StringBuilder()
  10.        For Each c As Char In Source_String : Hex_StringBuilder.Append(Asc(c).ToString("x2")) : Next c
  11.        Return Hex_StringBuilder.ToString()
  12.    End Function
  13.  
  14. #End Region



· Hexadecimal a string:

Código
  1. #Region " Hex To String Function "
  2.  
  3.    ' [ Hex To String Function ]
  4.    '
  5.    ' Examples :
  6.    ' Dim str As String = Hex_To_String("456c656b74726f204840636b6572"))
  7.  
  8.    Private Function Hex_To_String(ByVal Source_String As String) As String
  9.        Dim Hex_StringBuilder As New System.Text.StringBuilder()
  10.        For x As Integer = 0 To Source_String.Length - 1 Step 2 : Hex_StringBuilder.Append(Chr(Val("&H" & Source_String.Substring(x, 2)))) : Next x
  11.        Return Hex_StringBuilder.ToString()
  12.    End Function
  13.  
  14. #End Region



· Effecto Matrix (Aplicación de consola)

Código
  1.    Module Module1
  2.        Sub Main()
  3.            Console.Title = "Matrix Effect"
  4.            Console.ForegroundColor = ConsoleColor.DarkGreen
  5.            Console.WindowLeft = InlineAssignHelper(0, 0)
  6.            Console.WindowHeight = InlineAssignHelper(Console.BufferHeight, Console.LargestWindowHeight)
  7.            Console.WindowWidth = InlineAssignHelper(Console.BufferWidth, Console.LargestWindowWidth)
  8.  
  9.            Console.CursorVisible = False
  10.            Dim width As Integer, height As Integer
  11.            Dim y As Integer()
  12.            Dim l As Integer()
  13.            Initialize(width, height, y, l)
  14.            Dim ms As Integer
  15.            While True
  16.                Dim t1 As DateTime = DateTime.Now
  17.                MatrixStep(width, height, y, l)
  18.                ms = 10 - CInt(Math.Truncate(CType(DateTime.Now - t1, TimeSpan).TotalMilliseconds))
  19.                If ms > 0 Then
  20.                    System.Threading.Thread.Sleep(ms)
  21.                End If
  22.                If Console.KeyAvailable Then
  23.                    If Console.ReadKey().Key = ConsoleKey.F5 Then
  24.                        Initialize(width, height, y, l)
  25.                    End If
  26.                End If
  27.            End While
  28.        End Sub
  29.  
  30.        Dim thistime As Boolean = False
  31.  
  32.        Private Sub MatrixStep(ByVal width As Integer, ByVal height As Integer, ByVal y As Integer(), ByVal l As Integer())
  33.            Dim x As Integer
  34.            thistime = Not thistime
  35.            For x = 0 To width - 1
  36.                If x Mod 11 = 10 Then
  37.                    If Not thistime Then
  38.                        Continue For
  39.                    End If
  40.                    Console.ForegroundColor = ConsoleColor.White
  41.                Else
  42.                    Console.ForegroundColor = ConsoleColor.DarkGreen
  43.                    Console.SetCursorPosition(x, inBoxY(y(x) - 2 - ((l(x) \ 40) * 2), height))
  44.                    Console.Write(R)
  45.                    Console.ForegroundColor = ConsoleColor.Green
  46.                End If
  47.                Console.SetCursorPosition(x, y(x))
  48.                Console.Write(R)
  49.                y(x) = inBoxY(y(x) + 1, height)
  50.                Console.SetCursorPosition(x, inBoxY(y(x) - l(x), height))
  51.                Console.Write(" "c)
  52.            Next
  53.        End Sub
  54.  
  55.        Private Sub Initialize(ByRef width As Integer, ByRef height As Integer, ByRef y As Integer(), ByRef l As Integer())
  56.            Dim h1 As Integer
  57.            Dim h2 As Integer = (InlineAssignHelper(h1, (InlineAssignHelper(height, Console.WindowHeight)) \ 2)) \ 2
  58.            width = Console.WindowWidth - 1
  59.            y = New Integer(width - 1) {}
  60.            l = New Integer(width - 1) {}
  61.            Dim x As Integer
  62.            Console.Clear()
  63.            For x = 0 To width - 1
  64.                y(x) = m_r.[Next](height)
  65.                l(x) = m_r.[Next](h2 * (If((x Mod 11 <> 10), 2, 1)), h1 * (If((x Mod 11 <> 10), 2, 1)))
  66.            Next
  67.        End Sub
  68.  
  69.        Dim m_r As New Random()
  70.        Private ReadOnly Property R() As Char
  71.            Get
  72.                Dim t As Integer = m_r.[Next](10)
  73.                If t <= 2 Then
  74.                    Return ChrW(CInt(AscW("0"c)) + m_r.[Next](10))
  75.                ElseIf t <= 4 Then
  76.                    Return ChrW(CInt(AscW("a"c)) + m_r.[Next](27))
  77.                ElseIf t <= 6 Then
  78.                    Return ChrW(CInt(AscW("A"c) + m_r.[Next](27)))
  79.                Else
  80.                    Return ChrW(m_r.[Next](32, 255))
  81.                End If
  82.            End Get
  83.        End Property
  84.  
  85.        Public Function inBoxY(ByVal n As Integer, ByVal height As Integer) As Integer
  86.            n = n Mod height
  87.            If n < 0 Then
  88.                Return n + height
  89.            Else
  90.                Return n
  91.            End If
  92.        End Function
  93.        Private Function InlineAssignHelper(Of T)(ByRef target As T, ByVal value As T) As T
  94.            target = value
  95.            Return value
  96.        End Function
  97.  
  98.    End Module
9370  Programación / Scripting / Re: con que extecion guardo los Scripting bash para que se ejecuten en backtrack en: 18 Marzo 2013, 09:42 am
ScriptBash.sh

Saludos
Páginas: 1 ... 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 [937] 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 ... 1236
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines