fbugeja Posted March 31, 2005 Posted March 31, 2005 To simplify enttry of dates into a Date field on a search screen, I am toying with the idea of buttons on a layout which have "Today","Yesterday", "Last 7 Days", Last 14 days", etc which, when clicked, go to another layout (a search layout) and set the date in the Date field. I am using the SetField Command, so to show dates from the last 7 days I have: SetField[File:Date;">"&Get(CurrentDate)-7] Problem: Can the SetField command be made to show a date range e.g. 1.1.2005...3.1.2005? Frank
aaa Posted March 31, 2005 Posted March 31, 2005 Instead "Set field" comand in that case you must put "Insert calc result" comand. But you must have date field in the layout where you want to search your range.
Ender Posted March 31, 2005 Posted March 31, 2005 aaa, in FM7, you can use Set Field[] instead of Insert Calculated Result[] to insert a range for a find. Frank, I'm not sure what you're asking. Yes, you can use Set Field to insert a range in that format. Did you have trouble with that?
fbugeja Posted March 31, 2005 Author Posted March 31, 2005 Ender For single dates (e.g. today, yesterday) and SetField example that I included in my first post worked. I think the problem lies in the way that I write the range. I need to do some experimentation e.g "1.1.2005"&"2.3.2005". Will keep you posted on my experimentation! Frank
Ender Posted March 31, 2005 Posted March 31, 2005 Try: Set Field [ File::Date ; Date(1;1;2005) & "..." & Date(2;3;2005) ]
fbugeja Posted April 1, 2005 Author Posted April 1, 2005 Thanks Ender - your solution was spot on! Frank
Recommended Posts
This topic is 7176 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now