Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 25
Default cell values as label captions

In a userform I want to display cell values in a label. This code gives me a
subscript out of range.

label1.caption = workbooks("myworkbook.xls") .worksheets(1).range("a1)


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default cell values as label captions

label1.caption = workbooks("myworkbook.xls")
..worksheets(1).range("a1").Value

If it still gives you that error message, you don't have a workbook open
named Myworkbook.xls

--
Regards,
Tom Ogilvy


"Rbp9ad" wrote in message
...
In a userform I want to display cell values in a label. This code gives me

a
subscript out of range.

label1.caption = workbooks("myworkbook.xls") .worksheets(1).range("a1)




Reply
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
X axis captions Stefi Charts and Charting in Excel 6 September 11th 08 01:16 PM
label x-axis values programmatically [email protected] Charts and Charting in Excel 1 September 5th 06 03:04 AM
Cell values as captions TUNGANA KURMA RAJU Excel Discussion (Misc queries) 1 July 24th 06 12:29 PM
Identify Label €” More than one cell with label George Lynch Excel Discussion (Misc queries) 2 May 4th 05 05:12 PM
Is there a way to have two values (percent and number) in a label. msmiller613 Charts and Charting in Excel 1 December 15th 04 03:47 AM


All times are GMT +1. The time now is 09:26 AM.

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"