Rabu, 25 Mei 2011

RE: [MS_AccessPros] Format Font for Memo TextBox

 

It run now, I did the same thing in query with calculated field like the formula, but you are right calculated field in query will be plain text not rich text. Thanks

Best Regards,

Son

--- On Wed, 25/5/11, John Viescas <john@viescas.com> wrote:

From: John Viescas <john@viescas.com>
Subject: RE: [MS_AccessPros] Format Font for Memo TextBox
To: MS_Access_Professionals@yahoogroups.com
Date: Wednesday, 25 May, 2011, 9:43 AM

 

Son-

Apparently, you cannot concatenate a Memo / Rich Text field with anything in a query. The result is a plain text field that then displays all the embedded formatting characters, and the Text Format property isn't available in a query. But I did find a workaround on a form.

In Northwind 2007, there's an Employees table with a Notes memo field. In some of the fields, I added some italic and underline formatting to force it to add the formatting strings. In a text box on the Employee Details form, I was able to create a text box set to Rich Text and use this expression to add the Last Name to the front of the string:

=IIf(Left([Notes],5)="<div>","<div>" & [Last Name] & " " & Mid([Notes],6),[Last Name] & " " & [Notes])

If Notes has formatting in it (the text starts with <div>), I add a <div> in front of Last Name, a space, and then strip out the <div> in the front of the Notes field. If no formatting, then I just concatenate the two fields. It seems to display correctly without jumping to a new line.

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

http://www.viescas.com/

(Paris, France)

-----Original Message-----

From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Watson L

Sent: Wednesday, May 25, 2011 11:08 AM

To: MS_Access_Professionals@yahoogroups.com

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

Actually, The name data type is string and Memo data type is memo. I have tried to change the name data type to memo, but still the same, the name in first line and memo in second line. The example of the raw data like this : John has competence in access programming. I save "John" in Name field name (different table with memo) and "has competence in access programming" in memo field name. I have 4 criteria to describe the competence of the students, so I create a table with name field name to save student name and another table with memo data type to save the competence. And the software will choose the competence base on the result of the student. So I make a relationship between the two tables and create calculated field to combine the two fields from different table. Please assist me... thanks

Best Regards,

Son

--- On Wed, 25/5/11, John Viescas <john@viescas.com> wrote:

From: John Viescas <john@viescas.com>

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

To: MS_Access_Professionals@yahoogroups.com

Date: Wednesday, 25 May, 2011, 6:23 AM

Son-

Are both Name and Memo the Memo data type? Do you have them both set to display as Rich Text? I don't think you can concatenate two fields this way. What is the raw data in both fields?

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

http://www.viescas.com/

(Paris, France)

-----Original Message-----

From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Watson L

Sent: Wednesday, May 25, 2011 8:09 AM

To: MS_Access_Professionals@yahoogroups.com

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

Thanks for your response. Finally, I use Access 2007 and it run. But, when I try to combine two field from different table in a query, use calculated field and the formula like this : Comment:[Name] & ' ' & [Memo], the memo display in second line, I mean after name always space to line 2. Actually, I want the field display name following by memo that have italic style. In the table, the data like this : "name <div> memo </div>". Please assist me... thanks

Best regards,

Son

--- On Mon, 23/5/11, John Viescas <john@viescas.com> wrote:

From: John Viescas <john@viescas.com>

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

To: MS_Access_Professionals@yahoogroups.com

Date: Monday, 23 May, 2011, 6:16 PM

Son-

That's a problem. Neither Access XP (2002) nor 2003 support the Microsoft Rich Text Control (6.0), so you'll have to find a 3rd-party solution to be able to display "formatted" text stored in a table text or memo field. You'll have to follow the conventions of tht control to find out how to indicate italic vs regular text.

Access 2007 and 2010 let you define a Text Format property for Memo fields. When you set that property to Rich Text, you can easily define italics within the text stored in the field. If you define a part of a Rich Text memo field in Access 2007 and later as italic, the embedded codes are: <em> </em>

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

http://www.viescas.com/

(Paris, France)

-----Original Message-----

From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Watson L

Sent: Monday, May 23, 2011 8:41 AM

To: MS_Access_Professionals@yahoogroups.com

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

Microsoft Access XP/2003

--- On Mon, 23/5/11, John Viescas <john@viescas.com> wrote:

From: John Viescas <john@viescas.com>

Subject: RE: [MS_AccessPros] Format Font for Memo TextBox

To: MS_Access_Professionals@yahoogroups.com

Date: Monday, 23 May, 2011, 6:25 AM

Son-

Which version of Access are you using?

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

http://www.viescas.com/

(Paris, France)

-----Original Message-----

From: MS_Access_Professionals@yahoogroups.com

[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Watson L

Sent: Monday, May 23, 2011 7:20 AM

To: MS_Access_Professionals@yahoogroups.com

Subject: [MS_AccessPros] Format Font for Memo TextBox

Dear all,

I have a problem when the report that will be printed need foreign language to

print in italic format and mother language still in normal format in memo field.

Anyone know what is the tag for italic format in memo textbox ? please assist

me.. thx

Best regards,

Son

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

[Non-text portions of this message have been removed]

__._,_.___
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar