Prev: Action buttons did not function properly with power point 2007
Next: Help Plz: Problem playing AVI file within PowerPoint
From: Prasant on 20 Mar 2008 01:06 Hi there, I'm writing a macro which should read the blank space. Is there any command/code to identify the blank/null space in coding, something like Sp or whatever?
From: vindys on 20 Mar 2008 03:31 Do you mean you trying to find the blank space in a text box or so? Also whats this sp you mentioned? "Prasant" wrote: > Hi there, > I'm writing a macro which should read the blank space. Is there any > command/code to identify the blank/null space in coding, something like Sp or > whatever?
From: Prasant on 21 Mar 2008 00:49 Hi vindy Yes. I want to identify the blank space inside the text box. Sp is like an keyword or example thought might help. "vindys" wrote: > Do you mean you trying to find the blank space in a text box or so? Also > whats this sp you mentioned? > > "Prasant" wrote: > > > Hi there, > > I'm writing a macro which should read the blank space. Is there any > > command/code to identify the blank/null space in coding, something like Sp or > > whatever?
From: vindys on 21 Mar 2008 15:29 Hi Prasant, Assuming that you want to find the space in a shape other than the text area, 'Left corner of shape MsgBox ActiveWindow.Selection.ShapeRange(1).Left 'left corner of text MsgBox ActiveWindow.Selection.ShapeRange(1).TextFrame.TextRange.BoundLeft 'right corner of shape MsgBox ActiveWindow.Selection.ShapeRange(1).Left + ActiveWindow.Selection.ShapeRange(1).Width 'right corner of shape MsgBox ActiveWindow.Selection.ShapeRange(1).Left + ActiveWindow.Selection.ShapeRange(1).Width - ActiveWindow.Selection.ShapeRange(1).TextFrame.TextRange.BoundWidth 'top corner of shape MsgBox ActiveWindow.Selection.ShapeRange(1).Top 'top corner of text MsgBox ActiveWindow.Selection.ShapeRange(1).TextFrame.TextRange.BoundTop 'bottom corner of shape MsgBox ActiveWindow.Selection.ShapeRange(1).Top + ActiveWindow.Selection.ShapeRange(1).Height 'bottom corner of text MsgBox ActiveWindow.Selection.ShapeRange(1).Top + ActiveWindow.Selection.ShapeRange(1).Height - ActiveWindow.Selection.ShapeRange(1).TextFrame.TextRange.BoundHeight So i guess this might give you an idea where are the shape and text boundaries and you do your appropriate funtions. Replace selection shape to your shape. Thanks, Vinod "Prasant" wrote: > Hi vindy > > Yes. I want to identify the blank space inside the text box. > Sp is like an keyword or example thought might help. > > > > "vindys" wrote: > > > Do you mean you trying to find the blank space in a text box or so? Also > > whats this sp you mentioned? > > > > "Prasant" wrote: > > > > > Hi there, > > > I'm writing a macro which should read the blank space. Is there any > > > command/code to identify the blank/null space in coding, something like Sp or > > > whatever?
From: Steve Rindsberg on 21 Mar 2008 20:17
In article <7F9CC857-0262-4A6E-9927-279B25FA44FA(a)microsoft.com>, Prasant wrote: > Hi there, > I'm writing a macro which should read the blank space. Is there any > command/code to identify the blank/null space in coding, something like Sp or > whatever? Chr$(20) or " " are equivalent to spaces VBNullString is a null/empty string or if you're testing to see if a string is blank: If Len(string) = 0 Then Debug.Print "It's blank" End If ----------------------------------------- Steve Rindsberg, PPT MVP PPT FAQ: www.pptfaq.com PPTools: www.pptools.com ================================================ |