5,346 Posted Topics
Re: [b]>How can I get this to select just by order #? [/b] If your code uses DataTable then use Select() method or DataView to filter. Otherwise, you can simply put where clause with select statement in command object to fetch rows. | |
Re: [b]>All the fields that are being padded are nvarchar (not nchar), and are padded to their maximum length.[/b] Verify (code) the parameter type/size. | |
Re: [b]>there is no keypress event is there in asp.net texbox control [/b] That's true. There is no keypress event with ASP.NET controls but you can attach/add javascript code with ASP.NET controls. [code] <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <script type="text/javascript"> function doSomething() { var t1, t2; t1 = document.getElementById("TextBox1"); t2 = document.getElementById("TextBox2"); … | |
Re: Hi. We appreciate your help. Have you ever noticed that the current thread is six years old? Please do not resurrect old threads and have a look at forum [URL="http://www.daniweb.com/forums/faq.php?faq=daniweb_policies"]rules[/URL]. Please read before posting again - [url]http://www.daniweb.com/forums/thread78223.html[/url] Thread Closed. | |
Re: Google search [URL="http://code.google.com/p/google-api-for-dotnet/"]api.[/URL] | |
Re: Steps: 1. Add handler for button'c click event. 2. Inside that handler add code to connect with database. 3. Configure Command object by assigning select statement and a reference of connection object. | |
Re: [b]>click on a asp.net webpage link programmatically [/b] Use HttpWebRequest and it's methods. | |
Re: Correction : i [COLOR="Red"]<=[/COLOR] dtGrid.Rows.Count [code] for (i = 0; i < dtGrid.Rows.Count; i++) { DataGridViewRow row = dtGrid.Rows[i]; for (j = 0; j <row.Cells.Count; j++) { xApp.Cells[i + 1, j + 1] = row.Cells[j].ToString(); } } [/code] | |
Re: [b]>how to have default button in a content page.[/b] Wrap all the asp.net controls and buttons inside the Panel and set default button property of panel with the id of a button. [b]>currently if i hit enter ket my master page search getting fire.[/b] You need to add a panel … | |
Re: [b]>i just want to generate a html page. Do you undertand?????[/b] Yeh! Take a look at - [url]http://www.daniweb.com/forums/faq.php?faq=daniweb_policies[/url] | |
Re: Sorry, I'm not quite following the problem. My understanding from your description is that your have a problem with printing. Suggestion : You could use CrystalReport or MicrosoftReport services. | |
Re: Handle formClosing event instead of disposed. [code] Private Sub Form1_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing If MsgBox("Are you sure you want to exit?", MsgBoxStyle.Question + MsgBoxStyle.YesNo, "Exit") = MsgBoxResult.No Then e.Cancel = True End If End Sub [/code] | |
Re: [b]>cud anyone tell me what is session in asp.net[/b] HTTP is a stateless protocol. A client opens a connection and requests some resource. The server responds with the requested resource. After closing the connection, the server [icode]does not remember any information[/icode] about the client. So, the server considers the next … | |
Re: [b]>Is there any provision in Components(.dll's) to create a small UI. which would be used by external applicaton. [/b] Yes you can do. Windows Form control library is an example. | |
Re: You can simply fetch rows from the database with SqlDataAdapter object. [code] Dim Adp as New SqlDataAdapter("select * from tablename where col1='" & Session("id") & "'","put_connection_string") Dim dt as new DataTable Adp.Fill(dt) GridView1.DataSource = dt GridView1.DataBind() [/code] | |
Re: [b]>Is there a way to use the binding navigator control WITHOUT setting up a datasource using the wizard?[/b] Yes. [code] DataSet ds = new DataSet("TestDB"); DataTable dt = new DataTable("Table1"); BindingSource bind; private void Form1_Load(object sender, EventArgs e) { dt.Columns.Add("No"); dt.Columns.Add("Name"); dt.Rows.Add("1", "A"); dt.Rows.Add("2", "B"); ds.Tables.Add(dt); bind = new BindingSource(ds, … | |
Re: You can send unix command using Socket. | |
Re: This code insert a record into the table [B]Emp[/B]. Take a look at this code. [code] System.Data.OleDb.OleDbConnection cn; System.Data.OleDb.OleDbCommand cmd; cn.ConnectionString="put_connectionstring_here"; cmd.CommandText="insert into emp values (@eno,@ename,@edate)"; cmd.Connection=cn; cmd.Parameters.AddWithValue("@eno",textBox1.text); cmd.Parameters.AddWithValue("@ename",textBox2.text); cmd.Parameters.AddWithValue("@edate",textBox3.text); cn.Open(); cmd.ExecuteNonQuery(); cn.Close(); [/code] | |
Re: Take a look at following code: aspx markup [code] <form id="form1" runat="server"> <div> <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" onrowcancelingedit="GridView1_RowCancelingEdit" onrowdeleting="GridView1_RowDeleting" onrowediting="GridView1_RowEditing" onrowupdating="GridView1_RowUpdating" onselectedindexchanged="GridView1_SelectedIndexChanged"> <Columns> <asp:BoundField DataField="eno" HeaderText="No" /> <asp:BoundField DataField="ename" HeaderText="Name" /> <asp:BoundField DataField="edate" DataFormatString="{0:dd-MMM-yyyy}" HeaderText="DateJoined" /> <asp:CommandField ShowEditButton="True" /> <asp:CommandField ShowSelectButton="True" /> <asp:ButtonField CommandName="delete" Text="Delete" /> </Columns> </asp:GridView> </form> [/code] … | |
Re: Have you looked at - [url]http://www.codeproject.com/KB/cs/oazswitchnetconfig.aspx[/url] | |
Re: [b]>how to use the value of a textbox from form.cs to a new class[/b] You can pass textbox value to an instance of new class using - Constructor, public properties or method. Add constructor to your class, [code] public class MyNewClass { public MyNewClass {} public MyNewClass(string val) { ... … | |
Re: Do not hijack another thread to ask your question but start your own thread instead. Please read the rules before posting again - [url]http://www.daniweb.com/forums/thread78223.html[/url] and [URL="http://www.daniweb.com/forums/faq.php?faq=daniweb_policies"]rules[/URL]. Thread Closed. | |
Re: Qualify the variable with modulename. [code] modGlobalvar.Name=dr(3).ToString [/code] and [code] TextBox1.Text =modGlobalvar.Name [/code] | |
Re: [b]>can we move from one language to another language.so user can enter the details in the specific language. [/b] Yes. That is Globalization & Localization - Globalization is the process of designing/developing app that function for multiple cultures/languages. Take a look at msdn article: 1. [url]http://msdn.microsoft.com/en-us/library/c6zyy3s9.aspx[/url] 2. [url]http://msdn.microsoft.com/en-us/library/aa292205%28VS.71%29.aspx[/url] | |
Re: [b]>select command of linq in asp.net [/b] Here is the best doc of [URL="http://msdn.microsoft.com/en-us/netframework/aa904594.aspx"]Linq[/URL]. [code] List<int> nos = new List<int>() { 1,-2,33,4,2,-44,22,33,44 }; var positiveNos = from no in nos where no > 0 select no; foreach (var v in positiveNos) Response.Write("Value :" + v); [/code] | |
Re: Check/verify the code you have written in page load event. | |
Re: Take a look at - [url]http://www.windows-tech.info/3/8e83bac5425ac8ca.php[/url] | |
Re: [b]>HOW could i achieve this using vb.net and SQL server 2005 as databse. [/b] Firstly, create a DataTable with four columns. [code] Dim dt as new DataTable dt.Columns.Add("ItemNo",getType(integer)) dt.Columns.Add(Item") dt.Columns.Add("Qty",GetType(Integer)) dt.Columns.Add("Price",GetType(Integer)) [/code] Add some rows into datatable object. [code] dt.Rows.Add(10,"Item1",1,2) ... [/code] Finally write a code which insert each row … | |
Re: You can send an email using classes of System.Net.Mail namespace. | |
Re: [b]>please help me it's urgent. [/b] Please read the rules before posting again - [url]http://www.daniweb.com/forums/thread78223.html[/url] and [URL="http://www.daniweb.com/forums/faq.php?faq=daniweb_policies"]rules[/URL]. [b]>connection string [/b] Open applicationname.config and change the connection string once an application is installed. | |
Re: You need to start learning [URL="http://msdn.microsoft.com/en-us/vcsharp/aa336809.aspx"]C#[/URL] from the scratch. | |
![]() | Re: [b]>need some help to create an array with character indexing[/b] Think about Indexer. Create a new type and add indexer method. [code] class Test { static void Main() { TArray a = new TArray(3, 4); a['a', 'a'] = 10; Console.WriteLine(a['a', 'a']); } } public class TArray { int[,] ar; public … |
Re: [b]>What is the potential cause of this behaviour ? I am using SQL Server 2008.[/b] MS-SQL server is not installed properly OR MS-SQL server instance is not started yet. I think you have MS-SQL 2008 Express edition. | |
Re: Do not write string directly to the drawing, write them to the bitmap. [code] .... Bitmap btm = new Bitmap(30, 30); Graphics t = Graphics.FromImage(btm); t.Clear(Color.Black); t.DrawString("Text here", new Font("Arial", 20f), Brushes.Red , new PointF(1, 1)); g.DrawImage(btm, new Point(15, 15)); .... [/code] | |
Re: Use printing service components of .net framework. | |
Re: [b]>how can i fill the combobox?[/b] Two ways: 1. DataBinding 2. Use Items collection to add list items. | |
Re: Put single quote. [code] MyComm.CommandText = "SELECT * FROM identifikace WHERE identifikacni_kod ='" & txtJmeno.Text & "' AND heslo ='" & txtHeslo.Text & "')" [/code] | |
| |
Re: Do not hijack another thread to ask your question but start your own thread instead. Please read the rules before posting again - [url]http://www.daniweb.com/forums/thread78223.html[/url] and [URL="http://www.daniweb.com/forums/faq.php?faq=daniweb_policies"]rules[/URL]. Thread Closed. | |
Re: [code] <script type="text/javascript"> var so = new SWFObject("<%= Request["qry_string_key"] %>', "mymovie", "192", "67", "7", "#FFFFFF"); .... [/code] | |
Re: [b]>What is Callback?[/b] From the [URL="http://en.wikipedia.org/wiki/Callback_%28computer_science%29"]wiki[/URL]: In computer programming, a callback is a reference to executable code, or a piece of executable code, that is passed as an argument to other code. This allows a lower-level software layer to call a subroutine (or function) defined in a higher-level layer. | |
Re: Have a look at MSDN article - [url]http://msdn.microsoft.com/en-us/library/51ket42z%28VS.71%29.aspx[/url] | |
Re: Use JavaScript open method to open a url in the new browser . [code] open("url","_blank","left=100px,top=100px,width=300px,height=200px"); [/code] | |
Re: [b]>writeing hex to serial port [/b] You could use System.IO.Ports.SerialPort class. | |
Re: Take a look at this[URL="http://channel9.msdn.com/forums/TechOff/224858-Read-Write-USB-Port-CCompactFramework/"] thread[/URL]. | |
Re: [code] Select CASE variable Case exp1 case exp2 End Select [/code] | |
Re: LoadXml method of XmlDocument. [code] System.Xml.XmlDocument doc = new XmlDocument(); doc.LoadXml(xmlStr); [/code] OR [code] var result = from ele in XDocument.Parse(xmlStr).Descendants() select ele; [/code] | |
Re: [b]>how am i to read in the file that was opened by the dialog into other functions? [/b] Through the method arguments. Pass a filename or a reference of FileInfo object to that method. | |
Re: [b]>can somebody tell me the ado code to do so plz help me n i hope u understand what i want to say[/b] Yes. We want to help you but you need to show effort, and what better way than posting the code that you have tried so far? |
The End.