This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
‘ Programa para llenar automáticamente un formulario en word | |
‘ Lo que está escrito con comilla simple son solo comentarios para explicar el programas, pueden omitirse | |
‘ With… EndWith sirve para no tener que repetir la misma instrucción en cada línea, en este caso Selection | |
‘ | |
With Selection | |
.ParagraphFormat.LineSpacingRule = wdLineSpaceSingle ‘Coloca espacio de líneas en “espacio simple” | |
.TypeParagraph ‘Pasa a linea siguiente | |
.TypeParagraph ‘Pasa a linea siguiente | |
.Font.Bold = True ‘Coloca negrita | |
.TypeParagraph ‘Pasa a linea siguiente |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub formulario1() | |
‘ | |
‘ formulario1 Macro | |
‘ Macro creada el 26/07/2010 por INTEL | |
‘ | |
UserForm1.show | |
End Sub |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Application.PrintOut FileName:=”Permiso.doc”, Range:=wdPrintCurrentPage, Item:= _ | |
wdPrintDocumentContent, Copies:=1, Pages:=”", PageType:=wdPrintAllPages, _ | |
Collate:=True, Background:=True, PrintToFile:=False | |
Selection.WholeStory | |
Selection.Delete Unit:=wdCharacter, Count:=1 | |
Unload UserForm1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Curso VBA-8Sub Macro2() | |
‘ | |
‘ Macro2 Macro | |
‘ Macro grabada el 24-12-98 por TOMAS BRADANOVIC | |
‘ | |
If ActiveWindow.View.SplitSpecial <> wdPaneNone Then | |
ActiveWindow.Panes(2).Close | |
End If | |
If ActiveWindow.ActivePane.View.Type = wdNormalView Or ActiveWindow. _ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Private Sub CommandButton1_Click() | |
With Selection | |
. Font.Size = Val(10) | |
. ParagraphFormat.LineSpacingRule = wdLineSpaceSingle | |
. TypeParagraph | |
. Font.Name = “arial black” | |
. ParagraphFormat.Alignment = wdAlignParagraphCenter | |
. TypeText Text:=vbTab & “Programa de Prueba” | |
. ParagraphFormat.Alignment = wdAlignParagraphLeft | |
. TypeParagraph |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean) | |
TextBox1.Text = UCase(TextBox1.Text) | |
End Sub |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub prueba1() | |
UserForm1.show | |
End Sub |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Private Sub CommandButton1_Click() | |
tdolares.Text = “” | |
tpesos.Text = “” | |
End Sub | |
Private Sub tdolares_Change() | |
End Sub | |
Private Sub tdolares_Exit(ByVal Cancel As MSForms.ReturnBoolean) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Private Sub CommandButton1_Click() | |
tdolares.Text = “” | |
tpesos.Text = “” | |
End Sub |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Private Sub tpesos_Exit(ByVal Cancel As MSForms.ReturnBoolean) | |
tdolares.text = Val(tpesos.text) /500 | |
End Sub |