LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default Data Types and inaccuracies with Trig functions in VBA

I am developing an application to calculate navigation data from Sun & Star
sights (interesting for sailors, boring for everyone else).

The problem is that I appear to be getting small inaccuracies when
calculating angles. I have used Double as the data type. Looking through
the help files I note that there should be a 'Decimal' data type that uses
many more digits so potentially improving accuracy. However, a line such
as:

Dim dLat as Decimal

results in a message: 'Compile error: Expected: New or type name'

I understand that this is saying it doesn't recognise the Decimal data type.
Do I have to add a library to use this? if so which one?

Any ideas gratefully received.

Peter Morris


 
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
Excel 2007 error "some chart types cannot be combined with other chart types. Select a different chart types" roadsidetree Charts and Charting in Excel 15 June 2nd 09 10:53 AM
Trig Function seems odd. Ken McLennan Excel Worksheet Functions 9 May 8th 08 01:26 PM
Trig functions Kokopeelle Excel Worksheet Functions 3 September 30th 06 08:58 PM
Data types when importing Excel data to SQLServer [email protected] Excel Discussion (Misc queries) 1 September 27th 06 12:48 PM
how can I perform trig. functions usings grads 400deg per circle davystuff Excel Worksheet Functions 2 March 30th 06 03:00 PM


All times are GMT +1. The time now is 11:18 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"