Textbox

  • Thread starter Thread starter majikman
  • Start date Start date
M

majikman

I want to write some vba code that when the user enters the BeforeSav
event, it will save the content of text boxes that have been inserte
into a chart onto another excel workbook. how would i go about doin
that
 
So I'm trying to play around with the text boxes a bit so I can hopefully figure it out for myself. I don't understand this error I'm getting in the code below. If I use the code below, I get a Run-time error '91': Object variable or With block variable not set. I understand what the error is saying but I don't understand why its occuring because if I change ActiveChart.Shapes to ActiveSheet.Shapes, it works fine. Can someone please explain this to me? Thank

Dim oObj As Shap
For Each oObj In ActiveChart.Shape
If oObj.Type = msoTextBox The
oObj.DrawingObject.Font.Size = 2
End I
Next oObj
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top