OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

how can i cut and paste by macro

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
briglia23
OOo Enthusiast
OOo Enthusiast


Joined: 24 Jun 2008
Posts: 121

PostPosted: Mon Jun 29, 2009 8:04 am    Post subject: how can i cut and paste by macro Reply with quote

How can i do this in OOo

Code:


        If WordBasic.ExistingBookmark("CodInterno") Then
            WordBasic.EditBookmark Name:="CodInterno", SortBy:=1, GoTo:=1
            WordBasic.EditCut
            WordBasic.ViewHeader
            WordBasic.GoToHeaderFooter
            WordBasic.EditPaste
            WordBasic.CloseViewHeaderFooter
        End If


Thanks
Back to top
View user's profile Send private message
JohnV
Administrator
Administrator


Joined: 07 Mar 2003
Posts: 9183
Location: Lexinton, Kentucky, USA

PostPosted: Mon Jun 29, 2009 11:25 am    Post subject: Reply with quote

You can record a cut & paste macro.
Back to top
View user's profile Send private message
briglia23
OOo Enthusiast
OOo Enthusiast


Joined: 24 Jun 2008
Posts: 121

PostPosted: Tue Jun 30, 2009 1:37 am    Post subject: Reply with quote

I prefer write a macro than recorder it.

Probably is more difficult to do but let me to understand more about macro programming.

Thank you.
Back to top
View user's profile Send private message
rebelxt
OOo Enthusiast
OOo Enthusiast


Joined: 10 Dec 2006
Posts: 114
Location: StLouis

PostPosted: Wed Jul 01, 2009 9:58 am    Post subject: Reply with quote

Record a 'cut and paste' macro, then look at the generated code. That technique has helped me in the past.
Back to top
View user's profile Send private message
JohnV
Administrator
Administrator


Joined: 07 Mar 2003
Posts: 9183
Location: Lexinton, Kentucky, USA

PostPosted: Wed Jul 01, 2009 10:40 am    Post subject: Reply with quote

Quote:
I prefer write a macro than recorder it.

In the case of cut, copy and paste the code you write will be much the same as the code you record.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group