Welcome to DU! The truly grassroots left-of-center political community where regular people, not algorithms, drive the discussions and set the standards. Join the community: Create a free account Support DU (and get rid of ads!): Become a Star Member Latest Breaking News Editorials & Other Articles General Discussion The DU Lounge All Forums Issue Forums Culture Forums Alliance Forums Region Forums Support Forums Help & Search

SirRevolutionary

(579 posts)
7. Ha! The programmer who can't remove smileys from the code
Tue Dec 20, 2011, 09:50 PM
Dec 2011

That one baffled me, so I gave up

I'm not new to Java, but fairly new to Android and this is a different sample than that StackFlow one, this one was a lot easier. I mostly use PHP and Java on Apache, so I'd be really rusty on C# and IIS. Plus I'm set up on Mac now so I don't have the Visual Studio IDE set up anymore, but there's tons of simple samples out there. Things are definitely different for IIS, permissions to upload files to folders are probably handled much differently.

If you want to do it the right way, I'm sure you'd want to create a simple web service if it's just for your Android app to upload images http://www.c-sharpcorner.com/UploadFile/scottlysle/UploadwithCSharpWS05032007121259PM/UploadwithCSharpWS.aspx I can't speak for that example since I'm so rusty with .NET and IIS. But that's the route I'd take.

Just remember the post variable name in the Android code is called 'ufile'. So whatever .NET expects, you'll probably need to match the names.

If you want, send me a PM with an email address and I'll email you the plain text for the Activity Java class for Android and the PHP upload script so there's no smiley emoticons. There's no security or anything for the PHP script, it's just quick and dirty, takes a file and saves it somewhere, nothing fancy.

Recommendations

0 members have recommended this reply (displayed in chronological order):

Latest Discussions»Retired Forums»Website, DB, & Software Developers»Android code instructions...»Reply #7