En el foro no se hacen tareas, lo siento. Pero puedes publicar un nuevo post mostrando tus progresos y formulando una pregunta específica.
Tema Cerrado.
Tema Cerrado.
Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.
Mostrar Mensajes MenúCita de: Orubatosu en 24 Noviembre 2017, 10:48 AM
Claro... ahora imagina que lo mismo ocurre en EEUU, que se les "escapa" una nube de material radioactivo y se extiende sobre Mexico, Guatemala, Honduras, ¡ Cuba !
Toda internet estaría en llamas porque "el malvado imperio del mal contamina a sus vecinos"
Pero mira, lo hace Rusia... y no pasa nada, solo es una nubecilla
Cita de: _CrisiS_ en 6 Diciembre 2017, 00:32 AMComo veran en la imagen, pude lograrlo con este codigo pero con ese codigo solo me figura el control al momento de correr la aplicacion, yo lo quiero ver desde la ventana de diseño para poder cambiar su ubicacion y no salir en un formulario en una ubicacion estandar
Imports System
Imports System.ComponentModel
Imports System.Diagnostics
Imports System.Runtime.InteropServices
Imports System.Windows.Forms
<ClassInterface(ClassInterfaceType.AutoDispatch)>
<ComVisible(True)>
<DefaultBindingProperty("Value")>
<DefaultEvent("ValueChanged")>
<DefaultProperty("Value")>
Public Class TimePicker : Inherits DateTimePicker
<Bindable(True)>
<Browsable(True)>
<EditorBrowsable(EditorBrowsableState.Always)>
<RefreshProperties(RefreshProperties.All)>
Public Overloads Property Value As TimeSpan
Get
Return MyBase.Value.TimeOfDay
End Get
Set(value As TimeSpan)
MyBase.Value = DateTime.Today + value
End Set
End Property
Public Sub New()
Me.Format = DateTimePickerFormat.Time
Me.ShowUpDown = True
Me.Value = TimeSpan.Zero ' Me.Value = MyBase.Value.TimeOfDay
' Me.Width = 100
End Sub
End Class
' ***********************************************************************
' Author : Elektro
' Modified : 06-December-2017
' ***********************************************************************
#Region " Public Members Summary "
#Region " Constructors "
' New()
#End Region
#Region " Properties "
' Value As TimeSpan
#End Region
#End Region
#Region " Option Statements "
Option Strict On
Option Explicit On
Option Infer Off
#End Region
#Region " Imports "
Imports System
Imports System.ComponentModel
Imports System.Diagnostics
Imports System.Drawing
Imports System.Runtime.InteropServices
Imports System.Windows.Forms
Imports System.Windows.Forms.Design
' Imports ElektroKit.UserControls.Designers
#End Region
#Region " ElektroTimePicker "
' Namespace ElektroKit.UserControls
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Represents a control that allows the user to select an hour,
''' and to display the time with a specified format.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
<DisplayName("ElektroTimePicker")>
<Description("A extended DateTimePicker control that only displays the time.")>
<DesignTimeVisible(True)>
<DesignerCategory("UserControl")>
<ToolboxBitmap(GetType(DateTimePicker), "DateTimePicker.bmp")>
<ToolboxItemFilter("System.Windows.Forms", ToolboxItemFilterType.Require)>
<ClassInterface(ClassInterfaceType.AutoDispatch)>
<ComVisible(True)>
<DefaultBindingProperty("Value")>
<DefaultEvent("ValueChanged")>
<DefaultProperty("Value")>
<Designer(GetType(ElektroTimePickerDesigner))>
Public Class ElektroTimePicker : Inherits DateTimePicker
#Region " Properties "
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Gets or sets the time value assigned to the control.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
''' <value>
''' The time value assigned to the control.
''' </value>
''' ----------------------------------------------------------------------------------------------------
<Bindable(True)>
<Browsable(True)>
<EditorBrowsable(EditorBrowsableState.Always)>
<RefreshProperties(RefreshProperties.All)>
Public Overloads Property Value As TimeSpan
Get
Return MyBase.Value.TimeOfDay
End Get
Set(value As TimeSpan)
MyBase.Value = DateTime.Today + value
End Set
End Property
#End Region
#Region " Constructors "
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Initializes a new instance of the <see cref="ElektroTimePicker"/> class.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
Public Sub New()
Me.CustomFormat = "HH:mm:ss" ' 24-hour format.
Me.Format = DateTimePickerFormat.Custom
Me.ShowUpDown = True
Me.Value = TimeSpan.Zero
' Me.Value = MyBase.Value.TimeOfDay
Me.Width = Me.MinimumSize.Width
Me.AdjustControlWidth()
End Sub
#End Region
#Region " Event Invocators "
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Raises the <see cref="ElektroTimePicker.FontChanged"/> event.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
''' <param name="e">
''' An <see cref="EventArgs"/> that contains the event data.
''' </param>
''' ----------------------------------------------------------------------------------------------------
Protected Overrides Sub OnFontChanged(ByVal e As EventArgs)
If (Me.DesignMode) Then
Me.AdjustControlWidth()
End If
MyBase.OnFontChanged(e)
End Sub
#End Region
#Region " Overridable Methods "
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Grows the control width to fit the text displayed.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
Protected Overridable Sub AdjustControlWidth()
Using g As Graphics = Me.CreateGraphics()
Dim textSize As SizeF = g.MeasureString(Me.Text, Me.Font)
If (textSize.Width > Me.Width) Then
Me.Width = CInt(Math.Ceiling(Size.Width)) * 2
End If
End Using
End Sub
#End Region
End Class
' End Namespace
#End Region
' ***********************************************************************
' Author : Elektro
' Modified : 06-December-2017
' ***********************************************************************
#Region " Option Statements "
Option Strict On
Option Explicit On
Option Infer Off
#End Region
#Region " Imports "
Imports System
Imports System.Collections
Imports System.Diagnostics
Imports System.Windows.Forms.Design
#End Region
#Region " ElektroTimePickerDesigner "
' Namespace ElektroKit.UserControls.Designers
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Extends the design mode behavior of a <see cref="ElektroTimePicker"/> control.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
''' <seealso cref="ElektroTimePicker"/>
''' ----------------------------------------------------------------------------------------------------
<DebuggerStepThrough>
Public NotInheritable Class ElektroTimePickerDesigner : Inherits ControlDesigner
''' ----------------------------------------------------------------------------------------------------
''' <summary>
''' Provides design-time support for the <see cref="ElektroTimePicker"/> control.
''' </summary>
''' ----------------------------------------------------------------------------------------------------
''' <param name="properties">
''' Ab <see cref="IDictionary"/> that contains the properties for the class of the component.
''' </param>
''' ----------------------------------------------------------------------------------------------------
Protected Overrides Sub PreFilterProperties(ByVal properties As IDictionary)
MyBase.PreFilterAttributes(properties)
Dim propertyNames As String() = {
"CalendarFont",
"CalendarForeColor",
"CalendarMonthBackground",
"CalendarTitleBackColor",
"CalendarTitleForeColor",
"CalendarTrailingForeColor",
"CustomFormat",
"DropDownAlign",
"Format",
"MaxDate",
"MinDate",
"ShowUpDown"
}
For Each propertyName As String In propertyNames
properties.Remove(propertyName)
Next
End Sub
End Class
' End Namespace
#End Region
Cita de: r1f1 en 3 Diciembre 2017, 09:34 AMTengo conocimientos básicos de c/c++ y de POO (muy muy básicos) y lo primero es saber si este este lenguaje es el apropiado para lo que quiero hacer
Cita de: r1f1 en 3 Diciembre 2017, 09:34 AMen unos sitios me ponen que es mejor java, luego en otros que use visual studio con c# y me saturé, vengo aquí a ver si alguien me puede aclarar algo o más o menos indicarme por donde debo empezar.