![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
hi, my name is Mariya. Now i am working on vb.net. i have some problems with inserting a chart on the slide. i have insert a slide having 'PptlayoutText' layout. i went through the each shape. now i want to insert a chart of any desired type on this slide. but i cant. i have added the reference of Microsoft graph. where should i write the code for it? and which method i have to use? following is my code, pptApplication = CType(applicationObject, PowerPoint.Application) Dim slideCount As Integer slideCount = pptApplication.ActivePresentation.Slides.Count slideCount = slideCount + 1 ' inserting a slide currentslide = pptApplication.ActivePresentation.Slides.Add(index :=slideCount, Layout:=PpSlideLayout.ppLayoutText) Dim shapeNumber As Integer = 0 With currentslide For Each oShape In currentslide.Shapes 'going through each shape If shapeNumber = 0 Then oShape.Name = "myText1" oShape.TextFrame.TextRange.Text = "Enter your h question....." ElseIf shapeNumber = 1 Then oShape.Name = "myText2" oShape.TextFrame.TextRange.Text = "Enter your answer options....." oShape.TextFrame.TextRange.ParagraphFormat.Bullet. Style = PpNumberedBulletStyle.ppBulletAlphaLCPeriod oShape = currentslide.Shapes.AddOLEObject(Left:=100, Top:=100, Width:=350, Height:=200, ClassName:="MsGraph.Chart") obj = oShape.OLEFormat.Object obj.ChartType = XlChartType.xl3DPie End If shapeNumber += 1 Next End With Waiting for ur reply. can you plz send the reply as soon as possible. its urgent! thanks!! |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |