Compartir a través de


Método View.ScrollShapeIntoView (Publisher)

Desplaza la ventana de la publicación para que la forma especificada se muestre en la ventana o el panel de la publicación.

Sintaxis

expresión. ScrollShapeIntoView (Forma)

expresión Variable que representa un objeto View .

Parameters

Nombre Obligatorio/opcional Tipo de datos Descripción
Shape Obligatorio Shape Forma que se va a desplazar a vista.

Ejemplo

En este ejemplo se agrega una forma a la página nueva y se desplaza la vista actual a la nueva forma.

Sub ScrollIntoView() 
 Dim shpStar As Shape 
 Dim intWidth As Integer 
 Dim intHeight As Integer 
 
 With ActiveDocument 
 intWidth = .PageSetup.PageWidth 
 intWidth = (intWidth / 2) - 75 
 intHeight = .PageSetup.PageHeight 
 intHeight = (intHeight / 2) - 75 
 
 With .Pages.Add(Count:=1, After:=ActiveDocument.Pages.Count) 
 Set shpStar = .Shapes.AddShape(Type:=msoShape5pointStar, _ 
 Left:=intWidth, Top:=intHeight, Width:=150, Height:=150) 
 shpStar.TextFrame.TextRange.Text = "New Star Shape" 
 End With 
 End With 
 
 ActiveView.ScrollShapeIntoView Shape:=shpStar 
 
End Sub

Soporte técnico y comentarios

¿Tiene preguntas o comentarios sobre VBA para Office o esta documentación? Vea Soporte técnico y comentarios sobre VBA para Office para obtener ayuda sobre las formas en las que puede recibir soporte técnico y enviar comentarios.