473,795 Members | 2,826 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

can't find error location: c# web service

jhardman
3,406 Recognized Expert Specialist
I was in the middle of troubleshooting a different problem when my web service stopped working with a very cryptic error message: "specified cast is not valid"

The only location info is that the error came from the web method I called (which is pretty obvious) and this method is gigantic. Arghh. And the web service is running at a remote location - it has no developer tools installed. When I try to pull it up on my box it works - no error, in fact I can't even duplicate the error. So I can't use VWD or VS to troubleshoot.

I think the issue might be time-dependent: The method opens up an XML doc, finds the row that has data for the current time interval, and does some calculations on it and another DataSet before returning the DataSet. The remote location is in a different time zone, and I noticed the error as soon as the remote location time turned 6pm. So I think this may be why I don't see an error on my box running the same web service and the same XML file .

But how on earth can I narrow down the error? Do I need to wait until the middle of the night to duplicate the error conditions? And even then I'm not sure that is the trouble and that won't tell me where the error is. I went through every part of the web service that could be causing the problem, and I added logic that would catch every instance I could think of, but I get nothing.

Anyone have a suggestion?

Jared
Oct 1 '08 #1
3 2125
r035198x
13,262 MVP
It would seem that you have to go through all your type casts and determine which have their correctness determined by time.
Oct 2 '08 #2
jhardman
3,406 Recognized Expert Specialist
I ended up waiting until the error showed up in my time zone so I could debug on my machine. This was so frustrating! It turned out that it was a line which took a value from a DataRow (data type: int) and passed it to a variable (type: int). The problem was that the DataRow had not specified that it wouldn't allow nulls and at some times of the day the value from the xml doc was null so when I tried to pass this to the variable it failed. Disgusting!

Jared
Oct 2 '08 #3
Plater
7,872 Recognized Expert Expert
The problem was that the DataRow had not specified that it wouldn't allow nulls
I am with you on this, my tables like to say no nulls now.
Oct 2 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

5
9542
by: deko | last post by:
After developing an MDB in Access 2003 on WS03, then making it into an MDE and deploying it on a WinXP box with Access 2003 installed, I get this error: Function is not available in expressions in query expression SELECT IIf(IsNull(),"", & Chr(13) & Char(10)) & IIf(IsNull(),"", & Char(13) & Char(10)) & IIf(IsNull(),"", & Char(13) & Char(10)) & IIf(IsNull(),"",] & IIf(IsNull(),"",", ") &
3
1554
by: andrewcw | last post by:
Now that I have placed my class to be called as a service, the service does not know where the XML file for intialization ( deserilaization ) is. In my project I dropped the xml file in the bin directory. When I create and run the service I get my message that the file did not exist ( relative path private string myXMLiniFile="qccomboini.xml"; My first call into the object tests for the fil if (File.Exists(this.myXMLiniFile)==true ...
7
4782
by: Martin Strojek | last post by:
Hi, I have the following problem with developing some web site. I use Visual Studio 2003 to build a website. I tried Windows 2003 Server and switched now back to Windows XP with PWS but the error occurs in both installations. When I do a compile/build of my app and go to the browser and hit reload there comes an error:
9
1894
by: Opa | last post by:
When creating a new web service, I get the following error: Visual Studio .net cannot create or open the application. Web site 'http://localhost/WDWS' not started. The World Wide Web Publish service is started prior to attempting to create a new web service with vs.net. After I get this error, the service stops. Here are my steps:
0
2354
by: solex | last post by:
I am having some security issues with my web service The service uses the default credential cache to make a webDAV request to exchange to create an appointment. Using the browser the web services appears to work perfectly. Directly referencing the web service (as a DLL) from a test project also works perfectly. When I try to reference the service (as a web service) from .NET or Access 2003 I get the follwing error: ...
8
7219
by: vtxr1300 | last post by:
I've followed 2 very similar tutorials on creating a windows service and an installer. But, after successfully compiling it, I try to do the InstallUtil command, but I get a badimageformatexception. I tried to do some searching on that exception, but all I could find was a small blurb on MSs site about C++ which I'm not using. Can anyone see a problem in this code? Thanks. using System; using System.Collections.Generic; using...
0
3860
by: Neff | last post by:
I have a clustered installation of SQL Server 2005 with SSIS installed on the cluster. I'm running SQL Server Management Server on one of the cluster nodes and trying to connect to the integration services server. In the connection dialog the only editable field I have is server name and I can browse and find the server name SC-DB01. However wne I press the connect button I just get an error with the messages below...... Can anyone...
3
1953
by: nnaveenraju | last post by:
Hi Gurus, I am new to Ajax and JAVA. I am able to call the servlet class from the JSP page using AJAX. The servlet class is called successfully. I am processing some data and the data has to passed back to the front end JSP. I have used the following code
2
3837
by: btcoder | last post by:
Hi, my jsp page uses sun.net.smtp.SmtpClient to send email. It worked fine until the hosted location was moved to another server. Now it generates the sun.net.smtp.SmtpProtocolException and the hosting company can't find what's wrong with it so I'm here hoping somebody can help. The hosting company tried sending email from the server and it was okay and found no restrictions that prevents my page to access the smtp server. What could cause...
0
9672
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9519
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10214
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10164
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10001
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9042
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7540
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6780
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.