Hi,
I get the following exception: 'Cannot find the method on the object instance' when I hover over a property of one of my classes in Visual Studio 2010.
Any ideas?
Hello
i am currently trying to run a web crawler through the terminal. it compiles fine and the debug does not find any errors, however i get the following error which i do not understand.
any ideas on how to get rid of this error would be much appreciated
Unhandled Exception: System.ArgumentOutOfRangeException: startIndex + length > this.length
Parameter name: length
at System.String.Substring (Int32 startIndex, Int32 length) [0x00000]
at OpenWebSpiderCS.mysql.executeSQLQuery (System.String SQL) [0x00000]
at OpenWebSpiderCS.db.startIndexThisSite (OpenWebSpiderCS.page p) [0x00000]
at OpenWebSpiderCS.ows.startCrawling () [0x00000]
at OpenWebSpiderCS.mainClass.Main (System.String[] args) [0x00000]
thank you
I have noticed that in the Ruby exception hierarchy, there are "errors" such as ArgumentError and there are "exceptions" such as SignalException. Is there a certain practise of naming exceptions? thanks in advance, ell.
In languages that support exception objects (Java, C#), when is it appropriate to use error codes? Is the use of error codes ever appropriate in typical enterprise applications?
Many well-known software systems employ error codes (and a corresponding error code reference). Some examples include operating systems (Windows), databases (Oracle, DB2), and middle-ware products (WebLogic, WebSphere). What benefits do error codes provide? What are the disadvantages to using error codes?
Hi,
I am creating some multi-threaded code, and I have created a JobDispatcher class that creates threads. I want this object to handle any unhandled exceptions in the worker threads, and so I am using
Thread.setUncaughtExceptionHandler(this);
Now, I would like to test this functionality - how can I generate an unhandled exception in the run() method of my worker object?
Thanks,
Martin
What is the right way to build iPhone core data for this SMS like app (with location)?
- I want to represent an entity of
conversation with
"profile1"
"profile2"
that heritage from a profile entity,
and a message entity with:
"to"
"from"
"body"
where the "to" and "from" are equal to "profile1" and/or "profile2" in the conversation entity.
How can I make such a relationships?
is there a better way to represent the data (other structure)?
Thanks
Hi all,
I get this error:
StandardWrapperValve[Vaadin Servlet]: PWC1406: Servlet.service() for servlet Vaadin Servlet threw exception
java.lang.ClassCastException: com.delhi.entities.Category cannot be cast to com.delhi.entities.Category
when I try to run my webapps on glassfish v2.
Category is a JPA entity object
the offending code according to the server log is:
for (Category c : categories) {
mymethod();
}
categories is derived from:
List<Category> categories = q.getResultList();
Any idea what went wrong?
why do i get this exception?
Map myHash = null
myHash = (HashMap)Collections.synchronizedMap(new HashMap());
If i try to use this hashmap, i get java.lang.ClassCastException
Hi
Is there any performance problem or something else about letting the exception to propagate, or it is better to write it like this
try
{
}
catch
{
throw;
}
Hi! I have the next query:
var bPermisos = from b in ruc.Permisos
where b.IdUsuario == cu.Id
select new Permisos(){
Id=b.Id,
IdUsuario=b.Id,
IdPerfil=b.Id,
Estatus=b.Estatus
};
var qSisPer = from perm in bPermisos
select new { perm.IdPerfil,perm.Cat_Perfil.Nivel,perm.Cat_Perfil.Nombre,Nombre_Sistem=perm.Cat_Perfil.Cat_Sistema.Nombre};
And is throwing me an exception, plz help!
I am handling errors via my global.asax in this method:
Dim CurrentException As Exception
CurrentException = Server.GetLastError()
Dim LogFilePath As String = Server.MapPath("~/Error/" & DateTime.Now.ToString("dd-MM-yy.HH.mm") & ".txt")
Dim sw As System.IO.StreamWriter = New System.IO.StreamWriter(LogFilePath)
sw.WriteLine(DateTime.Now.ToString)
sw.WriteLine(CurrentException.ToString())
sw.Close()
In my code I currently have no other error handling. Should I still insert try, catch, finally blocks?
Thanks.
Disclaimer: absolute novice in Scala :(
I have the following defined:
def tryAndReport(body: Unit) : Unit = {
try {
body
} catch {
case e: MySpecificException => doSomethingUseful
}
}
I call it like this:
tryAndReport{
someCodeThatThrowsMySpecificException()
}
While the call to someCodeThatThrowsMySpecificException happens just fine, the exception is not being caught in tryAndReport.
Why?
Thank you!
We are logging any exceptions that happen in our system by writing the Exception.Message to a file. However, they are written in the culture of the client. And Turkish errors don't mean a lot to me.
So how can we log any error messages in English without changing the users culture?
I'm starting getting tired of this exception. Can't handle it, even so I'm using this:
AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException);
Still no success, Can anyone explain me, how I should handle it in a nice way. Or how to detect that it have fired this message and close the application, because I'm starting it automatically everytime it closes.
I have one crash in my iPhone application that does throw an NSException. The crash reports are completely ambiguous in where the error is and what exactly is causing it. Is there a smart way for me to set a top level exception handler somewhere to see what is causing it? I can't replicate the problem myself, but a few of my beta users certainly can.
What's a smart way to handle a problem of this nature?
I recently found a reference to 'Data Vault modeling' as a model for data-warehouses. The models I've seen before are Inmon and Kimball. The author refers to possible performance problems due to the joins needed. It looks like a nice model, but I wonder about the gotcha's. Are there any experience reports on-line?
I have a button and onClick it changes the contentView by setContentView (int layoutResID).
It works fine. But if you take the focus to the button by the trackball(making it yellow) and tap on it, it gives the exception.
java.lang.IllegalArgumentException: parameter must be a descendant of this view
I'm new in web development,
I have a problem in a web application after deployment (it's not appeared in my development machine),
The error in IE after enable the debug mode:
SYS.webforms.pagerequestmanagerserver error exception has been thrown
by the target of an invocation scriptresources.axd
The error is shown when an Ajax ModalPopupExtender is opened.
Inside the popup there's a user control and inside the user control there's a RadGrid from telerik contains a RadAsyncUpload in a GridTemplateColumn
kindly ask me for any extra information
Thanks in advance
Does Exception specification is a part of method signature?
What I mean is:
public void someMethod(String myString) throws IOException
is 'throws IOException' a part of a signature of this method?
Thanks
I have always been of the belief that if a method can throw an exception then it is reckless not to protect this call with a meaningful try block.
I just posted 'You should ALWAYS wrap calls that can throw in try, catch blocks.' to this question and was told that it was 'remarkably bad advice' - I'd like to understand why.
Thanks!
I moved an ASP.NET application from a XP to a new server and now I have this exception:
'System.Security.Permissions.SecurityPermission,
mscorlib, Version=2.0.0.0,
Culture=neutral,
On this line code:
System.Threading.Thread.CurrentThread.CurrentCulture
= new System.Globalization.CultureInfo("it-IT");
My server is so configurated:
Windows XP 2003 Sever
SharePoint
MS Visual Studio 2008 Team System Workgroup Server
I tried to change security setting, machine.config.
Someone can help me explain me where and how to change what?
Thanks a lot.
I'm looking at using SSE and I gather aligning data on 16byte boundaries is recommended. There are two cases to consider:
float data[4];
struct myystruct
{
float x,y,z,w;
};
I'm not sure the first case can be done explicitly, though there's perhaps a compiler option I could use? In the second case I remember being able to control packing in old versions of GCC several years back, is this still possible?
I would want to raise an exception as it's made in Python or Java --to finish the program with an error message--.
An error message could be returned to a parent function:
func readFile(filename string) (content string, err os.Error) {
content, err := ioutil.ReadFile(filename)
if err != nil {
return "", os.ErrorString("read " + filename + ": " + err)
}
return string(content), nil
}
but I want that it can be finished when the error is found. Would be correct the next one?
func readFile(filename string) (content string) {
content, err := ioutil.ReadFile(filename)
defer func() {
if err != nil {
panic(err)
}
}()
return string(content)
}