Thanks for the tip. We were ultimately able to get it going with the format 
statement:

gbCharge = Format(oExcel.ActiveCell.Value, "###0.00")

Thanks to all for the advice!

Gary Hall
Director of Information Technology
Estes Park Medical Center
970-577-4443 (office)
970-744-9052 (cell)
970-577-4355 (fax)

From: [email protected] [mailto:[email protected]]
Sent: Tuesday, November 17, 2009 2:17 PM
To: [email protected]
Subject: [talkbws] Re: Decimal (currency) from spreadsheet to Meditech?

Greetings,

Excel probably has a way to get it to return exactly what you want –but I don’t 
know it ☺  I’d have suggest the format command:
Here are some examples to prove it will work regardless of the data returned by 
Excel.

mydata = "10000"
Debug.Print Format(mydata, "#.00")
mydata = "10.3"
Debug.Print Format(mydata, "#.00")

mydata = "10.34"
Debug.Print Format(mydata, "#.00")

Regards,
Thom

Thom C. Blackwell
Product Manager
Boston Software Systems
(866) 653-5105 ex 807
www.bossoft.com<http://www.bossoft.com/>

Sign up for my weekly 
webinar!<http://www.bostonworkstation.com/customer_center/special_events.aspx>

LEGAL NOTICE Unless expressly stated otherwise, this message is confidential 
and may be privileged. It is intended for the addressee(s) only. Access to this 
E-mail by anyone else is unauthorized. If you are not an addressee, any 
disclosure or copying of the contents of this E-mail or any action taken (or 
not taken) in reliance on it is unauthorized and may be unlawful. If you are 
not an addressee, please inform the sender immediately, then delete this 
message and empty from your trash.


From: [email protected] [mailto:[email protected]]
Sent: Tuesday, November 17, 2009 4:08 PM
To: Talk
Subject: [talkbws] Re: Decimal (currency) from spreadsheet to Meditech?

Well – that’s not one of my choices…I have cText (which doesn’t go anywhere)…

Gary Hall
Director of Information Technology
Estes Park Medical Center
970-577-4443 (office)
970-744-9052 (cell)
970-577-4355 (fax)

From: [email protected] [mailto:[email protected]]
Sent: Tuesday, November 17, 2009 1:51 PM
To: [email protected]
Subject: [talkbws] Re: Decimal (currency) from spreadsheet to Meditech?

Define variable as Text ?

Sean Hoover
Application Analyst
Gulfport Memorial Hospital
228-865-3010-office
__________________________________________________________________________
Confidentiality Notice: This e-mail message, including any attachments, is for 
the sole use of the intended recipient(s) and may contain confidential and 
privileged information. Any unauthorized review, use, disclosure or 
distribution is prohibited. If you are not the intended recipient, please 
contact the sender by reply e-mail and destroy all copies of the original 
message.

>>> <[email protected]> 11/17/2009 2:42 PM >>>
Got to be an easy one for you experts, but trying to move medication charges 
from a spreadsheet into a Meditech price field. All of them work OK – unless I 
have “zero zero” past the decimal point. Then it just scripts in the dollar 
amount, and not the decimal point and zero zero.

Here’s the relevant code I’m using. I’ve also defined the variable as Currency, 
but still no luck. Any ideas? Is it the “Value” that’s dropping the zeroes?:

    Global gbCharge As String

    Set oExcel = CreateObject("Excel.Application")
    Set oBook = 
oExcel.Workbooks.Open("J:\PHA\Bill-Codes-2009-11-16-zeroes-partial.xls")
    Set oSheet = oBook.Worksheets("Charges")
    oSheet.Activate
    oExcel.Visible = True
    intRow = 1

    strCell = "E" & intRow
    oSheet.range(strCell).Select
    gbCharge = Trim(oExcel.ActiveCell.Value)

Gary Hall
Director of Information Technology
Estes Park Medical Center
970-577-4443 (office)
970-744-9052 (cell)
970-577-4355 (fax)
---
To post a message to this list, send mail to: [email protected]

You are currently subscribed as: [email protected]

Unsubscribe in the customer center on our website: 
http://www.bostonworkstation.com/customer_center/virtual_user_group_talk.aspx
---
To post a message to this list, send mail to: [email protected]

You are currently subscribed as: [email protected]

Unsubscribe in the customer center on our website: 
http://www.bostonworkstation.com/customer_center/virtual_user_group_talk.aspx
Nh֦zh+-ݙZF­&b.\&u-$en,\e'rz).&z‑׫z.+^i0,,bw(.&z‑׫楺ǫ.֥)
Nh֦z˚먶+-静ZF貊­ʦb箮\&޵ ezuǧꜢe'欲z)텧.ڦz‑׫z.+^۩0z,&#142956;bw(��&z‑׫楺ǫ.֥)
N�h�֦z���h���+-��ݙ����Z�F�����&b����.����\����&�u���b�隊V�r�y�&R{.n�+�����^r�-�g�q��z�'���y�"��m����
��h�
+��Z�*'r��r�-�g�q��z�nj[�z�+��mjY��

Reply via email to