Who Viewed the Topic
I’m trying to create an interface that will find all entries in the month specified in the script parameter. If the user selects the Sep button, I want the script to query a date field for “2017-09-01…2017-09-30”. This works correctly when I do it manually, and a case statement correctly builds this string in the variable $_range. But when I try to script the query as follows:
Enter Find Mode [Pause: Off]
Set Field [Calendar::calDate; $_range]
Perform Find [ ]
it consistently throws a 500 error, even though I’ve set no validation restrictions.
Set Field [Calendar::calDate; “\” & $_range & \””] does not resolve the problem.
Can anyone troubleshoot this, or suggest an entirely better method?
Hi Guys, Just a quick question for a beginner, I have created multiple export scripts, and notice that when I create a master script with the numerous subscripts being called, sometimes the output isnt correct, whereas when I run each script one by one (rather than lots of subscripts within a master script) the final result is fine. Could there be anything wrong with using subscripts for this?
Should I always have an Exit Script step at the end of each subscript? I hope that makes sense
I am using EmailRecipients () , and we have noticed that sometimes duplicate emails are being sent. I had one customer who said they received 10!
any ideas? My script is:
Set Variable [ $result ; Value:EmailConnectSMTP("smtp.gmail.com:465";"info@**********.com";"*********";"ssl=1") ]
If [ $result ≠ 1 ]
Show Custom Dialog [ Message: EmailLastError & ¶ & "Feedback emails failed! Password most likely wrong. Tell Doc."; Default Button: “OK”, Commit: “Yes” ]
Go to Layout [ original layout ]
Exit Script [ ]
#send email to foundset
Go to Record/Request/Page [ First ]
Loop Set Variable [ $first ; Value:patients::first ]
Set Variable [ $email; Value:patients::email ]
Set Variable [ $subject; Value:$first & ", Happy Birthday from Colonial Family Eyecare!" ]
Set Variable [ $msgCreate ; Value:EmailCreate( "info@************.com";patients::email ;$subject ) and EmailSetBody( $$body)
Set Variable [ $setRecipients ; Value:EmailRecipients($email) ]
Set Variable [ $sent; Value:EmailSend ]
If [ $sent ≠ 1 ]
Show Custom Dialog [ Message: EmailLastError; Default Button: “OK”, Commit: “Yes” ; Button 2: “Cancel” , Commit: “No” ]
Go to Record/Request/Page [ Next; Exit after last ]
End Loop Set Variable [ $disconnect ; Value:EmailDisconnect ]
If [ $disconnect="ERROR" ]
Show Custom Dialog [ Message: EmailLastError; Default Button: “OK”, Commit: “Yes” ]
Exit Script [ ]
I have just downloaded the 360works Email plugin Sample and I am doing some tests to check whether this would solve my problem. I would like to be able to download all emails from my email account into "messages" table and then on each customer record show those emails which are related to that customer via a portal based on a relationship between, but what I can not figure out how to do it is that the portal would show but types of emails those marked as "from" emails and those marketd as "to" emails. So far I have created a relationship between Customers::email ------- Messages::From and the portal would show all "from" messages. If I would set the relationship as Customers:email ------ Messages:To, the portal shows all "to" messages, but what I am trying to make is a join portal that would show by date both "from" and "to" messages, then I plan to make a Conditional Formating saying that if Customers:email = Messages::From then all text in blue, and all text in green when it is TO.
Is this something that can be achieved?
Thanks a lot for any tip,
I have a database, which has two printable forms. One has been designed in portrait, and the other in landscape. Both of them are only ever printed using buttons tied to script steps, never manually. I was hoping that there would be some way to specify orientation via the script. However, after some poking around of my own and light Google searching I am thinking this may not be so easy.
I am able to go into Print setup to change the orientation just fine, however this sets it for the entire database which is not all around helpful. While specifying the options in the print step, I am able to change orientation. For some reason though, this changes the default orientation across the entire database. Not even while running the script, but just specifying it in the options of the script step. So now I'm at a loss.
If this is not able to be done, redesigning one of the forms wouldn't be that difficult. But if there's a way to do what I'm trying to do, any assistance would be greatly appreciated!