i have shifted my application from mssql server 2000 to mssql server 2005 , now the prob is the command object is not returning the recordset if command text is stored procedure , here is my code please check it and guide me through errors .
dim cmdsp as command dim rs as new ADODB.recordset set cmdsp = new commadn cmdsp.activeconnection = cn cmdsp.commandtext = "MyStoredProcedure" cmdsp.commandtype = adcmdstoredproc set rs= cmdsp.execute 'here i got an error the state of rs is zero , but if i used this code at mssql server 2000 then it will return the records.
please help me in this , and if you have some better code then please also post it here, i have even tried this also
rs.open "exec myprocedurename",myCon,adOpenStatic,AdLockReadOnly
but this code is also not working at my end ,please check it out as i need help very urgently ,