Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


Take one textbox if I am inputting abc alphabet in capital
letter or in small letter on the button click it will be
bcd or if I enter 123 and it would be 234 like that in
ASP.NET?

Answers were Sorted based on User's Feedback



Take one textbox if I am inputting abc alphabet in capital letter or in small letter on the button..

Answer / nitin kumar nitin@bbspl.com

string str;
str = text4.Text;
string one, two,three;
string four;
char dd;

one = str.Substring(1,2);
three = str.Substring(2, 1);

two = one;
four = three;
dd=char.Parse(four);

int con = Convert.ToInt32(((int)dd).ToString());
string str1 = char.ConvertFromUtf32(con+1);
text5.Text = two + str1;

Is This Answer Correct ?    11 Yes 2 No

Take one textbox if I am inputting abc alphabet in capital letter or in small letter on the button..

Answer / sagnikmukh

i am posting the basic logic,

class Program
{
static void Main(string[] args)
{
string test = "123";
StringBuilder st=new StringBuilder ();
int l;
l = test.Length;
for (int i = l; i > 0; i--)
{
st = st.Append(test.Substring(i - 1,
1).ToString ());
}
Console.WriteLine(st.ToString ());
Console.Read();
}
}

this will be the Button event in ASP.NEt Page.

Is This Answer Correct ?    2 Yes 0 No

Take one textbox if I am inputting abc alphabet in capital letter or in small letter on the button..

Answer / sharumathi

protected void Button1_Click(object sender, EventArgs e)
{
string str = TextBox1.Text;
byte[] a = System.Text.Encoding.ASCII.GetBytes(str);
byte[] b = { a[1], a[2], (++a[2]) };
string x = System.Text.Encoding.ASCII.GetString(b);
TextBox2.Text = x;
}

Is This Answer Correct ?    0 Yes 0 No

Post New Answer



More ASP.NET Interview Questions

What is the difference between Server.Transfer and Response.Redirect?

5 Answers  


Which authentication uses a combination of windows and iis authentication?

0 Answers  


What is session id in web application?

0 Answers  


Project Architecture (3tier, n-tier)

1 Answers   Syntel,


What is CTS, CLS and CLR ?

20 Answers   CGI, Palm Technology, Reliable Technology, Satyam, Synergy, TCS,






What are validator? Name the validation controls in asp.net? How do you disable them?

0 Answers  


how to encrypt a connection string in web.config file?

3 Answers   Hexaware,


What are different methods of session maintenance in asp.net?

0 Answers  


How can you display all validation messages in one control?

0 Answers  


What is the main function of razor in asp.net? : asp.net mvc

0 Answers  


Contrast oop and soa. What are tenets of each16. How does the xmlserializer work? What acl permissions does a process using it require?

0 Answers  


8. Why do you want to work here?

0 Answers   Global Achievers, Swatz Oils,






Categories