I am trying to figure out a way to change the culture attribute of items being loaded thru the RadInputManager.
I'm using the methods I've found on the site to build the RadInputManager when a page is loaded.
I use the Page_Init to add settings:
protected void Page_Init(object sender, EventArgs e){ NumericTextBoxSetting numericSetting = new NumericTextBoxSetting(); numericSetting.Validation.IsRequired = false; numericSetting.BehaviorID = "numeric"; numericSetting.InitializeOnClient = true; RadInputManager1.InputSettings.Add(numericSetting); NumericTextBoxSetting _currencySetting = new NumericTextBoxSetting(); _currencySetting.BehaviorID = "currency"; _currencySetting.DecimalDigits = 2; _currencySetting.Type = NumericType.Currency; _currencySetting.Validation.IsRequired = false; _currencySetting.InitializeOnClient = true; RadInputManager1.InputSettings.Add(_currencySetting);}
And apply it like:
TextBox _txtTotal = (TextBox)e.Item.FindControl("txtTotal");
RadInputManager1.InputSettings[1].TargetControls.Add(new TargetInput(_txtTotal.UniqueID, true));
This works like a charm. I want to change the culture of the rendered controls based on selections that the user places on the screen. I can't do it on the Page_Init, however, because the data is not available at the time.
Is there a way to change the culture after I've used the Page_Init to build the controls?