Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Send Mail not working

Featured Replies

ok i have this script. it loops through a portal (relationship is based on a date) and send an e-mail for each record in the relationship. the script did not run thursday and friday (this is not the problem, just that we had the days off) well when i went to go back and run it to catch up. it runs the records for friday just fine. It does not send the e-mail for the records on thursday, it does do everything else in the script though. here is the script

If[ NumofPortalRows = 0 ]

Exit Script

End If

Set Field [ gPortalNumber, 1 ]

Loop

If[ PatternCount(hold,Orders_???:Order ID Number) < 1 ]

Go to Portal Row[ gPortalNumber ] [ By Field Value..., Select entire contents ]

Set Field [ hold, hold &Orders_???:Order ID Number& "" ] <- this step is performed

Go to Portal Row[ gPortalNumber ] [ By Field Value..., Select entire contents ]

Send Mail [ To:...] [ No dialog ] <-this step is NOT performed

End If

Exit Loop If[ gPortalNumber = NumofPortalRows ]

Set Field [ gPortalNumber, gPortalNumber + 1 ]

Go to Portal Row[ gPortalNumber ][ By Field Value..., Select entire contents ]

End Loop

Set Field [ gPortalNumber, 0 ]

Perform Script [ "remove double space" ][ Sub-scripts ]

If[ NumofPortalRows <> numoflines ]

Perform Script [ "loop email " ][ Sub-scripts ]

End If

Exit Record/Request

its wierd, at first i thought something was wrong with my if statement. but it performs one of the steps in my if statement, but not the other. I even tried unchecking the "perform without dialog" check box on the mail script, but it doesnt pop up the e-mail at all. its like it just skips that script step. Anyone have any advice as to what the problem may be?

[ November 26, 2001: Message edited by: bman ]

  • Author

UPDATE:

I have tried it on another computer, same exact problem. I can't figure out what is different about the records for that date.

one thing i did forget to mention is i get a error saying that there is not enought memory to perform the operation. but just on the ones from that date, all other dates work fine. and the error doesn't occur everytime. maybe 1 out of every 3 or 4 times i try to run it. this is wierd.

quote:

Originally posted by bman:

If[ NumofPortalRows = 0 ]

Exit Script

End If

Set Field [ gPortalNumber, 1 ]

Loop

If[ PatternCount(hold,Orders_
???
??? Order ID Number) < 1 ]

Go to Portal Row[ gPortalNumber ] [ By Field Value..., Select entire contents ]

Set Field [ hold, hold &Orders_: : Order ID Number& "" ]
<- this step is performed

Go to Portal Row[ gPortalNumber ] [ By Field Value..., Select entire contents ]

Send Mail [ To:...] [ No dialog ]
<-this step is NOT performed

End If

Exit Loop If[ gPortalNumber = NumofPortalRows ]

Set Field [ gPortalNumber, gPortalNumber + 1 ]

Go to Portal Row[ gPortalNumber ][ By Field Value..., Select entire contents ]

End Loop

Set Field [ gPortalNumber, 0 ]

Perform Script [ "remove double space" ][ Sub-scripts ]

If[ NumofPortalRows <> numoflines ]

Perform Script [ "loop email " ][ Sub-scripts ]

End If

Exit Record/Request

This is an incomplete answer, but I think you could simplify your loop by using the following:

Go to Portal Row [First]

Loop

Set Field [Hold]=Hold & "<paragraph symbol>" & Orders_: : Order ID Number

.

. <--whatever else you want to have happen to/with each row

.

Go to Portal Row [Next, Exit After Last]

End Loop

I'd also recommend taking out the [no dialog] in your Send Mail step (or any other script step) until you are sure the script works. Otherwise you're never quite sure what's going on in the background.

[ November 26, 2001: Message edited by: The Bridge ]

  • Author

i originally had the loop setup that way. unfortunately it caused more problems then it solved. I forget exactly what problems i had with it, but this is the solution that worked.

anyway, i have narrowed it down to one record. it sends the mail for every record in the relationship but one. and there is nothing drastically different about this record than any other. So the script works fine. it just won't send mail for that one record.

quote:

Originally posted by bman:

i originally had the loop setup that way. unfortunately it caused more problems then it solved. I forget exactly what problems i had with it, but this is the solution that worked.

Fair enough -- I can't say I haven't done what it takes to get something to work the way I want it. smile.gif" border="0

quote:

anyway, i have narrowed it down to one record. it sends the mail for every record in the relationship but one. and there is nothing drastically different about this record than any other. So the script works fine. it just won't send mail for that one record.

The only thing I can think of here is to double-check the actual data in that record. Perhaps there's a value mistyped, the date is in the wrong format... just a thought.

  • Author

i am checking on the data now. What really bugs me, is that it doesnt even try to send the mail. It doesn't even bring up the e-mail when i uncheck "perform without dialog."

It seems to only be happening if i set the "to:" field or the "cc:" field in the e-mail to be set by a field. if i just type in some to use it works fine.. but just for this record. i thought for a minute that it was because this person somehow enter up with a carriage return after her name and i was trying to pull that into the "CC:" field. But even after eradicating the carriage return it still does not function.

  • Author

Problem Solved....

It was being caused becuase her name in the database was different than her name on the e-mail server. so it could not find her.

thanks for your help.

Rick

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.