Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default embeded excel control doesn't work properly if excel workbook is open through GetObject("xx.xls")

1. i create the following VB code:
-----------------------------------------
Dim myworkbook As Excel.Workbook
myworkbook = GetObject("c:\temp\control.xls")
myworkbook.Parent.Visible = True
myworkbook.Parent.Windows("control.xls").Visible = True

--------------------------------
The control.xls is very simple excel file which contains two check boxs
controls.

When the control.xls is open, the check value in the check box doesn't
stay when you clicked other cells.

One of reason might be that the GetObject("xcell file name") method
creates a embeded workbook under the excel application, that may cause
the embeded control under the embeded workbook doesn't work properly.

Is there a way to make these embeded control work? Appreciate any help
from your experts.

Regards

Zhiming






*** Sent via Developersdex http://www.developersdex.com ***
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,549
Default embeded excel control doesn't work properly if excel workbook is open through GetObject("xx.xls")



If you are using VB or VBA (not VB.Net) then
"myworkbook = GetObject("c:\temp\control.xls")"
is missing the Set statement required for all Objects.
It should read...
Set myworkbook = GetObject("c:\temp\control.xls")
--
Jim Cone
Portland, Oregon USA



"Zhiming H"
wrote in message
1. i create the following VB code:
-----------------------------------------
Dim myworkbook As Excel.Workbook
myworkbook = GetObject("c:\temp\control.xls")
myworkbook.Parent.Visible = True
myworkbook.Parent.Windows("control.xls").Visible = True
--------------------------------
The control.xls is very simple excel file which contains two check boxs
controls.

When the control.xls is open, the check value in the check box doesn't
stay when you clicked other cells.

One of reason might be that the GetObject("xcell file name") method
creates a embeded workbook under the excel application, that may cause
the embeded control under the embeded workbook doesn't work properly.

Is there a way to make these embeded control work? Appreciate any help
from your experts.
Regards
Zhiming






*** Sent via Developersdex http://www.developersdex.com ***
  #3   Report Post  
Posted to microsoft.public.excel.programming
ZH ZH is offline
external usenet poster
 
Posts: 1
Default embeded excel control doesn't work properly if excel workbook is open through GetObject("xx.xls")



Thanks, you're right if the code in VB. However My code is in VB.Net

*** Sent via Developersdex http://www.developersdex.com ***
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
In my Excel "active application add-ins" not properly enable Shahid Excel Programming 1 July 9th 08 06:08 PM
How to disable "New" "open" menu items in Excel 2007 Aruna Akella Excel Programming 1 March 26th 08 05:13 AM
"Open With" Excel Does Not Work For TXT File Extension Rick Hamilton Excel Discussion (Misc queries) 4 September 17th 07 03:26 AM
Excel 2003: "Workbook.Open with URL does not work [email protected] Excel Programming 5 July 25th 06 02:26 PM
Why doesn't "Workbook.Range("myrange").value" work? Brad Patterson Excel Programming 0 July 9th 03 01:24 AM


All times are GMT +1. The time now is 02:33 AM.

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

About Us

"It's about Microsoft Excel"