WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

COMCONTROL
plus
plus

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Using Excel in a Dialog Com Control

 Keywords: Excel COMCONTROL window Browse 

Question:

I'm trying to host Excel inside a Dialog using the Com control. I've tried the class id from the registry. I've also tried "Excel.Application" but neither works. I get an error ... "Dialog Box Window Creation Failed.

I also tried using the name of an Excel file (.xls) instead of a GUID or progid. But it just opened the referenced file with an instance of Excel. It didn't open the file within the com control. I'm using Office 2003. Excel launches the .xls file but the Com control within the Dialog is blank.

What am I missing?

Answer:

Hmm. Works fine on my system as loading Excel file this way always has. The spread sheet is displayed in the COMCONTROL.

There is apparently a browser setting that is available the controls this.

Check the registry key at

HKEY_CLASSES_ROOT\Excel.Sheet.8 
for the presences of the value 'BrowserFlags'.

'BrowserFlags' has a value of 8 when the 'Browse In Same Window' is unchecked and does not exist if it is checked.

Of course being able to change or remove the value in a script is dependent on security settings.


Article ID:   W17397
File Created: 2008:04:10:15:09:16
Last Updated: 2008:04:10:15:09:16