Re: [mono-android] System.Net.WebClient.UploadFileAsync Problem

2012-01-19 Thread subsembly
It's not a feature request. It's a SEVERE BUG in the Mono WebClient implementation! -- View this message in context: http://mono-for-android.1047100.n5.nabble.com/System-Net-WebClient-UploadFileAsync-Problem-tp5157961p5158060.html Sent from the Mono for Android mailing list archive at Nabble.com

Re: [mono-android] System.Net.WebClient.UploadFileAsync Problem

2012-01-19 Thread subsembly
Thank you very much. Maybe I should explain my situation: I bought a MonoTouch + MonoDroid enterprise licence almost a year ago, when it was still with Novell. We already have two applications developed in C# for .NET 2.0 for Windows Desktop and also for the .NET Compact Framework for those good o

Re: [mono-android] System.Net.WebClient.UploadFileAsync Problem

2012-01-19 Thread subsembly
Got me :-) To my surprise your code does indeed add the MIME header stuff, even on the .NET Framework for Windows. So I went back to my real application code to check this out. I found the difference is that we are using "PUT" and not "POST" as the HTTP method. If you change your line to wc.Uplo

[mono-android] Memory Leak with Background Image

2012-01-23 Thread subsembly
Hi, it seems that bitmap images attached as background drawables are never released. In order to re-create the problem just create a default Mono for Android project and add the line android:background="@drawable/wallpaper" to the outer LinearLayout. Also add a wallpaper.png image (make it large

Re: [mono-android] Layout - Activity with ListView and TextView below it

2012-01-23 Thread subsembly
A more optimized layout serving the same purpose would be: http://schemas.android.com/apk/res/android"; android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > Less nesting means faster layout. Also I would prefer to u

Re: [mono-android] upper limit on resources/drawable size?

2012-01-25 Thread subsembly
Hi, I do not know whether there is an upper limit to the file size, but you have to keep in mind that a JPEG file with a pixel size of 1000x1000 that is maybe only a 50 KB file, will require 3 MB (1000x1000x3) when loaded. Therefore I am more concerned with the resulting pixel size of images, then

Re: [mono-android] Memory Leak with Background Image

2012-01-25 Thread subsembly
Thanks, that did solve the problem. I also added another GC.Collect() in my OnRestart() override, just to be absolutely sure. Cheers, Andreas. -- View this message in context: http://mono-for-android.1047100.n5.nabble.com/Memory-Leak-with-Background-Image-tp5165833p5430759.html Sent from the Mon

Re: [mono-android] sharing code between mono touch and mono for android

2012-01-30 Thread subsembly
Hi, we are sharing code across Windows .NET, Mono for Android and MonoTouch. Earlier we even also shared with .NET Compact Framework for Windows Mobile. We are sharing the source code using the Share feature of Visual SourceSafe which is very very useful for this kind of setup. If a code change i

[mono-android] Understanding ArrayAdapter and Java.Lang.Object

2012-08-09 Thread subsembly
Hi all, I am trying to understand what exactly happens when I am using an Android.Widget.ArrayAdapter for my list views and spinners. Considering the following sample code from an Activity: string[] vs = new string[] { "one", "two", "three" } ArrayAdapter aa = new ArrayAdapter(this, Android.Resou

Re: [mono-android] Understanding ArrayAdapter and Java.Lang.Object

2012-08-10 Thread subsembly
Thanks for your elaborate answer. My code to get the selected item now looks like this: Java.Lang.Object o = spinner.SelectedItem; string s = o.ToString(); o.Dispose(); Think this is the best was to do. For more complex list items I am already deriving from BaseAdapter. I will continue to use the

Re: [mono-android] Listview

2012-08-13 Thread subsembly
Jonathan Pryor-2 wrote > >> However, in my experience the Google docs are terrible. > Fully agree. Just try to understand the many Adapter classes based on documentation that does nothing but rephrase the method signatures. In the end it is just "trial and error" or "looking at the source".

Re: [mono-android] (aresgen) Finding Layout xml errors

2011-05-13 Thread subsembly
Hi, this exception happens whenever a referenced resource id could not be resolved. In particular it happens whenever using upper case characters in color names, or many other resource ids. To avoid this problem it is best to only use lower case characters for any and all resource file names and i

Re: [mono-android] Miguel's Announcement...

2011-05-25 Thread subsembly
I was hoping for something more, too. As the current Android for Mono release is not at all stable enough for a real product our company abandoned all Android (MonoDroid) development for now. This is a pity, as we did invest a lot of work and also bought a license that is actually worthless by no

[mono-android] HTTPS Communication fails after update to 4.0

2011-12-06 Thread subsembly
Hi, my application was working flawlessly with the last official Android for Mono release. After upgrading to 4.0, however, my online communication code fails with the following internal error: 12-06 15:20:52.185: I/mono-stderr(16976): ERROR building certificate chain: System.NullReferenceExcepti

Re: [mono-android] HTTPS Communication fails after update to 4.0

2011-12-14 Thread subsembly
Hi, I am testing with an LG Optimus One and an LG Optimus 2X (both with Gingerbread). The error occurs, for example, when accessing the PayPal NVP API at "https://api-3t.paypal.com/nvp";. I am using HttpWebRequest via WebRequest.Create(sUrl). Thank's for your support. -- View this message in c

Re: [mono-android] VS2010 crash on F5

2012-01-12 Thread subsembly
Hi, where do I find the "release notes"? I can't find them anywhere in the documentation linked from xamarin.com. Also, how can I check which version of Mono for Android is currently integrated in VisualStudio? Can't find any "about" dialog or something. Finally: I just downloaded the free previ

[mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-13 Thread subsembly
Hi, I am currently porting some (actually a lot of) code from .NET to Mono for Android. At one point there seems to be a problem with the WebClient class, in particular when the connected server responds with an error. The following code snippet can easily provoke (and also explains) the problem:

Re: [mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-13 Thread subsembly
Hi, during further porting I found, that a request sent through the WebClient sometimes succeeds and sometimes fails. I am not sure whether this is a device related problem. However, the same code always succeeds on my desktop PC connect to the same W-LAN. In order to reproduce you just have to c

Re: [mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-13 Thread subsembly
Hi, yet again :-) I just tested my second example code on an LG Optimus One, and it works every time I click the button. Again on the same W-LAN. So it seems that the Problem is related to the LG Optimus 2X. BTW: The Optimus One runs Android 2.3.3, the Optimus 2X runs Android 2.3.4. Could the pro

Re: [mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-13 Thread subsembly
So far I have only be running Debug builds with shared runtime on Android 2.3.3 or Android 2.3.4 only. According to the Visual Studio Help/About I am using Mono for Android 4.0.1. I have to admit, that I don't have a clue whether I should check "armeabi" or "armeabi-v7a" or both on the Application

Re: [mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-16 Thread subsembly
Hi, this is the output: >adb shell getprop ro.product.cpu.abi armeabi-v7a >adb shell getprop ro.product.cpu.abi2 armeabi So, to be on the save side, I now have both checks, armeabi and armeabi-v7a, ticked in my Application settings. I am still investigating the orginal WebClient problems and

Re: [mono-android] Unexpected Exception from System.Net.WebClient result

2012-01-17 Thread subsembly
Thanks a lot. After installing the 4.0.3 beta update and checking both armabi target platforms all other problems did disappear. So the wrong thread for the WebClient events is the last thing that remains. Cheers, Andreas -- View this message in context: http://mono-for-android.1047100.n5.nabb