| View previous topic :: View next topic |
| Author |
Message |
nickalopogus Newbie

Joined: 28 Oct 2004 Posts: 3
|
Posted: Thu Oct 28, 2004 1:47 am Post subject: Put buttons in an entire column for an action on their rows? |
|
|
I'd like to fill every cell in a column with a button(or a hyperlink, whatever) that when pressed moves everything in its row one spot to the right ( the spot to the immediate right of the button/whatever becomes blank). Preferrably the cursor would end up in this blank cell ready for data entry but that is secondary.
I've managed to do this for one row by recording a macro that inserts a blank cell ( thereby moving everything else to the right) then inserting a button and assigning it to this macro but its too time consuming to do for 150+ cells.
I've fooled around with formulas quite a bit in excel/open office but just can't wrap my head round this problem and don't understand enough about the buttons.
Thanks. |
|
| Back to top |
|
 |
nickalopogus Newbie

Joined: 28 Oct 2004 Posts: 3
|
Posted: Fri Oct 29, 2004 8:45 pm Post subject: Follow up |
|
|
Well I've worked out how to fill a whole column with buttons. its just Edit->Fill->Down as it is for formulas etc. I had tried it before my original post and it didn't work for some reason but it works now. Now I just need to figure out the "move cells one spot to the right" part of it.
I've realised that it probably has to be a macro to do this, I've been looking at the fomulas and they seem to act only on data in the cells etc. not on the cells themselves I found this http://www.translate.org.za/download/translatethon/openoffice-glossary-as.csv which lists some sort of Open Office commands but I can't work out how to use them. It includes "Insert Cells Right" which seems to be what I want.
I would paste the original macro I recorded in here but it's a dogs breakfast; I think it would serve only to confuse. However there is one part of it which is pertinent
| Code: | | dispatcher.executeDispatch(document, ".uno:InsertCell", "", 0, args3()) |
because it seems to be the actual bit that does the inserting.
Looks like I'm gonna have to learn some VB (that's what this stuff is right?). Any tips/tricks/resources would be much appreciated. I'm gonna go googling now  |
|
| Back to top |
|
 |
_Yiba_ Power User


Joined: 22 Jul 2004 Posts: 81 Location: Illinois, USA
|
Posted: Sat Oct 30, 2004 10:17 am Post subject: |
|
|
I highly suggest you post your question in the Macros and API section. You'll be a lot more likely to get an answer there. _________________ "Whose the more foolish, the fool or the fool who follows him?" |
|
| Back to top |
|
 |
DannyB Moderator


Joined: 02 Apr 2003 Posts: 3991 Location: Lawrence, Kansas, USA
|
|
| Back to top |
|
 |
|