The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 Edit-Delete in a script

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
a_user Posted - 08/13/1998 : 7:44:00 PM
The menu item 'Delete' in the Edit Menu is a quite powerful tool. It
not only deletes the contents of the selected cells, but also
reduces the length of the coloumn. If one deletes some cells in the
middle of a coloumn, the rest of the coloumn is moved upwards.

But how can I use this tool in a script? It is not difficult to delete the
contents of one or more cells, but if I want to move the rest of coloumn
upwards I have to write a little copy-loop. Does anybody know a better
solution?

1   L A T E S T    R E P L I E S    (Newest First)
a_user Posted - 08/13/1998 : 7:46:00 PM
Response

This particular menu item does not have a script command. However, by using
script, one can invoke the menu command.

Select the cell(s) that you want to delete, either manually, or using script.

For example:
worksheet -s 1 3 1 5; /* Select rows 3 to 5 in column 1 */

then invoke the menu command

domenu 881; /* Call the Delete menu by its ID number */

Note that using IDs is not recommended for future-compatible code, since
Origin's menu IDs may change at some future point.


The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000