LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Setting a value in an add-in

Nope... same error :(

"Norman Jones" wrote:

Hi Polandic,

Private Sub Workbook_Open()
Application.Run ("WorksheetB.xls!SetName('test')")
End Sub


If the name of the second workbook is WorksheetB.xls, then try:

Private Sub Workbook_Open()

Application.Run "WorksheetB.xls!SetName", "Test"

End Sub


---
Regards,
Norman


"polandjc" wrote in message
...
OK this is my most recent attempt:

Worksheet A:

Private Sub Workbook_Open()
Application.Run ("WorksheetB.xls!SetName('test')")
End Sub

Worksheet B:

Pubilc sFileName As String
Public Sub SetName(ByVal sName As String)
sFileName = sName
End Sub

Starting the execution in Worksheet A, I get a run time error 1004
(Application-defined or object-defined error).

The additional wrinkle to this is that I want Worksheet B to be a
protected
XLA.

Jim

"Dave Peterson" wrote:

And creating the function in one workbook and running it from the other
workbook
didn't work?

ps. I'm still confused at what's happening.





 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
setting default filter setting tpeter Charts and Charting in Excel 0 December 4th 09 02:50 PM
Setting a datarange Joyce Excel Discussion (Misc queries) 1 May 24th 05 02:22 AM
Setting default pivot table field setting to "sum" Mr. Moose Excel Discussion (Misc queries) 2 December 21st 04 04:43 PM
VBA Setting .Value to a date does not respect local system setting Frank_Hamersley Excel Programming 13 July 18th 04 02:51 PM
Sending email via macro- setting the importance setting. Julian Milano[_2_] Excel Programming 1 January 20th 04 10:15 PM


All times are GMT +1. The time now is 04:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"