web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested answer

Special Characters in BC

(0) ShareShare
ReportReport
Posted on by 275

Hey,

What special characters can not be used in BC?  i.e any of the following...!@#$%^&*()= in item creation, job creation etc. or in BC totality 

Thanks!

I have the same question (0)
  • Dev-Master Profile Picture
    65 on at
    RE: Special Characters in BC

    Yes thank you it worked for me. but i am getting exception if the product name is like this  DS-2CD2132F-IW(4MM).

    It give exception of

    The length of the string is 22, but it must be less than or equal to 20 characters. Value: @*DS-2CD2132F-IW(4MM)*

    How to solve this?

  • Suggested answer
    Nitin Verma Profile Picture
    21,666 Moderator on at
    RE: Special Characters in BC

    Hi,

    I have used only simple setfilter function only the catch is I have provided the values extracting from the function STRSUBSTNO with special characters in between of @* string*

    please check if it works for you 

  • Dev-Master Profile Picture
    65 on at
    RE: Special Characters in BC

    Hi thank you for your response.

    Can you please elaborate working of this filter. I am new in business central so i just know basic understanding of set filter function.

  • Suggested answer
    Nitin Verma Profile Picture
    21,666 Moderator on at
    RE: Special Characters in BC

    Hi,

    Try like this

    itemRec.SetFilter("No.", '%1',StrSubstNo('@*%1*', ProductName));

  • Dev-Master Profile Picture
    65 on at
    RE: Special Characters in BC

    Hi, I am going in a situation where i have product name with special character like 1001-B(101) .

    as i am already using the .filter function with filter criteria of ignore case 

    itemRec.SetFilter("No.", StrSubstNo('@%1*', ProductName));
    it gives error The filter "@(" is not valid for the No. field on the Item table. An error occured while interpreting the filter: Did not expect '('.
    when i apply this filter.
    itemRec.SetFilter("No.", StrSubstNo('*%1*', ProductName));
    and try to search with this filter it gives error "The filter "*(*" is not valid for the No. field on the Item table. An error occured while interpreting the filter: Did not expect '('.
    How can i apply both ignore case filter '@' and any special charter in the item name for product name searching like 1001-B(101).
  • Suggested answer
    YUN ZHU Profile Picture
    92,161 Super User 2025 Season 2 on at
    RE: Special Characters in BC

    Hi, there are not too many restrictions in BC. I recently discovered that you can even enter emoticons in the code field and text field.

    For example:

    pastedimage1631058251720v1.png

    pastedimage1631058262559v2.png

    But for system developers and administrators, I definitely don’t want to use these special characters.
    Hope the following link will help.

    How to prevent users from entering special characters inside an input field: https://yzhums.com/5734/

    Thanks.

    ZHU

  • Suggested answer
    JAngle Profile Picture
    117 on at

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Nimsara Jayathilaka. Profile Picture

Nimsara Jayathilaka. 3,885

#2
Rishabh Kanaskar Profile Picture

Rishabh Kanaskar 3,405

#3
Sumit Singh Profile Picture

Sumit Singh 2,837

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans