BookmarkSubscribeRSS Feed
Victor
Calcite | Level 5
Hello


1) I need to know within the custom task wich application is calling it : Excel, Word, etc. Is it possible ? I tried this :

_consumer.Option(EnvironmentOption.HostApplicationName)

But it is not enough. I can only know if it is Guide or an Add-In.

2) Is it possible to call Add-In dialog boxes within the custom task? like "Server Connexion", "Open a data table", "Stored Process List", etc.

3) Is it possible to communicate with the calling application (Excel, word) ? As same as VBA objects for example : Application, Workbooks, ActiveWoorkBook ?

4) Add-In's and Guide's Server Configuration are very different. Is there a project to make them the same? In guide, you can simply change the server by choosing it in a list box. In Add-in, you have to go into the configuration form to change the server.


Regards
1 REPLY 1
ChrisHemedinger
Community Manager
Victor,

Some answers:

1. You can use .NET calls to determine the application. For example, you can use System.Diagnostics.Process.GetCurrentProcess() to gather information about the current running process, including the EXE name.

2. You can indirectly call the file dialog to select a data set with the ISASTaskConsumer2.ShowDataSelector method.

3. We don't provide a direct hook into the Office object models, but you might be able to gain access by using the GetCurrentProcess() approach as outlined in (1).

4. Yes, in the 4.2 releases of EG and Office Add-In, these mechanisms have converged to be the same.

Chris
Learn from the Experts! Check out the huge catalog of free sessions in the Ask the Expert webinar series.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 663 views
  • 0 likes
  • 2 in conversation