Search Results

Search found 2343 results on 94 pages for 'masterchris 99'.

Page 65/94 | < Previous Page | 61 62 63 64 65 66 67 68 69 70 71 72  | Next Page >

  • MSTest Test Context Exception Handling

    - by Flip
    Is there a way that I can get to the exception that was handled by the MSTest framework using the TestContext or some other method on a base test class? If an unhandled exception occurs in one of my tests, I'd like to spin through all the items in the exception.Data dictionary and display them to the test result to help me figure out why the test failed (we usually add data to the exception to help us debug in the production env, so I'd like to do the same for testing). Note: I am not testing that an exception was SUPPOSED TO HAPPEN (I have other tests for that), I am testing a valid case, I just need to see the exception data. Here is a code example of what I'm talking about. [TestMethod] public void IsFinanceDeadlineDateValid() { var target = new BusinessObject(); SetupBusinessObject(target); //How can I capture this in the text context so I can display all the data //in the exception in the test result... var expected = 100; try { Assert.AreEqual(expected, target.PerformSomeCalculationThatMayDivideByZero()); } catch (Exception ex) { ex.Data.Add("SomethingImportant", "I want to see this in the test result, as its important"); ex.Data.Add("Expected", expected); throw ex; } } I understand there are issues around why I probably shouldn't have such an encapsulating method, but we also have sub tests to test all the functionality of PerformSomeCalculation... However, if the test fails, 99% of the time, I rerun it passes, so I can't debug anything without this information. I would also like to do this on a GLOBAL level, so that if any test fails, I get the information in the test results, as opposed to doing it for each individual test. Here is the code that would put the exception info in the test results. public void AddDataFromExceptionToResults(Exception ex) { StringBuilder whereAmI = new StringBuilder(); var holdException = ex; while (holdException != null) { Console.WriteLine(whereAmI.ToString() + "--" + holdException.Message); foreach (var item in holdException.Data.Keys) { Console.WriteLine(whereAmI.ToString() + "--Data--" + item + ":" + holdException.Data[item]); } holdException = holdException.InnerException; } }

    Read the article

  • Connection aborted.

    - by Pinu
    I am getting this error when i am trying to upload a file of 3mb or more on my WCF client application. SocketException (0x2745): An established connection was aborted by the software in your host machine] System.Net.Sockets.Socket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags) +73 System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) +131 [IOException: Unable to read data from the transport connection: An established connection was aborted by the software in your host machine.] System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) +294 System.Net.PooledStream.Read(Byte[] buffer, Int32 offset, Int32 size) +26 System.Net.Connection.SyncRead(HttpWebRequest request, Boolean userRetrievedStream, Boolean probeRead) +297 [WebException: The underlying connection was closed: An unexpected error occurred on a receive.] System.Net.HttpWebRequest.GetResponse() +5314029 System.ServiceModel.Channels.HttpChannelRequest.WaitForReply(TimeSpan timeout) +54 [CommunicationException: An error occurred while receiving the HTTP response to http://localhost:4649/Service1.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.] System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) +7596735 System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) +275 SmartConnectClient.SmartConnect.IService1.OrderCertMail(OrderCertMailResponse OrderCertMail1) +0 SmartConnectClient.SmartConnect.Service1Client.OrderCertMail(OrderCertMailResponse OrderCertMail1) in c:\documents and settings\pkale\my documents\visual studio 2008\projects\smartconnectclient\smartconnectclient\service references\smartconnect\reference.cs:1939 SmartConnectClient.Test_CertMail_Order.Page_Load(Object sender, EventArgs e) in C:\Documents and Settings\pkale\My Documents\Visual Studio 2008\Projects\SmartConnectClient\SmartConnectClient\Test_CertMail_Order.aspx.cs:40 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35 System.Web.UI.Control.OnLoad(EventArgs e) +99 System.Web.UI.Control.LoadRecursive() +50 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627 enter code here

    Read the article

  • How to use Object.GetHashCode() on a type that overrides GetHashCode()

    - by Jimmy
    Hi, I have a class A that implements IEquatable<, using its fields (say, A.b and A.c) for implementing/overriding Equals() and overriding GetHashCode(), and everything works fine, 99% of the time. Class A is part of a hierarchy (class B, C) that all inherit from interface D; they can all be stored together in a dictionary Dictionary, thus it's convenient when they all carry their own default Equals()/GetHashCode(). However, while constructing A I sometime need to do some work to get the values for A.b and A.c; while that's happening, I want to store a reference to the instance that's being built. In that case, I don't want to use the default Equals()/GetHashCode() overrides provided by A. Thus, I was thinking of implementing a ReferenceEqualityComparer, that's meant to force the use of Object's Equals()/GetHashCode(): private class ReferenceEqualityComparer<T> : IEqualityComparer<T> { #region IEqualityComparer<T> Members public bool Equals(T x, T y) { return System.Object.ReferenceEquals(x, y); } public int GetHashCode(T obj) { // what goes here? I want to do something like System.Object.GetHashCode(obj); } #endregion } The question is, since A overrides Object.GetHashCode(), how can I (outside of A) call Object.GetHashCode() for an instance of A? One way of course would be for A to not implement IEquatable< and always supply an IEqualityComparer< to any dictionary that I create, but I'm hoping for a different answer. Thanks

    Read the article

  • Is it possible to use theme colors in Windows Forms apps?

    - by Yadyn
    I normally make use of System Colors whenever possible when designing Windows Forms applications just so that it'll fit in with the user's preferences. But is it possible to use Theme Colors? I realize that this limits you in several ways (must be running Windows that supports it and has the Themes service running), so I would certainly like it if it could fall back on some other default, but since I'm fairly sure 99% of my users will have it available, I'd like to make use of it if possible. Specifically, for newer Windows versions (Vista and 7), things like hyperlinks have a softer more pastel-ish blue. The old System Colors do not define anything for links and the like, and in general are much more limited (coming from the 95 days) in choices and variety. Though WPF probably has better support, I'm not at liberty to use it. If some third party utility, assembly, or the like is necessary, it would also need to be free to use. I don't need anything that fancy, but in a perfect world I would be able to do something like this: linkLabel1.LinkColor = System.Drawing.ThemeColors.Hyperlink; Am I stuck just using the default Blue (0,0,255) and having them look out of place in Vista and above? I'll even settle for ugly p/invoke interop methods if need be...

    Read the article

  • [NSCFNumber _isNaturallyRTL]: unrecognized selector sent to instance 0x605ac10

    - by Risma
    my app got crashed an showed that keyword. There is no error and warning. can some body help me?? this is stack that showed : Call stack at first throw: ( 0 CoreFoundation 0x012ccbe9 __exceptionPreprocess + 185 1 libobjc.A.dylib 0x014215c2 objc_exception_throw + 47 2 CoreFoundation 0x012ce6fb -[NSObject(NSObject) doesNotRecognizeSelector:] + 187 3 CoreFoundation 0x0123e366 ___forwarding___ + 966 4 CoreFoundation 0x0123df22 _CF_forwarding_prep_0 + 50 5 UIKit 0x0042d35e -[UITextField setText:] + 53 6 Koder232_risma_edited 0x0006427a -[FilePropertiesViewController viewWillAppear:] + 442 7 UIKit 0x003c4d52 -[UIView(Hierarchy) _willMoveToWindow:withAncestorView:] + 207 8 UIKit 0x003cfa2b -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 378 9 UIKit 0x003cfa5c -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 427 10 UIKit 0x003cfa5c -[UIView(Hierarchy) _makeSubtreePerformSelector:withObject:withObject:copySublayers:] + 427 11 UIKit 0x003c6b36 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 370 12 UIKit 0x003c514f -[UIView(Hierarchy) addSubview:] + 57 13 UIKit 0x006ad8ae -[UIPopoverView presentFromRect:inView:contentSize:backgroundStyle:animated:] + 1920 14 UIKit 0x006a0a4c -[UIPopoverView presentFromRect:inView:animated:] + 236 15 UIKit 0x006d9b20 -[UIPopoverController presentPopoverFromRect:inView:permittedArrowDirections:animated:] + 1046 16 Koder232_risma_edited 0x0001f90f -[codeViewController arrangeTabWithTypeGesture:andNumtag:] + 4683 17 Koder232_risma_edited 0x0001e68f -[codeViewController setTap2:] + 99 18 UIKit 0x0061e9c7 -[UIGestureRecognizer _updateGestureWithEvent:] + 727 19 UIKit 0x0061a9d6 -[UIGestureRecognizer _delayedUpdateGesture] + 47 20 UIKit 0x00620fa5 _UIGestureRecognizerUpdateObserver + 584 21 UIKit 0x0062118a _UIGestureRecognizerUpdateGesturesFromSendEvent + 51 22 UIKit 0x003bc6b4 -[UIWindow _sendGesturesForEvent:] + 1292 23 UIKit 0x003b7f87 -[UIWindow sendEvent:] + 105 24 UIKit 0x0039b37a -[UIApplication sendEvent:] + 447 25 UIKit 0x003a0732 _UIApplicationHandleEvent + 7576 26 GraphicsServices 0x0191fa36 PurpleEventCallback + 1550 27 CoreFoundation 0x012ae064 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 52 28 CoreFoundation 0x0120e6f7 __CFRunLoopDoSource1 + 215 29 CoreFoundation 0x0120b983 __CFRunLoopRun + 979 30 CoreFoundation 0x0120b240 CFRunLoopRunSpecific + 208 31 CoreFoundation 0x0120b161 CFRunLoopRunInMode + 97 32 GraphicsServices 0x0191e268 GSEventRunModal + 217 33 GraphicsServices 0x0191e32d GSEventRun + 115 34 UIKit 0x003a442e UIApplicationMain + 1160 35 Koder232_risma_edited 0x00002680 main + 102 36 Koder232_risma_edited 0x00002611 start + 53 37 ??? 0x00000001 0x0 + 1 )

    Read the article

  • ActivityThread exception in Android?

    - by Praveen Chandrasekaran
    My Log CAT Value: 05-17 15:16:30.572: ERROR/ActivityThread(17448): Activity com.example.brown.Bru_Maps has leaked IntentReceiver android.net.NetworkConnectivityListener$ConnectivityBroadcastReceiver@432e6360 that was originally registered here. Are you missing a call to unregisterReceiver()? 05-17 15:16:30.572: ERROR/ActivityThread(17448): android.app.IntentReceiverLeaked: Activity com.example.brown.Bru_Maps has leaked IntentReceiver android.net.NetworkConnectivityListener$ConnectivityBroadcastReceiver@432e6360 that was originally registered here. Are you missing a call to unregisterReceiver()? 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread$PackageInfo$ReceiverDispatcher.<init>(ActivityThread.java:748) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread$PackageInfo.getReceiverDispatcher(ActivityThread.java:576) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ApplicationContext.registerReceiverInternal(ApplicationContext.java:770) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ApplicationContext.registerReceiver(ApplicationContext.java:757) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ApplicationContext.registerReceiver(ApplicationContext.java:751) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.content.ContextWrapper.registerReceiver(ContextWrapper.java:290) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.net.NetworkConnectivityListener.startListening(NetworkConnectivityListener.java:138) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at com.google.android.maps.MapActivity.onResume(MapActivity.java:232) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1225) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.Activity.performResume(Activity.java:3559) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread.performResumeActivity(ActivityThread.java:2838) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:2866) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1819) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.os.Handler.dispatchMessage(Handler.java:99) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.os.Looper.loop(Looper.java:123) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at android.app.ActivityThread.main(ActivityThread.java:4203) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at java.lang.reflect.Method.invokeNative(Native Method) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at java.lang.reflect.Method.invoke(Method.java:521) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:791) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 05-17 15:16:30.572: ERROR/ActivityThread(17448): at dalvik.system.NativeStart.main(Native Method) What is the Activity Thread Exception in Android? Please Help.

    Read the article

  • android checkbox box issue

    - by raqz
    i have this check box in a alertdialog. when i try to check the state of the checkbox, the application force closes. any idea why? LayoutInflater factory = LayoutInflater.from(NewActivity.this); final View textDisplayView = factory.inflate(R.layout.nearestlocs, null); final AlertDialog.Builder newAlert = new AlertDialog.Builder(NewActivity.this); newAlert.setView(textDisplayView); final CheckBox checkBoxLab = (CheckBox) findViewById(R.id.checkboxlab); newAlert.setPositiveButton("Display on Map", new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int whichButton) { if(checkBoxLab.isChecked()){ libDisplayFlag = true; } error log 03-13 08:01:58.273: ERROR/AndroidRuntime(6188): Uncaught handler: thread main exiting due to uncaught exception 03-13 08:01:58.292: ERROR/AndroidRuntime(6188): java.lang.NullPointerException 03-13 08:01:58.292: ERROR/AndroidRuntime(6188): at com.isproj3.NewActivity$3.onClick(NewActivity.java:158) 03-13 08:01:58.292: ERROR/AndroidRuntime(6188): at com.android.internal.app.AlertController$ButtonHandler.handleMessage(AlertController.java:158) 03-13 08:01:58.292: ERROR/AndroidRuntime(6188): at android.os.Handler.dispatchMessage(Handler.java:99) xml <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"> <LinearLayout android:orientation="horizontal" android:gravity="center" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1"> <CheckBox android:id="@+id/checkboxlib" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Library" android:gravity="left" android:textColor="#FF0000" android:paddingBottom="5px" android:textSize="07pt" android:checked="true" /> <TextView android:id="@+id/librarytext" android:layout_width="wrap_content" android:layout_height="wrap_content" android:gravity="center" android:paddingBottom="5px" android:textSize="8pt" /> </LinearLayout> </LinearLayout>

    Read the article

  • Problems with jQuery load and getJSON only when using Chrome

    - by leftend
    I'm having an issue with two jQuery calls. The first is a "load" that retrieves HTML and displays it on the page (it does include some Javascript and CSS in the code that is returned). The second is a "getJSON" that returns JSON - the JSON returned is valid. Everything works fine in every other browser I've tried - except Chrome for either Windows or Mac. The page in question is here: http://urbanistguide.com/category/Contemporary.aspx When you click on a Restaurant name in IE/FF, you should see that item expand with more info - and a map displayed to the right. However, if you do this in Chrome all you get is the JSON data printed to the screen. The first problem spot is when the "load" function is called here: var fulllisting = top.find(".listingfull"); fulllisting.load(href2, function() { fulllisting.append("<div style=\"width:99%;margin-top:10px;text-align:right;\"><a href=\"#\" class=\"" + obj.attr("id") + "\">X</a>"); itemId = fulllisting.find("a.listinglink").attr("id"); ... In the above code, the callback function doesn't seem to get invoked. The second problem spot is when the "getJSON" function is called: $.getJSON(href, function(data) { if (data.error.length > 0) { //display error message } else { ... } In this case - it just seems to follow the link instead of performing the callback... and yes, I am doing a "return false;" at the end of all of this to prevent the link from executing. All of the rest of the code is inline on that page if you want to view the source code. Any ideas?? Thanks

    Read the article

  • Exception in setDrawingCache in Android 1.5?

    - by sunil
    Hi, I am developing an application where I am using setDrawingCache and then once I get the Bitmap I destroy the cache by using destroyDrawingCache(). The application has been developed with Android SDK 1.6. When testing the application in emulator with Android 1.5 the application throws NullPointerException when try to manipulate the Bitmap returned by getDrawingCache(). It probably gives error since getDrawingCache returns null. The interesting thing in this is that the NullPointerException comes only after I run the application twice or thrice. It means I am able to get the Bitmap for two times and then it throws this exception. The error that I am getting is as below java.lang.NullPointerException E/AndroidRuntime( 1036): at com.babbleville.HomeScreenActivity.resizeBitmap(HomeScreenActivity.java: 394) E/AndroidRuntime( 1036): at com.babbleville.HomeScreenActivity.access $0(HomeScreenActivity.java:392) E/AndroidRuntime( 1036): at com.babbleville.HomeScreenActivity $1.handleMessage(HomeScreenActivity.java:327) E/AndroidRuntime( 1036): at android.os.Handler.dispatchMessage(Handler.java:99) E/AndroidRuntime( 1036): at android.os.Looper.loop(Looper.java:123) E/AndroidRuntime( 1036): at android.app.ActivityThread.main(ActivityThread.java:3948) E/AndroidRuntime( 1036): at java.lang.reflect.Method.invokeNative(Native Method) E/AndroidRuntime( 1036): at java.lang.reflect.Method.invoke(Method.java:521) E/AndroidRuntime( 1036): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:782) E/AndroidRuntime( 1036): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540) E/AndroidRuntime( 1036): at dalvik.system.NativeStart.main(Native Method) Can someone please let me know the problem? Regards Sunil

    Read the article

  • sed/awk or other: one-liner to increment a number by 1 keeping spacing characters

    - by WizardOfOdds
    EDIT: I don't know in advance at which "column" my digits are going to be and I'd like to have a one-liner. Apparently sed doesn't do arithmetic, so maybe a one-liner solution based on awk? I've got a string: (notice the spacing) eh oh 37 and I want it to become: eh oh 36 (so I want to keep the spacing) Using awk I don't find how to do it, so far I have: echo "eh oh 37" | awk '$3>=0&&$3<=99 {$3--} {print}' But this gives: eh oh 36 (the spacing characters where lost, because the field separator is ' ') Is there a way to ask awk something like "print the output using the exact same field separators as the input had"? Then I tried yet something else, using awk's sub(..,..) method: ' sub(/[0-9][0-9]/, ...) {print}' but no cigar yet: I don't know how to reference the regexp and do arithmetic on it in the second argument (which I left with '...' for now). Then I tried with sed, but got stuck after this: echo "eh oh 37" | sed -e 's/\([0-9][0-9]\)/.../' Can I do arithmetic from sed using a reference to the matching digits and have the output not modify the number of spacing characters? Note that it's related to my question concerning Emacs and how to apply this to some (big) Emacs region (using a replace region with Emacs's shell-command-on-region) but it's not an identical question: this one is specifically about how to "keep spaces" when working with awk/sed/etc.

    Read the article

  • boost::binding that which is already bound

    - by PaulH
    I have a Visual Studio 2008 C++ application that does something like this: template< typename Fcn > inline void Bar( Fcn fcn ) // line 84 { fcn(); }; template< typename Fcn > inline void Foo( Fcn fcn ) { // this works fine Bar( fcn ); // this fails to compile boost::bind( Bar, fcn )(); }; void main() { SYSTEM_POWER_STATUS_EX status = { 0 }; Foo( boost::bind( ::GetSystemPowerStatusEx, &status, true ) ); // line 160 } *The call to GetSystemPowerStatusEx() is just for demonstration. Insert your favorite call there and the behavior is the same. When I go to compile this, I get 84 errors. I won't post them all unless asked, but they start with this: 1>.\MyApp.cpp(99) : error C2896: 'boost::_bi::bind_t<_bi::dm_result<MT::* ,A1>::type,boost::_mfi::dm<M,T>,_bi::list_av_1<A1>::type> boost::bind(M T::* ,A1)' : cannot use function template 'void Bar(Fcn)' as a function argument 1> .\MyApp.cpp(84) : see declaration of 'Bar' 1> .\MyApp.cpp(160) : see reference to function template instantiation 'void Foo<boost::_bi::bind_t<R,F,L>>(Fcn)' being compiled 1> with 1> [ 1> R=BOOL, 1> F=BOOL (__cdecl *)(PSYSTEM_POWER_STATUS_EX,BOOL), 1> L=boost::_bi::list2<boost::_bi::value<_SYSTEM_POWER_STATUS_EX *>,boost::_bi::value<bool>>, 1> Fcn=boost::_bi::bind_t<BOOL,BOOL (__cdecl *)(PSYSTEM_POWER_STATUS_EX,BOOL),boost::_bi::list2<boost::_bi::value<_SYSTEM_POWER_STATUS_EX *>,boost::_bi::value<bool>>> 1> ] If anybody can point out what I may be doing wrong, I would appreciate it. Thanks, PaulH

    Read the article

  • 'License expired' error when dynamically generating Excel docs in ASP.NET

    - by Mac
    Anyone familiar with error below? When I run my webapp to generate a dynamic excel doc from my local machine it works fine but when the same piece of code is invoked on the server I get the below error. It seems like it's a permissions issues since it works on my machine but not the server but I don't know where to start in order to pinpoint the problem. Any guidance/help is greatly appreciated! Server Error in '/' Application. -------------------------------------------------------------------------------- This command is unavailable because the license to use this application has expired. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Runtime.InteropServices.COMException: This command is unavailable because the license to use this application has expired. Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [COMException (0x800a03ec): This command is unavailable because the license to use this application has expired.] Microsoft.Office.Interop.Excel.Workbooks.Add(Object Template) +0 PaymentsReport.Page_Load(Object sender, EventArgs e) +70 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34 System.Web.UI.Control.OnLoad(EventArgs e) +99 System.Web.UI.Control.LoadRecursive() +47 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061 Office/Excel is installed on the server and I can open/save excel docs on the server. Could it be the version of excel on the server vs. my local machine? If so how can I make sure I have the latest on the server?

    Read the article

  • Detecting cause of RuntimeException: Unable to stop activity

    - by Pentium10
    I have a really weird error, and I don't know what is causing this. It happens when I leave the Activity. 05-16 12:26:20.360: ERROR/AndroidRuntime(11648): Uncaught handler: thread main exiting due to uncaught exception 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): java.lang.RuntimeException: Unable to stop activity {com.myapk/com.myapk.modules.viewPairing}: java.lang.NullPointerException 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3596) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3674) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.access$2800(ActivityThread.java:126) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1965) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.os.Handler.dispatchMessage(Handler.java:99) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.os.Looper.loop(Looper.java:123) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.main(ActivityThread.java:4595) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at java.lang.reflect.Method.invokeNative(Native Method) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at java.lang.reflect.Method.invoke(Method.java:521) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at dalvik.system.NativeStart.main(Native Method) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): Caused by: java.lang.NullPointerException 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.Activity.performStop(Activity.java:3848) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3591) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): ... 11 more

    Read the article

  • Lua Alien Module - Trouble using WriteProcessMemory function, unsure on types (unit32)

    - by jefferysanders
    require "alien" --the address im trying to edit in the Mahjong game on Win7 local SCOREREF = 0x0744D554 --this should give me full access to the process local ACCESS = 0x001F0FFF --this is my process ID for my open window of Mahjong local PID = 1136 --function to open proc local op = alien.Kernel32.OpenProcess op:types{ ret = "pointer", abi = "stdcall"; "int", "int", "int"} --function to write to proc mem local wm = alien.Kernel32.WriteProcessMemory wm:types{ ret = "long", abi = "stdcall"; "pointer", "pointer", "pointer", "long", "pointer" } local pRef = op(ACCESS, true, PID) local buf = alien.buffer("99") -- ptr,uint32,byte arr (no idea what to make this),int, ptr print( wm( pRef, SCOREREF, buf, 4, nil)) --prints 1 if success, 0 if failed So that is my code. I am not even sure if I have the types set correctly. I am completely lost and need some guidance. I really wish there was more online help/documentation for alien, it confuses my poor brain. What utterly baffles me is that it WriteProcessMemory will sometimes complete successfully (though it does nothing at all, to my knowledge) and will also sometimes fail to complete successfully. As I've stated, my brain hurts. Any help appreciated.

    Read the article

  • Unable to call RESTful web services methods

    - by Alessandro
    Hello, I'm trying to dive into the RESTful web services world and have started with the following template: [ServiceContract] [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)] [ServiceBehavior(InstanceContextMode = InstanceContextMode.PerCall)] public class Test { // TODO: Implement the collection resource that will contain the SampleItem instances [WebGet(UriTemplate = ""), OperationContract] public List<SampleItem> GetCollection() { // TODO: Replace the current implementation to return a collection of SampleItem instances return new List<SampleItem>() {new SampleItem() {Id = 1, StringValue = "Hello"}}; } [WebInvoke(UriTemplate = "", Method = "POST"), OperationContract] public SampleItem Create(SampleItem instance) { // TODO: Add the new instance of SampleItem to the collection throw new NotImplementedException(); } [WebGet(UriTemplate = "{id}"), OperationContract] public SampleItem Get(string id) { // TODO: Return the instance of SampleItem with the given id throw new NotImplementedException(); } [WebInvoke(UriTemplate = "{id}", Method = "PUT"), OperationContract] public SampleItem Update(string id, SampleItem instance) { return new SampleItem { Id = 99, StringValue = "Done" }; } [WebInvoke(UriTemplate = "{id}", Method = "DELETE"), OperationContract] public void Delete(string id) { // TODO: Remove the instance of SampleItem with the given id from the collection throw new NotImplementedException(); } } I am able to perform the GET operation but I am unable to perform PUT, POST or DELETE requests. Can anyone explain me how to perform these operations and how to create the correct URLs? Best regards Alessandro

    Read the article

  • pylons on production server fedora 8

    - by stormdrain
    I'm interested in learning some python, and thought Pylons would be a good starting point (after spending 2 days trying to get django working -- to no avail). I have an Amazon EC2 instance with Fedora 8 on it. It is a bare-bones install. I am halfway through my second day of trying to get it to work. I have mod_wsgi installed. I have Apache (though that's a later task to tackle). I have easy_install, paster is working fine; basically all of the pre-requisites mentioned throughout the Pylons docs. I can't for the life of me get the thing to work. And I can't seem to find a coherent walkthough anywhere that lists all the steps necessary. There is tons of info out there, but it is all scattered. Wsgi this, python that. Google, google, google... "47 million results found for 'socket.error:(lol, 'Yous a goofs')". So, this is my latest attempt: apachectl -k stop cd /home/ paster create -t pylons test [blah blah.. ok] cd test nano development.ini [hmm, last time I changed the host from 127.0.0.1 to my domain name or url, it threw an error like socket.error: (99, 'Cannot assign requested address')... I'll just leave it] [open port 5000 on firewall] paster serve development.ini [firefox-url:5000] Firefox can't establish a connection to the server Doing these steps locally works as expected. This is just a test to see if I can get it to work at all, which I can't. If I get it to work, then is the task of getting it to work with apache. My madness is that I'd like to play around a little developing and deploying before diving into a full-fledged project. So far: self, I am dissapoint.

    Read the article

  • Circle drawing with SVG's arc path

    - by ????
    The following SVG path can draw 99.99% of a circle: (try it on http://jsfiddle.net/DFhUF/46/ and see if you see 4 arcs or only 2, but note that if it is IE, it is rendered in VML, not SVG, but have the similar issue) M 100 100 a 50 50 0 1 0 0.00001 0 But when it is 99.99999999% of a circle, then nothing will show at all? M 100 800 a 50 50 0 1 0 0.00000001 0 And that's the same with 100% of a circle (it is still an arc, isn't it, just a very complete arc) M 100 800 a 50 50 0 1 0 0 0 How can that be fixed? The reason is I use a function to draw a percentage of an arc, and if I need to "special case" a 99.9999% or 100% arc to use the circle function, that'd be kind of silly. Again, a test case on jsfiddle using RaphaelJS is at http://jsfiddle.net/DFhUF/46/ (and if it is VML on IE 8, even the second circle won't show... you have to change it to 0.01) Update: This is because I am rendering an arc for a score in our system, so 3.3 points get 1/3 of a circle. 0.5 gets half a circle, and 9.9 points get 99% of a circle. But what if there are scores that are 9.99 in our system? Do I have to check whether it is close to 99.999% of a circle, and use an arc function or a circle function accordingly? Then what about a score of 9.9987? Which one to use? It is ridiculous to need to know what kind of scores will map to a "too complete circle" and switch to a circle function, and when it is "a certain 99.9%" of a circle or a 9.9987 score, then use the arc function.

    Read the article

  • sqlite3 no insert is done after --> insert into --> SQLITE_DONE

    - by Fra
    Hi all, I'm trying to insert some data in a table using sqlite3 on an iphone... All the error codes I get from the various steps indicate that the operation should have been successful, but in fact, the table remains empty...I think I'm missing something... here the code: sqlite3 *database = nil; NSString *dbPath = [[[ NSBundle mainBundle ] resourcePath ] stringByAppendingPathComponent:@"placemarks.sql"]; if(sqlite3_open([dbPath UTF8String], &database) == SQLITE_OK){ sqlite3_stmt *insert_statement = nil; //where int pk, varchar name,varchar description, blob picture static char *sql = "INSERT INTO placemarks (pk, name, description, picture) VALUES(99,'nnnooooo','dddooooo', '');"; if (sqlite3_prepare_v2(database, sql, -1, &insert_statement, NULL) != SQLITE_OK) { NSAssert1(0, @"Error: failed to prepare statement with message '%s'.", sqlite3_errmsg(database)); } int success = sqlite3_step(insert_statement); int finalized = sqlite3_finalize(insert_statement); NSLog(@"success: %i finalized: %i",success, finalized); NSAssert1(101, @"Error: failed to insert into the database with message '%s'.", sqlite3_errmsg(database)); sqlit3_step returns 101, so SQLITE_DONE, which should be ok.. If I execute the sql statement in the command line it works properly... anyone has an idea? could it be that there's a problem in writing the placemarks.sql because it's in the resources folder? rgds Fra

    Read the article

  • [ActionScript 3] Array subclasses cannot be deserialized, Error #1034

    - by aaaidan
    I've just found a strange error when deserializing from a ByteArray, where Vectors cannot contain types that extend Array: there is a TypeError when they are deserialized. TypeError: Error #1034: Type Coercion failed: cannot convert []@4b8c42e1 to com.myapp.ArraySubclass. at flash.utils::ByteArray/readObject() at com.myapp::MyApplication()[/Users/aaaidan/MyApp/com/myapp/MyApplication.as:99] Here's how: public class Application extends Sprite { public function Application() { // register the custom class registerClassAlias("MyArraySubclass", MyArraySubclass); // write a vector containing an array subclass to a byte array var vec:Vector.<MyArraySubclass> = new Vector.<MyArraySubclass>(); var arraySubclass:MyArraySubclass = new MyArraySubclass(); arraySubclass.customProperty = "foo"; vec.push(arraySubclass); var ba:ByteArray = new ByteArray(); ba.writeObject(arraySubclass); ba.position = 0; // read it back var arraySubclass2:MyArraySubclass = ba.readObject() as MyArraySubclass; // throws TypeError } } public class MyArraySubclass extends Array { public var customProperty:String = "default"; } It's a pretty specific case, but it seems very odd to me. Anyone have any ideas what's causing it, or how it could be fixed?

    Read the article

  • SQL INSTR() using CSV. Need exact match rather than part

    - by Alastair Pitts
    This is a follow up issue relating to the answer for http://stackoverflow.com/questions/2445029/sql-placeholder-in-where-in-issue-inserted-strings-fail Quick background: We have a SQL query that uses a placeholder value to accept a string, which represents a unique tag/id. Usually, this is only a single tag, but we needed the ability to use a csv string for multiple tags, returning a combined result. In the answer we received from the vendor, they suggested the use of the INSTR function, ala: select * from pitotal where tag IN (SELECT tag from pipoint WHERE INSTR(?, tag) <> 0) and time between 'y' and 't' This works perfectly well 99% of the time, the issue is when the tag is also a subset of 2 parts of the CSV string. Eg the placeholder value is: 'northdom,southdom,eastdom,westdom' and possible tags include: north or northdom What happens, as north is a subset of northdom, is that the two tags are return instead of just northdom, which is actually what we want. I'm not strong on SQL so I couldn't work out how to set it as exact, or split the csv string, so help would be appreciated. Is there a way to split the csv string or make it look for an exact match?

    Read the article

  • "The given key was not present in the dictionary" ASP.NET error on IIS7

    - by eugeneK
    Hi, i have this error on one of my sites. Searched thought all project found no Dictionary of some kind. Read somewhere it could be caused by Url Rewrite module on IIS 7 which i'm using for certain redirects. Error appears on all pages thought the site, 99% sure only on pages that use Url Rewriting This is error's stack at System.ThrowHelper.ThrowKeyNotFoundException() at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at System.Data.DataView.System.Collections.IList.get_Item(Int32 recordIndex) at System.Web.UI.WebControls.ListViewPagedDataSource.EnumeratorOnIList.get_Current() at System.Web.UI.WebControls.ListView.CreateItemsWithoutGroups(ListViewPagedDataSource dataSource, Boolean dataBinding, InsertItemPosition insertPosition, ArrayList keyArray) at System.Web.UI.WebControls.ListView.CreateChildControls(IEnumerable dataSource, Boolean dataBinding) at System.Web.UI.WebControls.ListView.PerformDataBinding(IEnumerable data) at System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) at System.Web.UI.WebControls.DataBoundControl.PerformSelect() at System.Web.UI.WebControls.ListView.PerformSelect() at System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() at System.Web.UI.WebControls.ListView.CreateChildControls() at System.Web.UI.Control.EnsureChildControls() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)HTTP_CONNECTION:Keep-Alive HTTP_ACCEPT:image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, application/x-icq, / HTTP_ACCEPT_LANGUAGE:en HTTP_COOKIE:__utma=248870149.1673016949.1252234176.1276449788.1276595165.49; __utmz=248870149.1276595165.49.55.utmcsr=search|utmccn=(organic)|utmcmd=organic|utmctr=???%20??; wooTracker=C1T8MWMAZWQVHJXWROHB25SO4S0B7UO0; __utmb=248870149.6.10.1276595165; __utmc=248870149; wooTracker=C1T8MWMAZWQVHJXWROHB25SO4S0B7UO0; machine-id=87.69.44.154%3A1253914747956; wooMeta=ODAwMzkmMSYxJjc1MDE5JjEyNTUyMTQwODEwMjkmMTI1NTIxNDE1NjA0OCYmMTAwJiYzMDAyODQmJiYm; _csoot=1267959625296; _csuid=X4c1ef311c39a67; ASP.NET_SessionId=zzdn5b45uqyhw145ptqhxe20 HTTP_HOST:**** HTTP_REFERER:***** HTTP_USER_AGENT:Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; GTB6) HTTP_X_CEPT_ENCODING:gzip, deflate ***** Is anyone familiar with fix or at least where to look for one ?

    Read the article

  • CSS3 Gradients and border-radius leading to extraneous background in webkit

    - by iamfriendly
    Hello all, After my 1st question with relation to CSS3 gradients in which I was recreating an 'inner glow' I've now got to the point where I'm not so happy with the way in which webkit renders the effect. Basically, if you give an element a background colour and apply a border radius to it, webkit lets the background colour "bleed" out to fill the surrounding box (making it look a bit awful) To reproduce the undesirable effect, try something like the following section#featured footer p a { color: rgb(255,255,255); text-shadow: 1px 1px 1px rgba(0,0,0,0.6); text-decoration: none; padding: 5px 10px; border-radius: 15px; -moz-border-radius: 15px; -webkit-border-radius: 15px; background: rgb(98,99,100); -moz-box-shadow: inset 0 0 8px rgba(0,0,0, 0.25); -webkit-box-shadow: inset 0 0 8px rgba(0,0,0, 0.25); } You can see an example of this here: http://iamfriendly.clients.friendlygp.com/ Apparently this appears to be a Windows-only problem, so for those on a Mac, here's a screenshot: (Check the 'carry on reading' button) You'll notice that in Safari/Chrome (the latest available public downloads as well as the latest nightlies as far as I can tell), you get a rather ugly background colour bleed. However, in Firefox, you should be able to see what I'm after. If you're in Internet Explorer, woe betide you. Does anyone know of a technique which will allow me to produce the 'correct' effect? Is there a CSS Property which I've missed that tells webkit to only have the background within the border-radius'd part of the containing box. I could potentially use an image, but I'm really trying to avoid it. Naturally, as we're dealing with CSS3 and the landscape is continually changing, I might just have to 'lump' it and revert to an image. However, if anyone can suggest an alternative I would be very much appreciative!

    Read the article

  • Android java.lang.VerifyError for private method with annotated argument.

    - by alex2k8
    I have a very simple project that compiles, but can't be started on Emulator. The problem is with this method: private void bar(@Some String a) {} // java.lang.VerifyError The issue can be avoided if annotation removed private void bar(String a) {} // OK or the method visibility changed: void bar(@Some String a) {} // OK public void bar(@Some String a) {} // OK protected void bar(@Some String a) {} // OK Any idea what is wrong with original method? Is this a dalvik bug, or? If some one whould like to experiment with code, here it is: Test.java: public class Test { private void bar(@Some String a) {} public void foo() { bar(null); } } Some.java: public @interface Some {} MainActivity.java: public class MainActivity extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); new Test().foo(); } } Stack trace: ERROR/dalvikvm(1358): Could not find method com.my.Test.bar, referenced from method com.my.Test.foo WARN/dalvikvm(1358): VFY: unable to resolve direct method 11: Lcom/my/Test;.bar (Ljava/lang/String;)V WARN/dalvikvm(1358): VFY: rejecting opcode 0x70 at 0x0001 WARN/dalvikvm(1358): VFY: rejected Lcom/my/Test;.foo ()V WARN/dalvikvm(1358): Verifier rejected class Lcom/my/Test; DEBUG/AndroidRuntime(1358): Shutting down VM WARN/dalvikvm(1358): threadid=3: thread exiting with uncaught exception (group=0x4000fe70) ERROR/AndroidRuntime(1358): Uncaught handler: thread main exiting due to uncaught exception ERROR/AndroidRuntime(1358): java.lang.VerifyError: com.my.Test ERROR/AndroidRuntime(1358): at com.my.MainActivity.onCreate(MainActivity.java:13) ERROR/AndroidRuntime(1358): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123) ERROR/AndroidRuntime(1358): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2231) ERROR/AndroidRuntime(1358): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2284) ERROR/AndroidRuntime(1358): at android.app.ActivityThread.access$1800(ActivityThread.java:112) ERROR/AndroidRuntime(1358): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1692) ERROR/AndroidRuntime(1358): at android.os.Handler.dispatchMessage(Handler.java:99) ERROR/AndroidRuntime(1358): at android.os.Looper.loop(Looper.java:123) ERROR/AndroidRuntime(1358): at android.app.ActivityThread.main(ActivityThread.java:3948) ERROR/AndroidRuntime(1358): at java.lang.reflect.Method.invokeNative(Native Method) ERROR/AndroidRuntime(1358): at java.lang.reflect.Method.invoke(Method.java:521) ERROR/AndroidRuntime(1358): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:782) ERROR/AndroidRuntime(1358): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540) ERROR/AndroidRuntime(1358): at dalvik.system.NativeStart.main(Native Method)

    Read the article

  • HashMap key problems

    - by Peterdk
    I'm profiling some old java code and it appears that my caching of values using a static HashMap and a access method does not work. Caching code (a bit abstracted): static HashMap<Key, Value> cache = new HashMap<Key, Value>(); public static Value getValue(Key key){ System.out.println("cache size="+ cache.size()); if (cache.containsKey(key)) { System.out.println("cache hit"); return cache.get(key); } else { System.out.println("no cache hit"); Value value = calcValue(); cache.put(key, value); return value; } } Profiling code: for (int i = 0; i < 100; i++) { getValue(new Key()); } Result output: cache size=0 no cache hit (..) cache size=99 no cache hit It looked like a standard error in Key's hashing code or equals code. However: new Key().hashcode == new Key().hashcode // TRUE new Key().equals(new Key()) // TRUE What's especially weird is that cache.put(key, value) just adds another value to the hashmap, instead of replacing the current one. So, I don't really get what's going on here. Am I doing something wrong?

    Read the article

  • Full text index requires dropping and recreating - why?

    - by Amjid Qureshi
    Hi all, So I've got a web app running on .net 3.5 connected to a SQL 2005 box. We do scheduled releases every 2 weeks. About 14 tables out of 250 are full text indexed. After not every release, but a few too many, the indexes crap out. They seem to have data in there, but when we try to search them from the front end or SQL enterprise we get timeouts/hangs. We have a script that disables the indexes, drops them, deletes the catalog and then re creates the indexes. This fixes the problem 99 times out of 100. and the one other time, we run the script again and it all works We have tried just rebuilding the fulltext index but that doesn't fix the issue. My question is why do we have to do this ? what can we do to sort the index out? Here is a bit of the script, IF EXISTS (SELECT * FROM sys.fulltext_indexes fti WHERE fti.object_id = OBJECT_ID(N'[dbo].[Address]')) ALTER FULLTEXT INDEX ON [dbo].[Address] DISABLE GO IF EXISTS (SELECT * FROM sys.fulltext_indexes fti WHERE fti.object_id = OBJECT_ID(N'[dbo].[Address]')) DROP FULLTEXT INDEX ON [dbo].[Address] GO IF EXISTS (SELECT * FROM sysfulltextcatalogs ftc WHERE ftc.name = N'DbName.FullTextCatalog') DROP FULLTEXT CATALOG [DbName.FullTextCatalog] GO -- may need this line if we get an error BACKUP LOG SMS2 WITH TRUNCATE_ONLY CREATE FULLTEXT CATALOG [DbName.FullTextCatalog] ON FILEGROUP [FullTextCatalogs] IN PATH N'F:\Data' AS DEFAULT AUTHORIZATION [dbo] CREATE FULLTEXT INDEX ON [Address](CommonPlace LANGUAGE 'ENGLISH') KEY INDEX PK_Address ON [DbName.FullTextCatalog] WITH CHANGE_TRACKING AUTO go

    Read the article

< Previous Page | 61 62 63 64 65 66 67 68 69 70 71 72  | Next Page >