Hi, When i try to try to use the ExecuteScalar method, e.g. myValue = cmd.ExecuteScalar(), I get an error when the result is null. How can i avoid this? rgds, Nickson
Nickson
Posts
-
How to Check Null for records returned? -
Datagrid HeaderI also do not know how to do it from the datagrid cause the border settings is for the entire table. However, the repeater can do what you want but it means much more coding. rgds, Nickson
-
Printing the datareader contents directlyYou cannot write to a datareader. Use a dataadpater instead if DML statements are to be executed. rgds, Nickson
-
Using Dataset as temp tablesHi, I am thinking of using an untyped dataset as a temp table to work with in my program. It seems to be much faster than using a database temp table and furthermore and the data table can be created with whatever columns is required and is destroyed when it is no longer required. 1) Is my above concept true? Or what are pros and cons of each? 2) How do you actually update records into a dataset using the primary key conditions rather than specify the row number which is more likely to be unknown. thx in advance for any answers : ) rgds, Nickson
-
What's the opposite of Server.Map?You can create a virtual directory in your website through IIS. And then you can access your file using a URL. rgds, Nickson rgds, Nickson
-
Inserting Records into a Databinded DropdownHi, I have a dropdown list binded to a dataset. However, i will like to add in a few more list items at a particular position in the list. See below for my specific details : What i got listed in the dropdown with a dataset binded. Jan - Seminar A Mar - Seminar B Dec - Seminar C Feb - Workshop D What i wanted -- 2002 -- Jan - Seminar A Mar - Seminar B Dec - Seminar C -- 2003 -- Jan - Seminar F Feb - Workshop D rgds, Nickson
-
Merging Header Values In DatagridHmmm... still couldn't figure out how to do it? :confused: Now got another question instead? Can I add another header row to a datagrid. (see example below which is actually what i want to achieve) Jan Name 1st 2nd 3rd 4th --------------------- John 0 1 3 6 Mary 1 3 5 7 Should i use datagrid in the above case? Rlly need ur expert advise ;) rgds, Nickson
-
Merging Header Values In DatagridDoes anyone know if it is possible to merge 2 cells together to show as a single heading? The data should continue to show as 2 separate columns under the merge header. rgds, Nickson