Missing Assembly Dependencies

I have been facing this error since I figured it out and resolved so I just want to highlight it, the error is that when you try to open a page under ASP.NET application you may get this error in a blank screen : File or assembly name , or one of its dependencies, was not found.
If you try to refresh the page you will get a completely different missing assembly name which may drive you crazy, as the names are alphanumeric and generated in random fashion, from the first sight you will find that these files are not included in your bin directory that's why you shouldn't be getting this error, however for ASP.NET apps, while the application is running some temp assembly files are compiled and cached to the Windows Temp directory, so the application will refer to these temp assembiles later, of course the Network Service user is the one responsible for executing your code, so the reason behind this reason is that Network Service user is not granted right permissions to modify the contents of the Temp folder which might be C:\Windows\Temp or C:\WinNT\Temp directories, so you just will need to give permission to the Netowrk Service to Modify the contents of the above mentioned directory.
Note : Network Service user is MachineName\ASPNET in windows 2000, also you may need to restart your IIS.

Getting PrimaryKeys & Their DataTypes

Use this Stored procedure to get all the PKs for all the tables at your database and their types as well, I excluded type 'sysType' as it's duplicated at sysColumns system table :

Create Proc GetPrimaryKeysTypes as

select table_name As [Table],column_name As PrimaryKey,T.name As DataType from INFORMATION_SCHEMA.KEY_COLUMN_USAGE P
INNER JOIN SysObjects O On P.Table_Name = O.Name
INNER JOIN SysColumns C On P.Column_name = C.Name
INNER join SysTypes T On C.xtype = T.xtype
where O.Id = C.Id and T.name <> 'sysname'
order by T.Name, P.Table_Name