Running SAS while Userform is Active/Shown

Snox114

New Member
Joined
Apr 28, 2015
Messages
1
Dear readers,

I'm having a problem with SAS when executing SAS in batch mode while a userform is active in Excel.

Is there any way to run the SAS in batch mode while a userform is active?
If not, is there any way to check when the 'batch APP' has completed its run and then re-open the userform?

I've tried the following :
  • Creating an empty file from SAS as the last statement and then check in excel when the mentioned file exists (Using a loop);
  • Userform.hide and userform.show in the same SUB;
  • Using the waitonreturn with shell function in Excel (This executes the 'batch APP', but the score.sas code isn't executing);
  • sApp = "SAS.Application"
    If IsAppRunning(sApp) = True

    Function IsAppRunning(ByVal sAppName) As Boolean
    Dim oApp As Object
    On Error Resume Next
    Set oApp = GetObject(, sAppName)
    If Not oApp Is Nothing Then
    Set oApp = Nothing
    IsAppRunning = True
    End If
    End Function;

I'll appreciate any help.

Thanks
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest

Forum statistics

Threads
1,216,725
Messages
6,132,342
Members
449,719
Latest member
excel4mac

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top