Re: PowerPoint shapeId/ShapeName property changes/Increments autom

From: Abhishek Bagga (Bagga_at_discussions.microsoft.com)
Date: 10/25/04


Date: Sun, 24 Oct 2004 21:11:04 -0700

Thanks Shyam
I agree with what u r saying, reference is stored in a shape type variable
Nor do i but the problem arises in case of the tables when i am excessing
the rows and columns of a particular table
Since the id changes and may be there are some other changes to it as well
which result in a com exception in my code.
Basically when i start accessing the rows and columns i assign them to the
cell type variable but since it changes the id/name and may be some other
properties as well,
It raises a com exception

Regards,
Abhishek

"Shyam Pillai" wrote:

> Hello Abhishek,
> While I've encountered the issue you've mentioned in the past, I haven't
> experieced in refering to the shape if the reference is stored in a shape
> type variable even when the shape name/id changes.
>
>
> --
> Regards
> Shyam Pillai
>
>
> "Abhishek Bagga" <AbhishekBagga@discussions.microsoft.com> wrote in message
> news:16335358-FC72-4BBA-8FEF-27C294C07064@microsoft.com...
> > Hi!
> > I am accessing the properties of the borders of a table inserted within
> > ppt
> > presentation but facing this very annoying problem.
> > Whenever i access any property related to the borders of the table it
> > changes/Increments the ID as well as the shape of the current cell.
> > This has become a major problem since i am refering to the current shape
> > thru a variable and when the id changes the my code gives me a com
> > exception.
> > I am facing this problem with both off2k (Only shape name as Shape Id does
> > not exists) and off XP
> > I am posting a small sample code to better explain my problem
> > You can create a simple 3X3 table and select the table and chk this code
> > thru VB editor inside PPT
> > I am actually creating my app in .net but for testing purposes i am
> > posting
> > the vba code
> >
> > Sub Testing()
> > With ActiveWindow.Selection.ShapeRange(1).Table.Cell(1, 1)
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Id
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Name
> > MsgBox .Borders(ppBorderTop).Visible
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Id
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Name
> > MsgBox .Borders(ppBorderTop).Visible
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Id
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Name
> > MsgBox .Borders(ppBorderTop).Visible
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Id
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Name
> > MsgBox .Borders(ppBorderTop).Visible
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Id
> > MsgBox ActiveWindow.Selection.ShapeRange(1).Name
> > End With
> > End Sub
> >
> > Kindly give some suggestion or a solution to this or a link to some other
> > similar post that would be of some help
> >
> >
> > --
> > Abhishek Bagga
> > Sikhya Solutions
> > www.sikhya.com
> >
> >
>
>
>



Relevant Pages

  • Re: Dataset retunring Null ..a gurus opinion required!
    ... How is estateOleAdapter initialized? ... toolbox to the design area to establish the connection. ... application this exception comes up): ... When adding a reference, I tried "Add Service Reference" and I also ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: Giving an application a window icon in a sensible way
    ... My mistake, then. ... that began with your posting a question and continued -- well, ... This was misinterpreted as suggesting I didn't make the first post. ... That sounded to me like a reference to a specific thread. ...
    (comp.lang.java.programmer)
  • Re: "invalid handle", sockets, threads and garbage collector
    ... your IntPtr value happens to coincide with a reference. ... The exception contains "invalid handle" message. ... Socket constructor problem ... finalization means closing the handle to resource. ...
    (microsoft.public.dotnet.framework.clr)
  • Global Assembly Cache Issue
    ... I have a dll that I use in several projects, that I placed in the Global ... you can see in the Exception below). ... If I change the Copy Local property of the reference to True, ... Attempting download of new URL ...
    (microsoft.public.dotnet.framework.aspnet)
  • RE: Excel 2007 cell reference problems
    ... Please also help me to capture somes screenshots to show the symptom in ... This posting is provided "AS IS" with no warranties, ... Excel 2007 cell reference problems ... | The physical cell can contain any number. ...
    (microsoft.public.office.misc)