Userform with currency format

M

Mia

Hi,

I cant get the userform to show arspremie in the right format.
I want to show it in currency, do anyone know how to do this?

My code are:

Private Sub UserForm_Activate()
Application.OnTime Now + _
TimeValue("00:00:05"), "KillTheForm"
Dim namn As String
Dim antal As String
Dim arspremie As Currency

namn = Application.UserName
Label2 = namn


antal = Sheets("Uppföljning").Range("S4")
Label4 = antal & " st"

arspremie = Sheets("Uppföljning").Range("L3")
Label5 = arspremie
Format (arspremie, "Currency")

End Sub
 
H

Homey

Label5 = Format(arspremie, "Currency")

you have to format variable before you use it.

| Hi,
|
| I cant get the userform to show arspremie in the right format.
| I want to show it in currency, do anyone know how to do this?
|
| My code are:
|
| Private Sub UserForm_Activate()
| Application.OnTime Now + _
| TimeValue("00:00:05"), "KillTheForm"
| Dim namn As String
| Dim antal As String
| Dim arspremie As Currency
|
| namn = Application.UserName
| Label2 = namn
|
|
| antal = Sheets("Uppföljning").Range("S4")
| Label4 = antal & " st"
|
| arspremie = Sheets("Uppföljning").Range("L3")
| Label5 = arspremie
| Format (arspremie, "Currency")
|
| End Sub
|
|
|
| --
| Best regards
| Mia
 
G

Gokhan Erdem

arspremie.value = Sheets("Uppf??ljning").Range("L3")
Label5.Caption = Format (arspremie, "? #,##0.00")

Cheers



Mia wrote:

Hi,Thank you for your help but it doesen't work.--Best regardsMia"Homey" skrev:
20-Jan-10

Hi

Thank you for your help but it doesen't work

-
Best regard
Mi

"Homey" skrev:

Previous Posts In This Thread:

Userform with currency format
Hi

I cant get the userform to show arspremie in the right format
I want to show it in currency, do anyone know how to do this

My code are

Private Sub UserForm_Activate(
Application.OnTime Now +
TimeValue("00:00:05"), "KillTheForm
Dim namn As Strin
Dim antal As Strin
Dim arspremie As Currenc

namn = Application.UserNam
Label2 = nam

antal = Sheets("Uppf??ljning").Range("S4"
Label4 = antal & " st

arspremie = Sheets("Uppf??ljning").Range("L3"
Label5 = arspremi
Format (arspremie, "Currency"

End Su


-
Best regard
Mia

Label5 = Format(arspremie, "Currency")you have to format variable before you
Label5 = Format(arspremie, "Currency"

you have to format variable before you use it

| Hi

| I cant get the userform to show arspremie in the right format
| I want to show it in currency, do anyone know how to do this

| My code are

| Private Sub UserForm_Activate(
| Application.OnTime Now +
| TimeValue("00:00:05"), "KillTheForm
| Dim namn As Strin
| Dim antal As Strin
| Dim arspremie As Currenc

| namn = Application.UserNam
| Label2 = nam


| antal = Sheets("Uppf??ljning").Range("S4"
| Label4 = antal & " st

| arspremie = Sheets("Uppf??ljning").Range("L3"
| Label5 = arspremi
| Format (arspremie, "Currency"

| End Su



| -
| Best regard
| Mia

Hi,Thank you for your help but it doesen't work.--Best regardsMia"Homey" skrev:
Hi

Thank you for your help but it doesen't work

-
Best regard
Mi

"Homey" skrev:


Submitted via EggHeadCafe - Software Developer Portal of Choice
More Fun with Fluent NHibernate Automapping
http://www.eggheadcafe.com/tutorial...9-81ee42171b00/more-fun-with-fluent-nhib.aspx
 
J

JLGWhiz

arspremie = Format(Sheets("Uppf??ljning").Range("L3"),"Currency")
Label5.Text = arspremie

Or instead of "Currency" use "$###,##0.00" wotj cirremcy sympbol of choice,
of course. Possibly Kr?
 
J

JLGWhiz

Should be:
Label5.Caption = arspremie



JLGWhiz said:
arspremie = Format(Sheets("Uppf??ljning").Range("L3"),"Currency")
Label5.Text = arspremie

Or instead of "Currency" use "$###,##0.00" wotj cirremcy sympbol of
choice, of course. Possibly Kr?
 

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