Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Can you use VBA forms in different applications (VB app and Excel)???

Dear All,

I have the following problem with a macro. I hope somebody may help me.


Problem:
I want to display a VBA form created in an VB application on top of an
Excel worksheet to enter some information. But when I show the form
after opening the Excel workbook, the macro automatically switches back
to the application showing this form (and not on top of the Excel
workbook).

Code:
....
'Open Excel workbook
Set xlS = clsApp.GetApplication("excel.A*pplication")
Set xlsWB = xlS.Workbooks.Open(filename)
xlS.Visible = True
'Show form on top of that Excel workbook
frm.Show vbModeless
....
PROBLEM OCCURED: the macro switches back to the VB application showing
this form instead of staying with Excel

Purpose of the macro:
I have this VB application which provides Visual Basic Editor for
writing VBA macros. In order to import data from any Excel sheet, I
open an Excel workbook with the macro and then want to show a VBA form
on top of the opened Excel sheet. The Excel sheet itself cannot contain
any macro at all. Those Excel sheets will have the data always in
different columns so the user needs to see the Excel sheet as well as
the form in order to enter the proper column names in the form.

I would appreciate any help of you guys. MANY THANKS in advance!


Best wishes,
kuhni

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
Applications in Excel Snailspace New Users to Excel 5 October 22nd 08 03:39 PM
Installation of Excel and other MS Applications Rawle Excel Discussion (Misc queries) 1 February 13th 08 04:08 PM
Fun Excel applications wanted Zdenek Moravec[_2_] Excel Programming 3 April 17th 05 09:01 AM
Detecting Applications Run using Excel gr8guy Excel Programming 2 August 16th 04 08:16 AM
Distributing Excel Applications Michael D. Ober[_2_] Excel Programming 3 October 2nd 03 02:24 PM


All times are GMT +1. The time now is 12:18 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"