Click here to Skip to main content
14,734,298 members

Comments by Banajyotsna (Top 39 by date)

Banajyotsna 27-Aug-11 2:17am View
   
i am giving one example

form1_load
{
SqlDataAdapter ad=new SqlDataAdapter("select *from reg",con);
DataSet ds=new DataSet();
ad.Fill(ds,"reg");
comboBox1.DataSource=ds.Tables["reg"].DefaultView;
comboBox1.DisplayMember="name";
comboBox1.ValueMember="name";
}
private void comboBox1_SelectedIndexChanged()
{
SqlDataAdapter addd=new sqldataadapter("select *from reg where name='"+comboBox1.SelectedValue.ToString()+"'",con);
DataSet dss=new DataSet();
ad.fill(dss,"reg");
if(dss.Tables["reg"].Rows.Count>0)
{
textBox1.Text=dss.Tables["reg"].Rows[0]["telno"].ToString();
}
else
{
textBox1.Text="";
}
}
it is working finely try it.
Banajyotsna 10-Jul-11 5:22am View
   
sir it is not running
Banajyotsna 8-Jul-11 2:42am View
   
Sir where i have to write this coding?can you give that coding briefly?
Banajyotsna 13-Jun-11 8:50am View
   
can you help me some more
Banajyotsna 13-Jun-11 8:50am View
   
thanks a lot.I just change that field as image.after every problem solved.but sir when i want to retrieve all those .mp3 file it should display the mp3 image(music image).how is it possible?and also i want to filtrate because it is accepting .doc,.image also?what is the coding for this?
Banajyotsna 7-Jun-11 6:16am View
   
i voted you and accepted this ans also.
Banajyotsna 7-Jun-11 6:03am View
   
Thanks a lot sir.It is running perfectly now.Sir is this concept possible in window based application?Can you tell me this concept in window based application?Please sir
Banajyotsna 7-Jun-11 6:03am View
   
Thanks a lot sir.It is running perfectly now.
Banajyotsna 6-Jun-11 6:52am View
   
here my visual studio is not accepting the object of ListItem
Banajyotsna 6-Jun-11 6:51am View
   
foreach(ListItem 1stitem in CheckBoxList1.Items)
Sir problem is in this line.The ListItem is not coming automatically and also my visual studio is not accepting the object of ListItem.Showing error 1stitem.
Banajyotsna 6-Jun-11 6:50am View
   
foreach(ListItem 1stitem in CheckBoxList1.Items)
Sir problem is in this line.The ListItem is not coming automatically and also my visual studio is not accepting the object of ListItem.Showing error 1stitem.
Banajyotsna 9-Apr-11 2:32am View
   
yes sir it is working now.thanks a lot sir
Banajyotsna 9-Apr-11 2:32am View
   
thank you sir.It is working
Banajyotsna 8-Apr-11 6:15am View
   
can you describe briefly? where which coding i have to write in which button click?
Banajyotsna 8-Apr-11 4:10am View
   
Sir it is working now.But one how shall i make replay again again.means how shall i put that .wav file in for loop?How to loop that .wav file?
Banajyotsna 7-Apr-11 7:18am View
   
Sir it is not running in my visual studio 2008
Banajyotsna 7-Apr-11 6:40am View
   
Sir i want to retrieve the image from database without .ashx file.How is it possible?how shall i retrieve the image from database directly without .ashx file

I already succeed in that concept means using .ashx file .now i want how shall i retrieve those images without .ashx file?
Banajyotsna 6-Apr-11 10:16am View
   
But in my query filter contains the splitted words of sentence putted through the textbox.which is matching one by one words of that sentence and retrieving the datas.my question how it will retrieve the related data of word(i want to put Like keyword to match the latter of those splitted word).please try to understand my query.retrieve datas from database by matching latter of those splitted word.Ex-google search.I think it will succeed if we will use IN and LIKE sql commands in one SQLquery.But i do not know how to use in a single query
Banajyotsna 5-Apr-11 9:16am View
   
