Change format to fields...

J

Jorge Martínez

Hello to all!... How I can change the format to a text field, I need for example to convert two format classes, one with comas (of 12366,22 at 12.366,22) and another to percentage (of 12.33 to 12.33%).

Tanks in advance!...

Jorge
 
R

Rod Gill

Hi,

You need to use the Format command. Read about it in VBA help.

--

Rod Gill
Project MVP

Project VBA Book, for details visit:
http://www.projectvbabook.com

NEW!! Web based VBA training course delivered by me. For details visit:
http://projectservertraining.com/learning/index.aspx


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


Hello to all!... How I can change the format to a text field, I need for example to convert two format classes, one with comas (of 12366,22 at 12.366,22) and another to percentage (of 12.33 to 12.33%).

Tanks in advance!...

Jorge
 
J

John

Jorge Martínez said:
Hello to all!... How I can change the format to a text field, I need for
example to convert two format classes, one with comas (of 12366,22 at
12.366,22) and another to percentage (of 12.33 to 12.33%).

Tanks in advance!...

Jorge

Jorge,
I don't understand your first format "class" at all (12366,22 at
12.366,22). Maybe its just a format I'm not familiar with.

As far as the second example goes, use the format function
Text1=Format([your field]/100,"#.00%").

John
Project MVP
 
J

Jorge Martínez

Hi Jhon!, Thank you to answer me! (the same as Mr.Gill)...

Ok, the situation that I need to change the format to a number that has
single comas decimals and to add him point to separate thousands to show it:

12.123,85

and not

12123,85

(represent decimal coma and unit of thousands point).

I imagine that the format is similar to the percentage format.

The idea it's not use VBA.



thank you again friend!...


John said:
Jorge Martínez said:
Hello to all!... How I can change the format to a text field, I need for
example to convert two format classes, one with comas (of 12366,22 at
12.366,22) and another to percentage (of 12.33 to 12.33%).

Tanks in advance!...

Jorge

Jorge,
I don't understand your first format "class" at all (12366,22 at
12.366,22). Maybe its just a format I'm not familiar with.

As far as the second example goes, use the format function
Text1=Format([your field]/100,"#.00%").

John
Project MVP
 
R

Rod Gill

Ah well, you posted in a VBA news group, so you got some VBA answers!! :)

Project usually reflects the values in the regional settings page in the
Windows Control Panel. Check those first. However, a Text fields does not
have formatting: it's straight text so the only way to get what you want is
to use the Format function in either VBA or a formula. The Regional settings
should apply to date and number fields.

--

Rod Gill
Project MVP

Project VBA Book, for details visit:
http://www.projectvbabook.com

NEW!! Web based VBA training course delivered by me. For details visit:
http://projectservertraining.com/learning/index.aspx


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


Jorge Martínez said:
Hi Jhon!, Thank you to answer me! (the same as Mr.Gill)...

Ok, the situation that I need to change the format to a number that has
single comas decimals and to add him point to separate thousands to show
it:

12.123,85

and not

12123,85

(represent decimal coma and unit of thousands point).

I imagine that the format is similar to the percentage format.

The idea it's not use VBA.



thank you again friend!...


John said:
Jorge Martínez said:
Hello to all!... How I can change the format to a text field, I need for
example to convert two format classes, one with comas (of 12366,22 at
12.366,22) and another to percentage (of 12.33 to 12.33%).

Tanks in advance!...

Jorge

Jorge,
I don't understand your first format "class" at all (12366,22 at
12.366,22). Maybe its just a format I'm not familiar with.

As far as the second example goes, use the format function
Text1=Format([your field]/100,"#.00%").

John
Project MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top