c# - SQLDatasource parameters problem -


why if use following instruction in code behind:

sqldatasource1.selectparameters["page"].defaultvalue = "0"; 

i 'system.nullreferenceexception: object reference not set instance of object.

'?

the 2 objects involves in single statement (bold)

sqldatasource1.selectparameters["page"].defaultvalue

sqldatasource1.selectparameters["page"].defaultvalue

so 1 of them must null. when looking @ previous question, because have not yet added "page" parameter sqldatasource1.


Comments

Popular posts from this blog

delphi - TJvHidDeviceController "DevicePath" always showing "\" -

web applications - Making Python scripts work on MAMP -

cocoa - Converting NSString to keyCode+modifiers for AXUIElementPostKeyboardEvent -