Re TYpe mismatch

P

Paul

Hello, i an not sure if this is the rihgt place for this question, if not
could someome point me to the correct newsgroup please.

For a number of years i have been designing sites and hosting them using a
reseller account. For various reasons i am now going over to VPS server
using Windows Server 2003 with iis 6 installed. This is a large leap for me
and its getting me quite confused.

One problem i have is i am getting this error when testing a page

Provider error '80020005'

Type mismatch

The line in question is a currency field and the data that it is attempting
to be written is £200.00, if i try it without the £ sign it works fine,
what i dont understand is that it works fine on the existing site with or
without the £ sign.

Can anybody point me in the right direction, i dont really want to have to
write code to remove the £ sign if thers no need too.

Thanks in advance

Paul
 
M

MyndPhlyp

Paul said:
Hello, i an not sure if this is the rihgt place for this question, if not
could someome point me to the correct newsgroup please.

For a number of years i have been designing sites and hosting them using a
reseller account. For various reasons i am now going over to VPS server
using Windows Server 2003 with iis 6 installed. This is a large leap for me
and its getting me quite confused.

One problem i have is i am getting this error when testing a page

Provider error '80020005'

Type mismatch

The line in question is a currency field and the data that it is attempting
to be written is £200.00, if i try it without the £ sign it works fine,
what i dont understand is that it works fine on the existing site with or
without the £ sign.

Can anybody point me in the right direction, i dont really want to have to
write code to remove the £ sign if thers no need too.

Regional settings at the server perhaps? The currency settings can be
adjusted in the Regional Options on the Control Panel.
 
P

Paul Bromley

Hi Thanks for that quick reply, it sounded logical but ubfortunately
after the settings to the UK its still producing the same problem on
this machine.
 
P

Phillip Windell

I think the right way would be to do it without the £ sign anyway. A simple
"Replace()" function could strip it out of the input, there is no large
amount of code required to do that. I never consider including the $ for US
currency,...the databse already displays it in the field based on the
Datatype of the field,...the only thing you put in is the number.

--
Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com
-----------------------------------------------------
Understanding the ISA 2004 Access Rule Processing
http://www.isaserver.org/articles/ISA2004_AccessRules.html

Microsoft Internet Security & Acceleration Server: Guidance
http://www.microsoft.com/isaserver/techinfo/Guidance/2004.asp
http://www.microsoft.com/isaserver/techinfo/Guidance/2000.asp

Microsoft Internet Security & Acceleration Server: Partners
http://www.microsoft.com/isaserver/partners/default.asp
 
M

MyndPhlyp

Paul Bromley said:
Hi Thanks for that quick reply, it sounded logical but ubfortunately
after the settings to the UK its still producing the same problem on
this machine.

What if you were to test the string with IsNumeric() or tried a conversion
with CDbl()? You might have to shave off the currency symbol to process it
as a number.
 
P

Paul

I think the right way would be to do it without the £ sign anyway. A
simple "Replace()" function could strip it out of the input, there is
no large amount of code required to do that. I never consider
including the $ for US currency,...the databse already displays it in
the field based on the Datatype of the field,...the only thing you put
in is the number.

Yes i agree with you, that to use the replace function would solve the
problem, but as stated in my original post, i am trying to have to avoid
rewriting code. If it was just this 1 page and 1 site thats exactly what i
would have done, but there are numerours sites that i would have to do that
in, and if i missed any out, sites that are working now may stop working
properly, thats why i am trying to avoid that route. Especially as the
sites are working fine on the other server, surely it has to be down to a
setting or something like that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top