Skip to content
View in the app

A better way to browse. Learn more.

MSFN

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.

Delphi: How do I get '&' character from a source?

Featured Replies

A process included in my application uses Results in a string, which sometimes needs to include the '&' symbol. I know replacing '_ ' with '&&' would get it, however is there a way to handle the string where it doesn't amperand the character?

This is really hard to explain... basically is there a method to safely detect '&' characters in a string and replace them with '&&', or prevent them from becoming amperanded at all?

An example of an unsuccessfull call would be:

Save a text file containing the contents '& ' as C:\test.txt

In Delphi place a memo and button on the form, Memo1 and Button1 respectively

Button1.click:

begin
Memo1.loadfromfile('C:\test.txt');
showmessage(Memo1.lines[0]);
end

Where it would show '_' in the showmessage.

Edited by BrainDrain

  • Author

Eech, I should have done a bit more trialing, replacing '&' with 'and' works (well enough)... it seems the character is handled as & until its painted on the form... :}

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

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.