Home
Get Started
Learn
Downloads
AJAX
MVC
Community
Wiki
Forums
Sign in
|
Join
Home
›
ASP.NET Forums
›
Search
Search
You searched for the word(s): userid:776860
More Search Options
RSS Available
Matching Posts
GridView Columns width: How to set those to get a well formatted view
hi all, I am having a bounded GridView, there are 6 to 7 columns which shows a tables's records. Many of them columns have field with 50 to 70 words. But when GridView get bound it seems odd because if not fix width of columns. how to set them to get a better organizes view. And What shouls we do if we are having 300 words text in a Label Control to get a beeter view(organized like a paragraph) OR we should use another control to shows large value of text featching from database. can ypu please
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/24/2009
there is no row in table but it shows, How it can possible
hi all, there is no row in my database table. this is my code string StrSql = "select Sum(Sub_ContractAmt)As Total from mtblSub_Contract where Budget_Line=@Line"; SqlCommand com = new SqlCommand(StrSql, con); com.Parameters.Add("@Line", SqlDbType.NVarChar, 50).Value = ddlBudgetLine.SelectedItem.Text; SqlDataAdapter da = new SqlDataAdapter(com); DataTable dt = new DataTable(); da.Fill(dt); if (dt.Rows.Count > 0) { txtSubContract.Text = dt.Rows[0]["Total"].ToString
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/23/2009
Re: there is no row in table but it shows, How it can possible
hi yogi I tried to ur updated code but it still shows error ExecuteScalar requires an open and available Connection. The connection's current state is closed. thanks
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/23/2009
Re: there is no row in table but it shows, How it can possible
Thanks you both NathiyaR and sreejukg . your code is working fine But yogi's code shows error on line string str = com.ExecuteScalar(); Cannot implicitly convert type 'object' to 'string'. An explicit conversion exists (are you missing a cast?) thanks a lot
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/23/2009
Re: there is no row in table but it shows, How it can possible
Thanks Yogesh, now it's working fine thanks
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/23/2009
Re: which is better method to close the Sql Connection
so you dont need to open a connection before retrieving values from database table. ..??? so if you are using parameters some where you need Sqlcommand object. like string StrSql = "select * from mtblContract_New where flag=@flag"; SqlCommand com = new SqlCommand(StrSql, con ); com.Parameters.Add("@flag",SqlDbType,int).Value='1'; SqlDataAdapter da = new SqlDataAdapter(com); DataTable dt = new DataTable(); da.Fill(dt); if (!IsPostBack) { ddlCostCode.DataSource = dt; ddlCostCode
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/22/2009
Re: which is better method to close the Sql Connection
thanks Mikesdotnetting so can I go in same way for com.ExecuteNonQuery() while inserting, updating and deleteing thanks
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/22/2009
Autopost back cteates problem with webform
Hi all, There are many controls on my webform, like dropdownlists, calendars....so on every time if I make calendar visible on my button click and select a date from it, and On calendar1_SelectionChanged property I hide this calendar. my form goes back to top, it feel vert irritating.. any solution for it. I dont want to use javascript calendar . thnaks..
Posted to
Web Forms
(Forum)
by
demoninside9
on 12/22/2009
Re: Autopost back cteates problem with webform
Thank you Imarn and Venkatu it's working88888..
Posted to
Web Forms
(Forum)
by
demoninside9
on 12/22/2009
Re: which is better method to close the Sql Connection
Thanks you Mikesdotnetting, Now I came to under stand. Just last question to remove my confusion. for every updation , delete or insert I need to define three blocks on same page. for insert using (SqlConnection conn1 = new SqlConnection(Connectionstring)) { SqlCommand cmd = new SqlCommand (qry1, conn1) ; conn.Open(); cmd.ExecuteNonQuery(); } for updation using (SqlConnection conn2 = new SqlConnection(Connectionstring)) { SqlCommand cmd = new SqlCommand (qry2, conn2) ; conn.Open(); cmd.ExecuteNonQuery
Posted to
Data Presentation Controls
(Forum)
by
demoninside9
on 12/22/2009
Page 1 of 74 (736 items) 1
2
3
4
5
Next >
...
Last »
ASP.NET:
jQuery Hide/Close Link
ASP.NET:
Merry Christmas
TechNet Edge:
FPE Customer Story
Silverlight:
Being a writer, and having an editor. A Short Rant.
Channel 9:
Channel 9 Live at PDC09: Dr Brian Brooks (3M)
Channel 9:
C9 Lectures: Dr. Erik Meijer - Functional Programming Fundamentals Chapter 13 of 13
Silverlight:
Information for Silverlight HVP Developers…
WindowsClient:
Custom Content Loaders in Silverlight 4.0
WindowsClient:
MVVM Links\Info
TechNet Edge:
Check out how Dolly Parton uses IE8 and Web slices!!!
Silverlight:
A Silverlight HVP Update
Channel 9:
Channel 9 Live at PDC09: This Week on Channel 9 - PDC09 Daily Show Edition Day 1
Channel 9:
Maria Klawe: Scholar, Scientist and Microsoft Board Member
Channel 10:
Play the Bing Sherlock Holmes Game
Channel 9:
Channel 9 Live at PDC09: Loic Le Meur
Channel 10:
How to Delete Jump List Items
Channel 10:
Roll Back to Classic Network Indicator in Win7
Channel 9:
Jafar Husain: Silverlight Toolkit and Rx, Part 2
Channel 9:
Ping 42: Is Microsoft cool? Photo DNA, Win7 tool, 10k MIX contest
Channel 9:
Jafar Husain: Silverlight Toolkit and Rx, Part 1
Microsoft Communities
ASP.NET
Channel 8
Channel 9
Channel 10
IIS.NET
Silverlight
TechNet Edge
WindowsClient
Mix Online