Add An Error Message

Horse06
Member Posts: 496
I have a a pogram to export the data in excel format. Everything is fine, but I have encountered a pop-up message as below when there are no data retrieved.
This message is for C/AL programmer:
An exception was raised in method rangne. THe OLE control or Automation server has returned error(HRESULT)-2147352567. The component did not provide the exception description.
Is there any way to write a message like "No data were found" instead of the system message. Appreciate it!
This message is for C/AL programmer:
An exception was raised in method rangne. THe OLE control or Automation server has returned error(HRESULT)-2147352567. The component did not provide the exception description.
Is there any way to write a message like "No data were found" instead of the system message. Appreciate it!
0
Comments
-
There is an ERROR function...
http://msdn.microsoft.com/en-us/library/dd355305.aspx
May be of some use!0 -
I think the error raised when you are accessing range, which is not exists. Are you using named ranges? It is a couple of cells, which have there name?
In that case you should always check if name range exist or no before exporting values.Sincerely yours, GRIZZLY
Follow my blog at http://x-dynamics.blogspot.com0 -
I tried to retrieve the data from the date range. For example, I enter the date range from 7/10/11..7/20/11 and if there are no data retrieved, there is an system error. Otherewise everything is fine. Thank you!0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions