Red de conocimiento informático - Problemas con los teléfonos móviles - Una pregunta en VBA

Una pregunta en VBA

1) Asignación

2)

Cuando este método se aplica al objeto Formas, devuelve un objeto Forma que representa la nueva Autoforma en la hoja de trabajo. . Cuando se aplica a un objeto CanvasShapes, este método devuelve un objeto Shape que representa la nueva autoforma en el lienzo de dibujo.

expresión.AddShape(Tipo, Izquierda, Superior, Ancho, Alto)

la expresión es obligatoria. Esta expresión devuelve un objeto Formas.

Tipo MsoAutoShapeType, obligatorio. Especifique el tipo de autoforma que desea crear.

MsoAutoShapeType puede ser una de las siguientes constantes MsoAutoShapeType.

msoShape16pointStar

msoShape24pointStar

msoShape32pointStar

msoShape4pointStar

msoShape5pointStar

msoShape8pointStar

msoShape8pointStar

p>

msoShape8pointStar

p>

msoShapeActionButtonBackorPrevious

msoShapeActionButtonBeginning

msoShapeActionButtonCustom

msoShapeActionButtonDocument

msoShapeActionButtonEnd

msoShapeActionButtonForwardorNext

msoShapeActionButtonHelp

msoShapeActionButtonHome

msoShapeActionButtonInformation

msoShapeActionButtonMovie

msoShapeActionButtonReturn

msoShapeActionButtonSound

msoShapeArc

msoShapeBalloon

msoShapeBentArrow

msoShapeBentUpArrow

msoShapeBevel

msoShapeBlockArc

msoShapeCan

msoShapeChevron

msoShapeCircularArrow

msoShapeCloudCallout

msoShapeCross

msoShapeCube

msoShapeCurvedDownArrow

p>

msoShapeCurvedDownRibbon

msoShapeCurvedLeftArrow

msoShapeCurvedRightArrow

msoShapeCurvedUpArrow

msoShapeCurvedUpRibbon

msoShapeDiamond

msoShapeDonut

msoShapeDoubleBrace

msoShapeDoubleBracket

msoShapeDoubleWave

msoShapeDownArrow

msoShapeDownArrowCallout

msoShapeDownRibbon

msoShapeExplosion1

msoShapeExplosion2

msoShapeFlowchartAlternateProcess

msoShapeFlowchartCard

msoShapeFlowch

artCollate

msoShapeFlowchartConnector

msoShapeFlowchartData

msoShapeFlowchartDecision

msoShapeFlowchartDelay

msoShapeFlowchartDirectAccessStorage

msoShapeFlowchartDisplay

msoShapeFlowchartDocument

msoShapeFlowchartExtract

msoShapeFlowchartInternalStorage

msoShapeFlowchartMagneticDisk

msoShapeFlowchartManualInput

msoShapeFlowchartManualOperation

msoShapeFlowchartMerge

msoShapeFlowchartMultidocument

msoShapeFlowchartOffpageConnector

msoShapeFlowchartOr

msoShapeFlowchartPredefinidoProceso

msoShapeFlowchartPreparation

msoShapeFlowchartProcess

msoShapeFlowchartPunchedTape

msoShapeFlowchartSequentialAccessStorage

msoShapeFlowchartSort

msoShapeFlowchartStoredData

msoShapeFlowchartSummingJunction

msoShapeFlowchartTerminator

msoShapeFoldedCorner

msoShapeHeart

msoShapeHexagon

msoShapeHorizontalScroll

msoShapeIsoscelesTriangle

msoShapeLeftArrow

msoShapeLeftArrowCallout

msoShapeLeftBrace

msoShapeLeftBracket

msoShapeLeftRightArrow

msoShapeLeftRightArrowCallout

msoShapeLeftRightUpArrow

msoShapeLeftUpArrow

msoShapeLightningBolt

msoShapeLineCallout1

msoShapeLineCallout1AccentBar

msoShapeLineCallout1Bordera

ndaccentbar

MsoshapelineCallout1noborder

MsoshapelineCallout2

MSOShapeelLLLLET2ACENT2ACENT2AR

MsoshapelineCalllet2Bor2back DERANDAACCENTBAR

MsoshapelineCallout2nobord

MsoshapelineCallout3

msoShapeLineCallout3AccentBar

msoShapeLineCallout3BorderandAccentBar

msoShapeLineCallout3NoBorder

msoShapeLineCallout4

msoShapeLineCallout4AccentBar

msoShapeLineCallout4BorderandAccentBar

msoShapeLineCallout4NoBorder

msoShapeMixed

msoShapeMoon

msoShapeNoSymbol

msoShapeNotchedRightArrow

msoShapeNotPrimitive

msoShapeOctagon

msoShapeOval

msoShapeOvalCallout

msoShapeParallelogram

msoShapePentagon

msoShapePlaque

msoShapeQuadArrow

msoShapeQuadArrowCallout

msoShapeRectangle

msoShapeRectangularCallout

msoShapeRegularPentagon

msoShapeRightArrow

msoShapeRightArrowCallout

msoShapeRightBrace

msoShapeRightBracket

msoShapeRightTriangle

msoShapeRoundedRectangle

msoShapeRoundedRectangularCallout

msoShapeSmileyFace

msoShapeStripedRightArrow

msoShapeSun

msoShapeTrapezoid

msoShapeUpArrow

msoShapeUpArrowCallout

msoShapeUpDownArrow

msoShapeUpDownArrowCallout

msoShapeUpRibbon

msoShapeUTurnArrow

msoS

hapeVerticalScroll

msoShapeWave

Left , Top Tipo único, obligatorio. Proporciona la posición de la esquina superior izquierda del borde de la Autoforma, en puntos, en relación con la esquina superior izquierda del documento.

Ancho, Alto Tipo único, requerido. Proporciona el ancho y alto del borde de la autoforma en puntos.

Descripción

Para cambiar el tipo de una Autoforma agregada, establezca la propiedad AutoShapeType.

Ejemplo

Este ejemplo agrega un rectángulo a myDocument.

Establecer myDocument = Worksheets(1)

myDocument.Shapes.AddShape msoShapeRectangle, 50, 50, 100, 200