Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ben Ben is offline
external usenet poster
 
Posts: 509
Default Calling msgbox in Excel

Hi all,

I just starting using VS2002. Currently in my Excel XP development, I can
use the msgbox to have it display a message.

While I was experimenting with VS 2002 and the PIA, I was wondering how I
can cause Excel to display a msgbox instead of one from the VS 2002 code.
Displaying a msgbox from within VS2002 causes the msgbox to appear behind
Excel. Whereas I would like to code it in such a way in VS2002 such that
when I instantiate an instance of Excel I would like Excel to display a
msgbox so that it is on top/ in front of Excel instead of behind it. Any
ideas? Thanks.

Ben



--

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Calling msgbox in Excel

You would have to call a macro or otherwise execute a macro in Excel (written
in VBA) that displays the message box. (and perhaps returns a value).

--
Regards,
Tom Ogilvy


"Ben" wrote:

Hi all,

I just starting using VS2002. Currently in my Excel XP development, I can
use the msgbox to have it display a message.

While I was experimenting with VS 2002 and the PIA, I was wondering how I
can cause Excel to display a msgbox instead of one from the VS 2002 code.
Displaying a msgbox from within VS2002 causes the msgbox to appear behind
Excel. Whereas I would like to code it in such a way in VS2002 such that
when I instantiate an instance of Excel I would like Excel to display a
msgbox so that it is on top/ in front of Excel instead of behind it. Any
ideas? Thanks.

Ben



--

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Calling msgbox in Excel

I haven't worked in .NET, but here is some added:

http://support.microsoft.com/kb/306682/en-us
How to run Office macros by using Automation from Visual Basic .NET

http://support.microsoft.com/kb/303871/en-us
How To Create an Excel Macro by Using Automation from Visual Basic .NET

--
Regards,
Tom Ogilvy



"Ben" wrote:

Hi all,

I just starting using VS2002. Currently in my Excel XP development, I can
use the msgbox to have it display a message.

While I was experimenting with VS 2002 and the PIA, I was wondering how I
can cause Excel to display a msgbox instead of one from the VS 2002 code.
Displaying a msgbox from within VS2002 causes the msgbox to appear behind
Excel. Whereas I would like to code it in such a way in VS2002 such that
when I instantiate an instance of Excel I would like Excel to display a
msgbox so that it is on top/ in front of Excel instead of behind it. Any
ideas? Thanks.

Ben



--

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Calling msgbox in Excel

Ben,
That MsgBox is not part of Excel, but VBA. Its full reference is :
VBA.Interaction.MsgBox

So unless you can access this from your environment, you are out of luck.
Excel does have an InputBox method, but that may not be want you want.

Otherwise maybe the MessageBox/MessageBoxEx API calls will do what you need.

NickHK

"Ben" wrote in message
...
Hi all,

I just starting using VS2002. Currently in my Excel XP development, I can
use the msgbox to have it display a message.

While I was experimenting with VS 2002 and the PIA, I was wondering how I
can cause Excel to display a msgbox instead of one from the VS 2002 code.
Displaying a msgbox from within VS2002 causes the msgbox to appear behind
Excel. Whereas I would like to code it in such a way in VS2002 such that
when I instantiate an instance of Excel I would like Excel to display a
msgbox so that it is on top/ in front of Excel instead of behind it. Any
ideas? Thanks.

Ben



--



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
Calling a DLL in MS-Excel Jim Excel Programming 1 March 22nd 06 06:16 AM
Calling VB from Excel Ingvar[_2_] Excel Programming 1 October 10th 04 11:46 AM
Calling a VB.NET exe/dll from excel Rui Dias Excel Programming 0 August 11th 04 05:44 PM
Calling Excel from C++ GL[_2_] Excel Programming 1 August 9th 04 09:15 PM
how msgbox from Word when ran from Excel? Dave Peterson[_3_] Excel Programming 0 September 6th 03 12:11 AM


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