ihere3010,
Error 'data type mismatch' comes from comparing data items that are not the same type, typically comparing a numeric to a string, but it can also be comparing dates to non-dates etc... The compares can happen in a Where string, but also in a JOIN because JOINS are something like WHERE clauses in disguise. So if you try to join table Personal to table Payed2 on the field 'payroll' in both tables, and payroll is numeric in one table and not numeric in the other table, you'll get that type of error.
So I'm going to guess that either
payed2.page is not the same data type as payed1.page (payed2.page = payed1.page in JOIN)
or
payed2.payroll is not the same data type as personal.payroll (payed2.payroll = personal.payroll in Inner Join)
or
payed2.payroll is not a string (payed2.payroll = '" & mpayroll & "' in WHERE clause, the quotes indicate you're comparing strings)
or
payed2.Page = " & mpage & "" ... OOPS what's that, looks like an extra " at the end of your Where clause
Looks like you were going for a numeric compare.
payed2.Page = " & mpage looks like a numeric compare because there's no ' before you concatenate the mpage variable
We don't know your table/column definitions so we can only guess what you meant. Pay close attention to column data types.
Jim