Hi,
I have c# Application running in my desktop(Windows XP) with Java web services and oracle DB . The Application includes a shipping screen which has a calendar window. When I run the application in my desktop it works fine.
Client uses the same application. We access it through CITRIX box(Windows Server 2008 SP1). When the application is launched at the client side, when click event is performed at the calendar, it shows the message "This product is not available for selected date" eventhough the product is available for delivery at the selected date. It occurs for all the products. But the same case works fine in windows XP.

Any idead?? Need help!!

Can you be so kind to put here the code failing? Is difficult to find error with only the message: some thing is not workinf fine. The error message you post says nothing to any developer.

Trying to help:
Did you checked the regional settings and language are all the same in both machines?
Did you provided mechanisms to convert numbers and dates to the invariant culture before accessing the database?

Hope this helps

I have c# Application running in my desktop(Windows XP) with Java web services and oracle DB . The Application includes a shipping screen which has a calendar window. When I run the application in my desktop it works fine.
Client uses the same application. We access it through CITRIX box(Windows Server 2008 SP1). When the application is launched at the client side, when click event is performed at the calendar, it shows the message "This product is not available for selected date" eventhough the product is available for delivery at the selected date. It occurs for all the products. But the same case works fine in windows XP.

Any idead?? Need help!!

You should definitely post the code that is the problem. It appears that your query is not returning records between the selected dates. I would debug the code in the click event to see why the dates are not returning the data you are expecting(you said there are products in those dates).

This is the code i used,
But if I select the date as 27th May, e.End.Date shows 6/27/2012, how does the daterangeeventargs works?

