Jump to content
Server Maintenance This Week. ×

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

Recommended Posts

Hi everyone. I was wondering if you could help me . I have a database of service certificates and i wanted to create a script that would run when the admin logs in. Ive started it and it does what i want to a fashion (ive not added the admin part yet) but ive hit a problem and i cant figure out how to get around it.

The problem i have is that its not taking into consideration that a new service has been done . Its picking up the old retest date not the latest one for that customer. i need to find ONLY the ones that havent been re-serviced yet.   Im doing a find on the retest date 30 days before the certificate runs out so that i can organise the service to be done . 

Any ideas?

 

Thanks

 

 

 

 

Screen Shot 2017-04-07 at 05.30.06.png

Edited by baweld123
wrong file
Link to comment
Share on other sites

Note that your script is not readable. The screen shot is cropped so your Let statement is incomplete.

Better to print the script to PDF and post that. Or post the file. Or find some other way to actually reveal the complete script.

Link to comment
Share on other sites

ha ha as you can see im pretty useless at scripts. This is a make up of stuff i found by searching . I try and walk through manually what i want the script to do then try and replicate it in the script. what you are seeing here though (as i sent it quick while working ) was me trying lots of stuff .

okay i have a customer layout and attached to this is service.

The customer layout is the main hub for the database. 

I wanted to create a layout pop up that would automatically search for services that are due in 30 days time ( so that office staff could then call them and organise re-service).

I want this new popup layout to Omit those that have already been re-serviced though. I only want it too show whats outstanding in that week window. 

This would then be a creeping barrage of jobs week by week. I also wanted to then make buttons so that you could search month and quarter for a bigger picture. 

My ultimate would be then to put these services into areas of the country ( but thats for later)

I have fields for  ServiceDate ReTestDate, CreationDate.

 

too explain the above ( which is brilliant by the way :-)) 

Th set field (service::Retest Date) script part i got from another post and it seems to work in finding those dates in that week window. 

New record request i was guessing as i thought i  needed to do a new search. 

Thinking about the creation timestamp your right now i see the problem with that.

Multiple i was again guessing 

The if get found count again that was on a post.

Thanks bruce for looking at it and i hope im making sense now. 

Link to comment
Share on other sites

Quote

New record request i was guessing as i thought i  needed to do a new search. 

But that would you you to first enter find mode; which you did not do.

So you're in a new record.

Link to comment
Share on other sites

hi Bruce , just too let you know i think ive sorted it . Ive created an Active/Inactive field  and included or omitted this in the search criteria. I looked at the script more closely after what you explained and understood more of the steps i was asking it to do. I now have a script that i can either select 7 ,30,60 day windows of only ACTIVE files .

Thanks for the pointers

 

Link to comment
Share on other sites

This topic is 2571 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.