In the following coding how shall i use IN and Like in sqlcommand.My coding is:
private void btnSearch_Click(object sender, EventArgs e)
{
try
{
string commaDelimited = textBox1.Text;
string[] year = commaDelimited.Split(new char[] { });

/////////////////////////////////////////
//string[] r = { "TV", "Radio", "Coal" };
string filter = string.Empty;
foreach (string name in year)
{
if (filter.Length > 0)
{
filter += ",";
}
filter += string.Format("'{0}'", name);
}

SqlDataAdapter adp;
DataSet ds = new DataSet();
adp = new SqlDataAdapter("Select * from EMP_DET where FName IN (Like '%(" + filter + ")%')", con);
adp.Fill(ds, "EMP_DET");
dataGridView1.DataSource = ds.Tables[0].DefaultView;
}
catch
{ }
Banajyotsna 5-Apr-11 9:12am View
   
Sir i used Like and IN sql commands in coding given by your previous link.I added IN and Like in sql command but it is not succeed.My coding is:
private void btnSearch_Click(object sender, EventArgs e)
{
try
{
string commaDelimited = textBox1.Text;
string[] year = commaDelimited.Split(new char[] { });

/////////////////////////////////////////
//string[] r = { "TV", "Radio", "Coal" };
string filter = string.Empty;
foreach (string name in year)
{
if (filter.Length > 0)
{
filter += ",";
}
filter += string.Format("'{0}'", name);
}

SqlDataAdapter adp;
DataSet ds = new DataSet();
adp = new SqlDataAdapter("Select * from EMP_DET where FName IN (Like '%(" + filter + ")%')", con);
adp.Fill(ds, "EMP_DET");
dataGridView1.DataSource = ds.Tables[0].DefaultView;
}
catch
{ }
Banajyotsna 5-Apr-11 7:30am View
   
Yes i checked.My question in that coding is.if i will put one sentence in one textbox that all the words will check one by one like google search.and it will display all related datas in datagridview.
Banajyotsna 5-Apr-11 7:16am View
   
Sir in your example i want to put like this:- select * from CandidateDetails where FirstName in (like('%ra%')) .But it is not running.Can you rectify it ?
Banajyotsna 5-Apr-11 7:13am View
   
Sir i am asking How to use LIKE and IN sql command in one query?
Banajyotsna 5-Apr-11 7:12am View
   
Yes i am looking for same thing but this is not succeed .Try to solve my problem please
Banajyotsna 4-Apr-11 6:10am View
   
Sir it is not running.
Banajyotsna 4-Apr-11 4:10am View
   
guide me please
Banajyotsna 4-Apr-11 4:10am View
   
Sir i putted coding like this but it is showing error:Please be sure a sound file exists at the specified location.
My coding is:
protected void btnAlarm_Click(object sender, EventArgs e)
{
SoundPlayer pl = new SoundPlayer(@"D:\Ringtone\Teri_Mast_Mast(www.FunAtoZ.com).midi");
pl.Play();
}
Banajyotsna 4-Apr-11 3:41am View
   
Sir i do not have any idea about wave file and alarm system.Please sir help me
Banajyotsna 4-Apr-11 3:08am View
   
thanks a lot sir
Banajyotsna 4-Apr-11 3:04am View
   
In combobox having data.When i used your coding it is not retrieving the data from database.But when i changed comboBox1.SelectedValue.ToString() in your coding it is working fine.only little i changed.that is:comboBox1.SelectedValue.ToString();
Thanks for giving path to me.Thanks a lot.It is working fine now.
Banajyotsna 4-Apr-11 2:52am View
   
When i changed the index number to Rows[1] it is showing the error : There is no row at position 1.
Banajyotsna 4-Apr-11 2:51am View
   
when i used comboBox1.SelectedValue.ToString() then also it is showing same error.
Banajyotsna 4-Apr-11 2:50am View
   
It is showing same error only
Banajyotsna 30-Mar-11 6:37am View
   
Thanks a lot sir.Now it is working.
Banajyotsna 30-Mar-11 6:14am View
   
Thank you sir for giving suggestion.Now it is working.
Banajyotsna 28-Mar-11 8:13am View
   
Sir it is showing Cannot implicitly convert type 'string' to 'System.Windows.Controls.Image' error
Banajyotsna 28-Mar-11 8:09am View
   
Sir I tried.I got this error when i wrote image1.Source=a .Cannot implicitly convert type 'string' to 'System.Windows.Media.ImageSource'
Banajyotsna 9-Mar-11 7:11am View
   
Sir i tried this coding but i could not able to succeed.Can u give another method to solve this problem in window based?
Banajyotsna 9-Mar-11 7:11am View
   
Deleted
Sir i tried this coding but i could not able to succeed.Can u give another method for solve this problem in window based?