Whitespace

Hi,

I'm new to fs4, I have a Tfrxmemoview liked to a dataset and dataview called First_Name and one Tfrxmemoview called Last_Name.
The problem comes when both expressions are combined, how to eliminate the white space between the expressions
I keep getting
Welcome Jim                   Smith                    many .......


instead of
Welcome Jim Smith and

Hope someone can help

Thanks in advance

Comments

  • Anu de DeusAnu de Deus Hampshire, UK
    edited 9:47PM
    In your memoview.text, where you have something like '[<dataset.field1>]', merge the contents of your memoview objects in one:
    'Dear [<dataset.field1>] and [<dataset.field2>]'
  • edited September 2010
    Thanks for the prompt reply

    Sorry tried that but still not working
    I have combined the two fields as expression
    [<Customer."First_Name">+<Customer."Last_Name">]
    

    The whitespace allways appears. Can i set field widths dynamically from code as in sql, see code below
    SELECT RTRIM(First_Name),RTRIM(Last_Name) FROM Client_Record WHERE Client_No = :Client_No
    

    I can then add
    form2.ClientLabel.Caption.Text:=FirstName+''+LastName;
    

    No whitespace
  • gordkgordk St.Catherines On. Canada.
    edited 9:47PM

    Anu was correct, it is the fact that your white space is coming from your data that you need to wrap the fields with appropriate functions.
    first when using multiple fields in 1 memoview don't link the memoview to a data set or field
    just use an expression.
    The expression may be built using the expression builder
    ie select memoview rclick and enter edit mode
    select the expression button and the expression builder dialog appears
    select the desired function in the expression box place the cursor between the ()
    then go back and select the datafield click on okand the correct text will be added to the memo.
    ie
    [Trim(<Customer."Firstname">)] [Trim(<Customer."LastName">)]
  • edited 9:47PM
    Thanks for the prompt reply from you guys, worked a treat.

    I had been trying to use Trim, but in the wrong place.

    Thanks, best service ever.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.