frubeng
07-20-2009, 08:55 AM
Hi all,
I am using
Workbooks("Winlose.xlsm").Sheets("toprint").Cells(counter + 7, 2) = Format(Workbooks("Winlose.xlsm").Sheets("names").Cells(q + 1, 9), "currency")
in a VBA script. However this displays this in the ($1.23) format for negative values, and I would want -$1.23
I cannot just change the format of the cell in the spreadsheet because I also have the line
Workbooks("Winlose.xlsm").Sheets("toprint").Cells(counter + 7, 2) = Format(Workbooks("Winlose.xlsm").Sheets("names").Cells(q + 1, 9) / 100, "percent")
in certain cases (ie, the cell is not always a currency figure).
How can i change that format?
Thanks.
I am using
Workbooks("Winlose.xlsm").Sheets("toprint").Cells(counter + 7, 2) = Format(Workbooks("Winlose.xlsm").Sheets("names").Cells(q + 1, 9), "currency")
in a VBA script. However this displays this in the ($1.23) format for negative values, and I would want -$1.23
I cannot just change the format of the cell in the spreadsheet because I also have the line
Workbooks("Winlose.xlsm").Sheets("toprint").Cells(counter + 7, 2) = Format(Workbooks("Winlose.xlsm").Sheets("names").Cells(q + 1, 9) / 100, "percent")
in certain cases (ie, the cell is not always a currency figure).
How can i change that format?
Thanks.