hi,
i am developing a web application in asp.net, i need to generate UserId and Password for different users. so the UserId is should be in their designation(like EIDPRO-0025,EIDMM-0025,EIDTL-0026).The EIDPRO,EIDMM,EIDTL is different users, I need the Numeric value (0025,0026,0026) should be increment. how to do this? Anyone give me solution for this
raajsj 0 Newbie Poster
Recommended Answers
Jump to PostSorry, I thought you were asking for guidance. If you have partially working code that would be helpful.
I do not have any pre-built code to share with you. Maybe some other member would be willing to design it, develop this code up for you and just turn it over.
Jump to PostTo split the string at the dash, with string str being the returned result ...
string s = str.Substring(str.IndexOf("-")+1, str.Length - (str.IndexOf("-")+1));
Jump to PostIs there an id field in the table? if so, your SP can do the below.
select * from TableName where Id = (select max(Id) from TableName)
All 10 Replies
JorgeM 958 Problem Solver Team Colleague Featured Poster
raajsj 0 Newbie Poster
JorgeM 958 Problem Solver Team Colleague Featured Poster
G_Waddell 131 Posting Whiz in Training
raajsj 0 Newbie Poster
BMXDad 23 Newbie Poster
raajsj 0 Newbie Poster
BMXDad 23 Newbie Poster
raajsj 0 Newbie Poster
raajsj 0 Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.