Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Performing search using altered value list


This topic is 7369 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Currently there is a drop down list with each month range in it.

EX: 1/1...2/1

2/1...3/1

And so on.

This is used for searching for patients whose baby due date is in that month. HOWEVER, the year stays as the current year when the search is done.

What I'm looking at is taking the 1/1...2/1 and adding the appropriate year to it and putting that in the EDD field and doing the search on that.

So if it is October and 1/1...2/1 is selected in the drop down list, the date in the EDD box is 1/1/2005...2/1/2005.

Any suggestions will be appreciated. Basically I'm not sure how to get the data selected, I think after that I can dynamically create the string to go in the EDD field.

Posted

How about Insert Cacluated Result [EDD, DateToText(Date( LeftWords( range, 1 ), MiddleWords( range, 2, 1), Year(Status(CurrentDate)) + (Month(Status(CurrentDate)) > TextToNum(LeftWords( range, 1 ))) )) & "..." &

DateToText(Date( Substitute( MiddleWords( range, 3, 1 ), ".", "" ), MiddleWords( range, 4, 1), Year(Status(CurrentDate)) + (Month(Status(CurrentDate)) > TextToNum(LeftWords( range, 1 ))) ))]?

Posted

That is a start for sure. I think I will have to make a new field that has like NEXT YEAR in it then do an IF the current month is greater than the requested month NEXT YEAR is added on other wise use current year.

Posted

That's what the + (Month(Status(CurrentDate)) > TextToNum(LeftWords( range, 1 ))) portion does.

This topic is 7369 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.