hi,
using ultraCalendarInfo's BeforeDisplayAppointmentDialog, I have a code written to show my own custom appointment dialog box. Before I show that dialog box however, I want to check if the slot double clicked (in the ultradayview) is within the correct range in which appointment is allowed to be made. For us its from 930am to 6pm . If its before 930am or after 6pm, I want to prevent showing the appointment dialog box. Plz suggest what should I do.
thanks!
..ab
Hi,
Maybe one possible solution could be if you are using AfterTimeSlotSelectionChanged event. By this way you could get the time slots. For example :
private void ultraDayView1_AfterTimeSlotSelectionChanged(object sender, EventArgs e)
{
ultraDayView1.SelectedTimeSlotRange.StartDateTime;
ultraDayView1.SelectedTimeSlotRange.EndDateTime;
}
Let me now if you have any questions.
You could specify Start / End times through your calndarInfo for each day of week. See attached screenshot.
Let me know if you have any questions.
for me this is working fine:
Dim withinworkinghours As Boolean = m_ownerfrompoint.IsInWorkingHours(m_timeslotfrompoint, m_datetimefrompoint)
if withinworkinghours is true then I show the appointment dialog box, else i dont.
thanks.
What about this question ?
jangroup said:What I'm really looking for is the start time of the working hours, which I said is 930 in my case. Which properties will help me get the current working hour start time that is shown in the dayview control?
I wanted to know the start and end time of the clicked dayview because I wanted to compare it to the start and end times of the currently selected timeslot, so I can make a decision to show or not to show the appointments dialog box (based on whether timeslot is within the working hour range).
the "m_ownerfrompoint.IsInWorkingHours" provided this same info without me having to explicitly compare the individual datetimes. So that did the job.
Now I have to control the dragging and resizing of the appointments. I have to prevent any appointment from resizing beyond working hours, or being dragged beyond the working hours. For this purpose I again am in a need to know the start and end of the current owner's current day's start and end time. The image that you posted above which helps me getting the start and end times through DayOfWeek (of calenderinfo) property does give me some values, but are they owner specific or not? Because its possible that one owner's start time for Monday is different from another owner's start time for same Monday. please suggest.
Thanks.
Hello jangroup
jangroup said:... but are they owner specific or not? Because its possible that one owner's start time for Monday is different from another owner's start time for same Monday. please suggest
They are not owner specific. At that moment we have not such functionality. You can suggest new product ideas for future versions (or vote for existing ones) at <http://ideas.infragistics.com>.
There are many benefits to submitting an product idea:
- Direct communication with our product management team regarding your product idea.- Notifications whenever new information regarding your idea becomes available.- Ability to vote on your favorite product ideas to let us know which ones are the most important to you. You will have ten votes for this and can change which ideas you are voting for at any time.- Allow you to shape the future of our products by requesting new controls and products altogether.- You and other developers can discuss existing product ideas with members of our Product Management team.
Steps to create your idea: 1. Log into the Infragistics Product Idea site at http://ideas.infragistics.com (creating a new login if needed).2. Navigate to the product / platform channel of your choice (e.g. WPF, Windows Forms, ASP.NET, HTML5 / Ignite UI, iOS / NucliOS, etc.)3. Add your product idea and be sure to be specific and provide as much detail as possible. Explain the context in which a feature would be used, why it is needed, why it can’t be accomplished today, and who would benefit from it. You can even add screenshots to build a stronger case. Remember that for your suggestion to be successful, you need other members of the community to vote for it. Be convincing!
The Product Idea site puts you in the driver’s seat and allows you to track the progress of your ideas at any time, see how many votes it got, read comments from other developers in the community, and see if someone from the product team has additional questions for you.