Skip 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.

Set Next Serial Value script step question/problem

Featured Replies

I have a text field, "ID", that is set to auto-enter serial numbers in the format "pt00001" and increment by 1. It works great when adding new records. When adding new records the field increments by one in the format I specified. ie, pt00002, pt00003, etc. The problem I have is when using the Set Next Serial Value script step on this field. I use it in a script when certain conditions exist. I use a calculation like: ID + 1. So basically I am saying set the counter to the value of the ID field on the current record plus one.

The problem is that when I use the script step it returns a straight number without the formatting that I wanted. For example if the ID field on the current record has "pt00001" in it and I run that script step I get "2" instead of "pt00002".

Anyone no what can be done?

Adding only applies to numeric portions of a field. You have to add the text portion and leading zeroes to the calculation.

Set Next Serial Value [YourTable::ID; "pt" & Right( "0000" & YourTable::ID + 1; 5 )]

Or:

Set Next Serial Value [ YourTable::ID ; SerialIncrement ( YourTable::ID ; 1 ) ]

*******, I forgot about that function!

I trust you have typed those asterisks yourself - rather than using language not fit for mixed company!

Mixed or not, since when is d@mn a censored word?

:offtopic:

Not since when, but until when. According to Wikipedia:

Until around the mid-20th century ******* was a more offensive term than it is today,and was frequently represented as "D--n," "D---," or abbreviated to just "D." The use of "*******" in Rhett Butler's parting line to Scarlett O'Hara in the film Gone With the Wind in 1939 captivated moviegoers.

"*******" is commonly nowadays known as a very mildly profane word and used while cursing or swearing.

However, the Am.Heritage Dictionary lists the word with no marking as profane or even vulgar. And so does the Bible.

  • Author

Thanks comment! That did the trick!

Thanks for the etymology lesson, Comment, but I was referring to the forum software. :wink2:

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.