sorry I am having trouble responding to post. This is the code I have so far.
USE AP
Declare @MyRowCount int
SELECT Top 1 name
FROM sys.tables
WHERE name not like 'dtproperties' and name not like 'sysdiagrams'
order by name asc
SET @MyRowCount = @@ROWCOUNT
;