i have been developing iphone apps for a while now. I just started on android and have about half of my app done.
My app calls the native datepicker which the user selects the date then on the selection of the date a particular image is show in the format 2010-3-24, same as android output.
I have used the date picker tutorial to get the datepicker working and displaying the selected text in textview.
What i need is to display the particular image that corresponds to the selected date. The images are local to the app. I have looked for tutorials that would possibly help me out but so far no such luck. It is a very simple problem, i am just new to the platform.
So you would take the Date that comes back from the DatePicker and do some sort of conditional statement to determine what image to display in an ImageView.
What exactly are you having trouble with? Are you having trouble with the conditional statement that would determine the image to use? If so you need to give us more information on how you want that to work.
Are you having trouble getting an image to display in an ImageView? If so show us what code you have tried and we can help you with that.
Related
enter image description here
Sorry for the language of that pics, it is korean.
I want to make a planner that can help me to be noticed my plan. As you can see the picture, it is a calender, and I can add some plan depend on a user. the korean meaning is my major of Uni. So it is just some schedule.
The problem is I don't have any idea how to make like that. The way to operate this app, I hope I can add my schedule on the specific dates like the pictures and, creat the interface like that. I can slide the planner and it leads the next dates. When the plan comes to me, it could notice me by sound.
I can't find the way how to code the function 'slide' and how change the months and dates automatically by sliding?
I have ever create an application like this picture for my job interview, you can use recyclerview to show the date as horizontal. Then you should create database to showing data by date selected. Then showing the data as vertical using recyclerview after selected date. This is really simple apps.. Below is picture i have
enter image description here
I am making an attendance app i want to highlight multiple dates where student is absent and also make calendar view not clickable.
only want to show calendar.
This question doesn't look, you have done any research.
However, you can use https://github.com/Applandeo/Material-Calendar-View
Pros:
Easily customizable. [I have used in 3-4 projects so far]
Fits in requirement like range picker, one-day selection (event based)
Lightweight library, few files/ less code. You can also strip off the unnecessary code of range picker and other if you want. As for me, the requirement was only One-day-picker
i want to highlight multiple dates where student is absent
You can create a list of object of EventDay which take the Calendar instance. You can pass it to the CalendarView. It will show the different event aka absentees in your case.
make calendar view not clickable
That's not the big deal, You can easily do that as CalendarView is a custom view itself.
This is my latest screenshot from one of my project. It work really well.
I want to develop an new android application , by i was wondering if there is some feature or a code availabale that allow me the folowing thing.
if you see the picture , you can understand what i want , i need some feature or component that can display the current date or any date , with a specific content (if you see the containter under the date) , i also need two buttons that could allow to go forward or backword , each time i change that date i get the correct date with the correct content.
any ideas , so i can figure out from where i can begin.
thanks.
You can use Toolbar widget and inflate your custom layout with Button,TextView,Button.
More info about Toolbar widet here
http://developer.android.com/reference/android/support/v7/widget/Toolbar.html
I am sure,I think my question is something different in android.I goggled 100s of sites i saw the date picker in android, all are same type, no one give the different date picker.
My Task is to design custom date picker. Please find this below screen shot.
https://docs.google.com/file/d/0B_c-SDSO63obZzVreHpmdnZBYzg/edit?usp=sharing
For that I goggled, I didn't find any solution. I think, For android solutions this is the best site.
coming to my date picker it is totally dialog box. In that red symbol,name,close mark,submit i can do it. But i want that sun,man,tue,web In red color and on the top month and year. In below dates with green color picker. so Please tell me how can I do that task.
All advices are accepted.
Thanks&Regards
Shankar
Clite
I can only suggest how I would have gone for such a calendar. By the UI it is clear that it has to come as a pop-up or to better say a dialog. Now you have to google the opensource calendars if any or just using the calendar API provided by java you can get the calendar for a month year etc. and move it across previous month by normal java function calls.
Now that you have got the data to populate in your calendar. You have to design a custom layout xml create ~30-40 boxes or a grid with dynamic textviews or a webview with <table>, <tr>, <td> the choice is completely yours.
AFAIK
If you can't find anything opensource then I would suggest you should do these things by the suggested approach.
I have a range say,1-100 and i want the user to select a value from this range.Ofcourse showing this with a spinner will be awful.I want to use the functionality of date widget,where we can pick a date by pressing a +/- sign,the longer the press ,higher the iteration speed.
I found numberpicker.java that has the code the date widget uses to get this functionality, but do i have to paste that entire code to achieve this functionality!
Here is a tutorial on how to pull out NumberPicker; I've followed it myself: http://www.quietlycoding.com/?p=5
I found numberpicker.java that has the
code the date widget uses to get this
functionality, but do i have to paste
that entire code to achieve this
functionality!
Unfortunately, yes, plus perhaps some resources as well (I have not looked at that code recently). I am not aware of anyone who has pulled that out to make a reusable component, and it is not a widget in the SDK.
Sorry!