Rocket Software Homepage
Forum Home Forum Home > AccuTerm Knowledge Base (read only) > Advanced Features
  New Posts New Posts RSS Feed - Create an Excel List
  FAQ FAQ  Forum Search   Register Register  Login Login

The AccuTerm forum has moved. Go to community.rocketsoftware.com to register for the new Rocket forum.

Forum LockedCreate an Excel List

 Post Reply Post Reply
Author
Message
abreck View Drop Down
Newbie
Newbie


Joined: October 27 2006
Status: Offline
Points: 1
Post Options Post Options   Thanks (0) Thanks(0)   Quote abreck Quote  Post ReplyReply Direct Link To This Post Topic: Create an Excel List
    Posted: October 27 2006 at 6:02am
I'm trying to create a list (with a drop down list for the columns columns) in MSExcel.  And while I can get the command itself to work, if I send more than one argument to the METHARGS the command returns:

'Invalid procedure call or argument'

If my data that I wanted in the list started at cell A1 everything would be fine (MSExcel handles this in a 'default' manner just fine), but my list data starts at cell A7

The command goes as follows:

CALL ATGETPROPERTY(Worksheet,'ListObjects',ListObjects,ERRMSG,OPTS)
TEST2 = '1':@VM:''
CALL ATINVOKEMETHOD(ListObjects, 'Add', TEST2, List1,ERRMSG,OPTS)

If I look at how the MSO VB editor approaches this it give me

ActiveSheet.ListObjects.Add(xlSrcRange, Range("$A$7:$AV$15"), ,
xlYes).Name = _ "List2"

See

http://msdn2.microsoft.com/de-de/library/microsoft.office.interop.excel.listobjects.add.aspx

for more information on this method

I have learned through trial and error that the .name portion is not needed.

For testing purposes, I'm trying to use the range A7:Z16 and I have a Range object that is holding that range just fine

TEST4 = 'Range':@SM:'A7:Z16'
CALL ATGETPROPERTY(Worksheet, TEST4, Range, ERRMSG, OPTS)

If I am understanding the use of ATINVOKEMETHOD correctly, TEST2 should be:

TEST2 = '1':VM:Range:VM:VM:'1'

But anytime I send more than one parameter it fails (even '1':VM:''
fails).

Any help would be greatly appreciated.

PS - for those looking for an MSOffice programming reference, look here

http://msdn2.microsoft.com/en-us/library/microsoft.office.interop.excel.aspx
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.03
Copyright ©2001-2019 Web Wiz Ltd.