I am using Silverlight + MVVM to host a form with some fields like drop down list, text boxes and date controls.
I have some validations on the textbox and date control which fire automatically when the control loses focus.
I wanted to know if there is a way to reset the validations based on the drop down list change (captured in View Model)?
Related
IS this possible to have check boxes in crm 2015 page (not through web resource) , I tried to implement couples of solution with js but did not work out. Any comments would be useful.
You can add checkboxes by creating fields of type two options. Then, add them to an entity form and in the field properties window, change the format to "checkbox".
Check this out: https://www.microsoft.com/en-US/dynamics/crm-customer-center/create-or-edit-entity-fields.aspx
Possible data types for a field
Two options
After creating this field, configure it in the form to which it was added. In the form, select whether the field is displayed as option buttons (also known as radio buttons), a check box, or a list.
Cheers.
In the Dynamics CRM entity form editor:
Click New Field button on the extreme down-right corner
Provide Name to the field
Set data type as Two options
Save the record
Drag this newly added field into the form from the right side field list
Click Change Properties in the menu bar
In the pop-up click the Formatting tab
Select Two radio buttons / Check box / List in the Control formatting section
Click OK
In my application i use an AutoCompleteBox, on tap of the AutoCompleteBox i fetch the data from the server and populate the itemsource. While typing it displays the dropdown based on the text input. I would like the dropdown to be displayed without me having to input any text. Any inputs on this?
I am trying to design a page that has two radio button options and two text boxes with each radio button. I am validating these text boxes using data annotation validation attribute.
I am using jquery slider.toggle() to display each text boxes according to the radio button clicked. When i submit the page, required field validators of both text boxes are triggered. What I want to do is to disable the first text box validation when the second radio button is clicked.
Is there any method in MVC to disable the validation of text boxes when the radio button associated to it is not selected?
This can be done rather simply front end. The validation which occurs is done based on html5's data attribute. Remove the data attributes from an input element and the validation will cease to function.
I Have three records which I want to display in three Accordion Panes
which (every pane) will have a Header and a content ( Two label controls, 1 text box and 1 checkbox and 1 link button)
I am able to display data on the accrodion from database but when I am trying to Update the text in textbox by clicking link button the LINKBUTTON doesnot fire and unabel to make the update. How can we create Update event working ??
I am creating the Accordion Panes and Content controls statically and directly assigning the values to the controls from Code behind in Page Load.
I was able to do it using the "ItemCommand" event of the Accordion Panel by using the Command Name property of a Link Button which will update the Text Boxes.
It works for me now but I felt JQUERY will be a better option which has no postback, css issues..
When a user tries to click:
Save
and they have entered in some invalid data, i want to notify them. This can be with methods such as:
directing their attention to the thing that needs their attention with a balloon hint
automatically dropping down a combo-box
triggering an animation
showing a modal dialog box
etc
What is the mechanism where a controller tells the view to show a validation message for some controls, given that different views have different notification methods?
p.s. the controller doesn't know the order that controls are physically arranged in the view (e.g. LTR locale wants to notify the user in a top-down-left-to-right visual order, while RTL locale wants to notify the user in a bottom-up-right-to-left order)
The controller can add a Validation object to the Model, which can contain the names of the fields which were invalid, specific validation messages, etc.
The View can then choose to render this Validation object however it wishes: by highlighting the incorrect fields, animating something, showing a modal dialog, etc.
If you are using ASP.Net MVC 2.0, check out this post by Scott Gu, although some of this will apply for ASP.Net MVC 1.0 as well.