Comments (6)
Can we change min/max date properties run time ? I have 2 inline datepickers. I want to change the min/max property of second date picker based on value of first date picker. So I have added row.cellConfigAtConfigure code in formrowvaluechanged method. But its not working.
from xlform.
I ended up creating a pull request for this feature and a couple of other minor update here #74
from xlform.
@bhirt-bpl
You can set minimum date or maximum date like this.
row = [XLFormRowDescriptor formRowDescriptorWithTag:@"ends" rowType:XLFormRowDescriptorTypeTimeInline title:@"Ends"];
row.value = [NSDate dateWithTimeIntervalSinceNow:60*60*25];
[row.cellConfigAtConfigure setValue:[[NSDate date] dateBySubtractingYears:13] forKey:@"maximumDate"];
[row.cellConfigAtConfigure setValue:[[NSDate date] dateBySubtractingYears:20] forKey:@"minimumDate"];
from xlform.
Instead of using row.cellConfigAtConfigure...
I try to use the following, and it works.
[row.cellConfig setObject:minimumDate_you_want forKey:@"minimumDate"];
from xlform.
@brianfox201 did you have any success with that?? I am looking for the same thing.
from xlform.
NSDate *currentDate = [NSDate date];
NSDictionary *dict = @{
@"datePicker.maximumDate" : currentDate
};
[row.cellConfigAtConfigure addEntriesFromDictionary: dict];
try to use
from xlform.
Related Issues (20)
- Round corner
- Help Needed: How can I get the cell like Native iPhone Calendar's Add Event HOT 3
- CALayer bounds contains NaN: [0 nan; 320 291]
- [UIColor systemGray3Color] No known class method for selector 'systemGray3Color' HOT 3
- iOS 11 - Keyboard
- No navigation VC is not considered
- Crash: Inline date picker row following alert presentation. Attempted to scroll the table view to an out-of-bounds row
- Ability to change TextField Auto Capitalization
- Support for distribution via Swift Package Manager HOT 2
- UIDatePicker Style in iOS 14 HOT 4
- trailingSwipeActionsConfigurationForRowAtIndexPath never called
- Detected a case where constraints ambiguously suggest a height of zero for a table view cell's content view. HOT 2
- How to change the section header or change tableview style HOT 6
- How to wait the response and then update the value - need to refresh the data in time HOT 4
- Framework not found XLForm.framework
- Fields are overlapping and everything appears on first row when built from Xcode 13 and Later HOT 1
- Image adding in the form in obj C
- How to edit XLFormOptionsViewController tableviewstyle to UITableViewStyleInsetGrouped? HOT 1
- XLFormRowDescriptorTypeSelectorPickerView becomes active but no options available in iOS 17 Beta
- Not support Mac catalyst app
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xlform.