epos4u Posted September 19, 2014 Share Posted September 19, 2014 Hi, i am trying to load a memo field from DBisam to a UniDBGrid see pic attached in next post as i forgot to attach the memo is not inserting new line in epos and price field i want it to show BLT Salad ++ Oatcakes ++ Brown Toasty its showing BLT Salad ++ Oatcakes ++ Brown Toasty and the price to be 6.15 1.20 0.36 any help would be great as i am trying my best Thank you Quote Link to comment Share on other sites More sharing options...
epos4u Posted September 19, 2014 Author Share Posted September 19, 2014 forgot the pic lol Quote Link to comment Share on other sites More sharing options...
bugra Posted September 23, 2014 Share Posted September 23, 2014 Hi; You can use HTML code in uniGUİ. Try <br/> before +. You can try to add your db like "BLT Salad <br/> ++ Oatcakes <br/> ++ Brown Toasty" or you can try write a code which detecting some sentences and show them different. For example: procedure TMainForm.Table1SpeciesNoGetText(Sender: TField; var Text: string; DisplayText: Boolean); begin Text := stringReplace(Sender.AsText, '++', '<br />++', [rfReplaceAll]); end; Quote Link to comment Share on other sites More sharing options...
epos4u Posted September 23, 2014 Author Share Posted September 23, 2014 Hi; You can use HTML code in uniGUİ. Try <br/> before +. You can try to add your db like "BLT Salad <br/> ++ Oatcakes <br/> ++ Brown Toasty" or you can try write a code which detecting some sentences and show them different. For example: procedure TMainForm.Table1SpeciesNoGetText(Sender: TField; var Text: string; DisplayText: Boolean); begin Text := stringReplace(Sender.AsText, '++', '<br />++', [rfReplaceAll]); end; Thank you for your reply, will try something different, would be better if the dbgrid had word-wrap thank you Bugra Yener Sahinoglu Quote Link to comment Share on other sites More sharing options...
bugra Posted September 23, 2014 Share Posted September 23, 2014 I've changed the code. Try this one. Quote Link to comment Share on other sites More sharing options...
epos4u Posted September 23, 2014 Author Share Posted September 23, 2014 Hi, thank you for quick reply i was looking for #13 to replace, will try a different method, as with the price in a memo field like 12.90 12.10 3.50 will still show up as 12.90 12.10 3.50 Quote Link to comment Share on other sites More sharing options...
bugra Posted September 24, 2014 Share Posted September 24, 2014 When your program running it's not pascal anymore it's HTML. And in HTML there is no #13. That's why it's not change. Quote Link to comment Share on other sites More sharing options...
epos4u Posted September 24, 2014 Author Share Posted September 24, 2014 Thank you, will try this Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.