I have VBA code in Access 2010 that I am using to make a temporary table. The only problem is it rounds the dollar amount and I need it to show the whole number. In the code below how can I format the Amount field to show a dollar amount.
"
Public Sub ViewActionsAlreadyInMaster()
Dim strSQL As String
Dim rs1 As DAO.Recordset
strSQL = ""
strSQL = strSQL & "SELECT "
strSQL = strSQL & """"" AS [Bank Account] , "
strSQL = strSQL & "0 AS [Check Number], "
strSQL = strSQL & "0 as [Amount], "
strSQL = strSQL & "INTO TEMPViewActionsAlreadyInMaster "
DoCmd.RunSQL (strSQL)
Set rs1 = CurrentDb.OpenRecordset("tblDBIndex")
Do While Not rs1.EOF
strSQL = ""
strSQL = strSQL & "INSERT INTO TEMPViewActionsAlreadyInMaster "
strSQL = strSQL & "SELECT "
strSQL = strSQL & "[" & rs1("DBname") & " Master Issued Checks].[Bank Account], "
strSQL = strSQL & "[" & rs1("DBname") & " Master Issued Checks].[Check Number], "
strSQL = strSQL & "[" & rs1("DBname") & " Master Issued Checks].[Amount], "
strSQL = strSQL & "FROM tblDailyPaids, [" & rs1("DBname") & " Master Issued Checks] "
strSQL = strSQL & "WHERE "
strSQL = strSQL & "tblDailyPaids.[Check Number] = [" & rs1("DBname") & " Master Issued Checks].[Check Number] "
strSQL = strSQL & "AND tblDailyPaids.[Bank Account] = nz([" & rs1("DBname") & " Master Issued Checks].[Bank Account],0) "
strSQL = strSQL & "AND [" & rs1("DBname") & " Master Issued Checks].[ACTION] is not null; "
DoCmd.RunSQL (strSQL)
Debug.Print rs1("DBname")
rs1.MoveNext
Loop
DoCmd.RunSQL ("DELETE FROM TEMPViewActionsAlreadyInMaster WHERE [Action Date] = #1/1/1900#;")
DoCmd.OpenTable "TEMPViewActionsAlreadyInMaster", acViewNormal
End Sub"