Click here to Skip to main content
15,886,026 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: image in ASP.Net Pin
myinstincts31-Aug-09 1:30
myinstincts31-Aug-09 1:30 
AnswerRe: image in ASP.Net Pin
mylogics31-Aug-09 1:30
professionalmylogics31-Aug-09 1:30 
GeneralRe: image in ASP.Net Pin
Amit Patel198531-Aug-09 2:17
Amit Patel198531-Aug-09 2:17 
GeneralRe: image in ASP.Net Pin
sashidhar31-Aug-09 2:25
sashidhar31-Aug-09 2:25 
GeneralRe: image in ASP.Net Pin
Abhijit Jana31-Aug-09 2:49
professionalAbhijit Jana31-Aug-09 2:49 
GeneralRe: image in ASP.Net Pin
Amit Patel198531-Aug-09 3:38
Amit Patel198531-Aug-09 3:38 
Questionaccess Pin
mylogics31-Aug-09 0:46
professionalmylogics31-Aug-09 0:46 
AnswerRe: access Pin
Coding C#31-Aug-09 3:33
Coding C#31-Aug-09 3:33 
mylogics wrote:
PID:Autonumber



mylogics wrote:
string str1 = "Select MAX(PID) From Product";
OleDbCommand cmd = new OleDbCommand(str1, conn);
OleDbDataReader dr = null;
conn.Open();
string max = cmd.ExecuteScalar().ToString();
if (max != "")
{
max = "PID" + max;

}
else
{
max = "PID" + 1;
}



You have set the PID:Autonumber in database?

If yes then no need to include it in insert/update query. It will be automatically created by database.
Just include the other fields in insert/update query except PID.

HTH

Coding C#

ExciteTemplate

GeneralRe: access Pin
mylogics31-Aug-09 21:02
professionalmylogics31-Aug-09 21:02 
QuestionSecurity Exception in ASP.net Pin
Leezo8730-Aug-09 23:18
Leezo8730-Aug-09 23:18 
AnswerRe: Security Exception in ASP.net Pin
Aman Bhullar31-Aug-09 0:40
Aman Bhullar31-Aug-09 0:40 
QuestionRole & membership Pin
KhandelwalA30-Aug-09 23:02
KhandelwalA30-Aug-09 23:02 
AnswerRe: Role & membership Pin
sashidhar30-Aug-09 23:31
sashidhar30-Aug-09 23:31 
QuestionHow to read web.config file from a different site? Pin
pubududilena30-Aug-09 22:18
pubududilena30-Aug-09 22:18 
AnswerRe: How to read web.config file from a different site? Pin
Abhishek Sur30-Aug-09 22:58
professionalAbhishek Sur30-Aug-09 22:58 
GeneralRe: How to read web.config file from a different site? Pin
Gaurav Dudeja India31-Aug-09 0:03
Gaurav Dudeja India31-Aug-09 0:03 
GeneralRe: How to read web.config file from a different site? Pin
Abhishek Sur31-Aug-09 23:17
professionalAbhishek Sur31-Aug-09 23:17 
Questiondate problem [modified] Pin
venu65630-Aug-09 22:03
venu65630-Aug-09 22:03 
AnswerRe: date problem Pin
dan!sh 30-Aug-09 22:16
professional dan!sh 30-Aug-09 22:16 
GeneralRe: date problem Pin
venu65630-Aug-09 22:24
venu65630-Aug-09 22:24 
GeneralRe: date problem Pin
dan!sh 30-Aug-09 22:26
professional dan!sh 30-Aug-09 22:26 
GeneralRe: date problem Pin
venu65630-Aug-09 22:32
venu65630-Aug-09 22:32 
AnswerRe: date problem Pin
Abhishek Sur30-Aug-09 22:56
professionalAbhishek Sur30-Aug-09 22:56 
GeneralRe: date problem Pin
venu65630-Aug-09 23:07
venu65630-Aug-09 23:07 
GeneralRe: date problem Pin
Abhishek Sur30-Aug-09 23:47
professionalAbhishek Sur30-Aug-09 23:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.