protected void monthCalendar1_DateSelected(object sender, DateRangeEventArgs e)
        {
            string atpScript = null;

            try
            {
               if (deliveryDateImpl.ToString() != "1/1/0001" && shippingMethodCodeImpl != null &&
                      shippingDateImpl.ToString() != "1/1/0001" && shippingMethodDescriptionImpl != null)
                {
                    //If date is changed in edit mode, this flag determines
                    //that the selected shipping methods have to be reset
                    isDateChanged = true;
                    this.panelDeliveryMethod.Controls.Clear();
                    isShipMethodSelected = false;

                }
                else
                {
                    //Date is not changed in edit mode.
                    isDateChanged = false;
                }
                if (e.End.Date > System.DateTime.Now.AddYears(1).Date)
                {
                    MessageBox.Show("Your selected date is a year ahead of current date");
                    //To display the default date date in the textbox
                }
                else
                {
                    if (currentMonth == e.End.Month)
                    {
                        if (shipDataCtrller.shipmentDataFactory.DefaultDeliveryDate.Date.ToShortDateString() != "1/1/0001")
                        {
                            if (!IsDateAvailable(e.End))
                            {
                                //MessageBox.Show("I am sorry this product is not available for this date. Let me see how soon we can have this for you.");
                                MessageBox.Show(UIHelperConfig.GetHolidayErrorMsg(), UIHelperConfig.GetErrorMessageCaption(), MessageBoxButtons.OK, MessageBoxIcon.Information);
                                tableLayoutPanelDelivery.Controls.Clear();
                            }
                            else
                            {
                                FormatSelectedDate(e.End.ToShortDateString());
                                isShipMethodSelected = false;
                                PopulateDefaultShippingMethods(e.End);
                                if (ApplicationCache.BrandName == "CCO" && ApplicationCache.OrderType == "BGS" &&
                                    CustomerDataFactory.SelectedCustomer != null &&
                                    CustomerDataFactory.SelectedCustomer.customerShipInfo != null)
                                {
                                    if (CustomerDataFactory.SelectedCustomer.customerShipInfo.Length > 0)
                                    {
                                        checkBoxCustomerShipInfo.Visible = true;
                                        checkBoxCustomerShipInfo.Checked = true;
                                        DisplayThirdPartyCarriers();
                                    }
                                }
                            }
                        }
                    }
                    else
                    {
                        if (shipDataCtrller.shipmentDataFactory.DefaultDeliveryDate.Date.ToShortDateString() != "1/1/0001")
                        {
                            GetStartAndEndDates(e.End);
                            RetrieveDelDate(startDate, endDate);
                            DisplayBoldedDates();
                            if (!IsDateAvailable(e.End))
                            {
                                MessageBox.Show("I am sorry this product is not available for this date. Let me see how soon we can have this for you.");
                                tableLayoutPanelDelivery.Controls.Clear();
                            }
                            else
                            {
                                //this.monthCalendar1.SetDate(shipDataCtrller.shipmentDataFactory.DefaultDeliveryDate);
                                isShipMethodSelected = false;
                                PopulateDefaultShippingMethods(e.End);

                                if (ApplicationCache.BrandName == "CCO" && ApplicationCache.OrderType == "BGS" &&
                                    CustomerDataFactory.SelectedCustomer != null &&
                                    CustomerDataFactory.SelectedCustomer.customerShipInfo != null)
                                {
                                    if (CustomerDataFactory.SelectedCustomer.customerShipInfo.Length > 0)
                                    {
                                        checkBoxCustomerShipInfo.Visible = true;
                                        checkBoxCustomerShipInfo.Checked = true;
                                        DisplayThirdPartyCarriers();
                                    }
                                }
                            }
                        }
                    }
                    //To display the selected date in the textbox
                    if (IsDateAvailable(this.monthCalendar1.SelectionEnd.Date))
                    {
                        FormatSelectedDate(this.monthCalendar1.SelectionEnd.Date.ToShortDateString());
                    }
                }
                //                if (atpScriptText.Contains(atpShipDate) && 
                if (atpShipDate != e.End.ToShortDateString() &&
                    IsDateAvailable(e.End))
                {
                    if (atpScriptText.IndexOf('/') != -1)
                    {
                        atpScript = atpScriptText.Remove(0, atpScriptText.IndexOf('/') - 2);
                        atpScript = atpScript.Remove(atpScript.IndexOf('.'), atpScript.Length - atpScript.IndexOf('.'));
                        atpScriptText = atpScriptText.Replace(atpScript.Trim(), e.End.ToShortDateString());
                    }
                    this.lblATPMessage.Text = atpScriptText;
                }
            }
            catch (UOCJWSException jws)
            {
                if (jws.ErrorType == "info")
                {
                    MessageBox.Show(UIHelperConfig.GetCCOErrorMessage(jws.ErrorCode),
                                "Search Result",
                                MessageBoxButtons.OK,
                                MessageBoxIcon.Information);
                }
                else
                {
                    frmMdi2.mdi2.LogException("ucCCONormalShipment", "monthCalendar1_DateSelected", jws.ErrorCode,
                                                jws.Message, jws.StackTrace + "\n" + jws.ErrorTrace, ExceptionType.WebServiceException);
                    MessageBox.Show(UIHelperConfig.GetCCOErrorMessage(jws.ErrorCode),
                                "Error Information",
                                MessageBoxButtons.OK,
                                MessageBoxIcon.Error);
                }
            }
            catch (Exception exc)
            {
                frmMdi2.mdi2.LogException("ucCCONormalShipment", "monthCalendar1_DateSelected", string.Empty,
                                                exc.Message, exc.StackTrace, ExceptionType.UIException);
            }
        }

Hi lolafuertes,

I compared the regional settings in Windows XP and Windows 7,
In windows XP
Short Date-5/23/2012
Long Date-Wednesday, May 23, 2012
In Windows 7
Short Date-MM/dd/yy(5/23/12)
Long Date-dddd, MMMM dd,YYYY(Wednesday, May 23, 2012)

It differs in short date. Is the date format can be changed by myself? I tried changing myself and launched the application but the same message occurs again.
Or, Is the date format is one time configuration during OS Installation?

This question has already been answered. Start a new discussion instead.