BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
ChrisBrooks
Ammonite | Level 13

I'm not entirely sure why you're code isn't trapping those errors but I would strongly recommend fixing the SAS code outside of an IOM call anyway. When calling SAS from another language I always use a test harness which attempts to emulate the call from within SAS as it's much easier to resolve issues.

 

In your case I think the "Format Couldn't be Loaded" error is caused by a missing FMTSEARCH option telling SAS where to look for the stored custom format and if you add that to your SAS program you should resolve that issue. The "Open Code Statement Recursion" error is impossible to give advice on without seeing the SAS code as it could be caused by a multiplicity of issues.

Petr_D
Calcite | Level 5

Hello,

thanks for quick reply. I am using SAS Enterprise Guide (SAS EG) to debug the code. The problem is same (error free) code when run in SAS EG generates errors when run in VBA.

E. g. Format Couldn't be Loaded error in Visual Basic error log  and vice versa: Open code statement recursion detected - not being indicated in VBA error log.

Open code statement recursion detected error is deliberate for testing purposes driven by missing apostrophe in prxmatch expression.

I tried to use options nosource nonotes to reduce log extent in VBA but again it works in SAS EG only.

Petr

ChrisHemedinger
Community Manager

You might need to add options nofmterr to your code to prevent errors when a SAS format can't be found.  EG submits that statement automatically.

It's time to register for SAS Innovate! Join your SAS user peers in Las Vegas on April 16-19 2024.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

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
  • 17 replies
  • 16184 views
  • 0 likes
  • 5 in conversation