Try this vb code behind, then comment out my test Private Sub BindGrid() Dim dt_SQL_Results As New DataTable '' Commenting out to use test data as I have no access to your database 'Dim da As SqlClient.SqlDataAdapter 'Dim strSQL2 As String 'Dim Response As String = "" 'strSQL2 = "SELECT...
.net,vb.net,conditional,variable-assignment,iif
What you're asking to do would have been possible in a language that supports pointer types (such as C/C++, or C# in unsafe mode) with dereferencing; VB.NET doesn't do that. The best you got to leverage is local variables, reference types, and (perhaps) ByRef. If it's a Class, its instantiation...
If I understand you correctly, you can use .Element() method to find first child having element name equals certain name, for example : Dim elementName As String = "TestDB" connectionString = root.Element(elementName).Value Dotnetfiddle Demo...
I think the only solution is create a new function and gradually migrate to it. Public Function ExecuteQueryReturnDS(ByVal cmdQuery As SqlCommand) As DataSet Try Dim ds As New DataSet Using sqlCon As New SqlConnection(connStr) cmdQuery.Connection = sqlCon Dim sqlAda As New SqlDataAdapter(cmdQuery) sqlAda.Fill(ds) End Using Return ds Catch ex As...
sql-server,vb.net,authentication,connection-string
You need to add Integrated Security=SSPI and remove username and password from the connection string. Dim ConnectionString As String = "Data Source=Server;Initial Catalog=m2mdata02;Integrated Security=SSPI;" ...
I would recommend you to use GridTemplateColumn as : <telerik:GridTemplateColumn DataField="Call" DataType="System.Int32" FilterControlAltText="Filter Call column" HeaderText="" SortExpression="Call" UniqueName="Call"> <ItemTemplate> <a href="http://twilio.liquidus.net/handleincomingcall.ashx?call=<%# Eval("Call") %>" title="Get call"><asp:Label ID="lblCallId" runat="server" Text='<%# Eval("Call") %>'></asp:Label></a> </ItemTemplate> </telerik:GridTemplateColumn> ...
You need to build your query to look like this: Name LIKE '%tom%' AND Name LIKE '%jack%' .... So take your input, split it up, project it to a new string and join them all together with AND: bndSourceGrid.Filter = string.Join(" AND ", cboName.Text .Split(' ') .Select(s => string.Format("Name LIKE...
You need to add Microsoft.VisualBasic as a reference to your Project. In your Project in the Solution Explorer right-click References and select "Add Reference". Search for "Microsoft.VisualBasic" in the Framework Tab.
asp.net,vb.net,stored-procedures,hash,password-protection
A very simple aproach is to use a MD5 hash. public class MD5 { public static string Hash(string message) { // step 1, calculate MD5 hash from input System.Security.Cryptography.MD5 md5 = System.Security.Cryptography.MD5.Create(); byte[] inputBytes = System.Text.Encoding.ASCII.GetBytes(message); byte[] hash = md5.ComputeHash(inputBytes); // step 2, convert byte array to hex string StringBuilder...
Try using Generics. Public Interface ICell(Of T) Property Value As T End Interface Public Class cell(Of T) Implements ICell(Of T) Public Property Value As T Implements ICell(Of T).Value Public id As Long Public Formula As String Public ix As Integer Public lev As Integer End Class Then both of these...
Remove the Root namespace from the project properties: ...
You can create labels and set the parents of the label to be that button *Remember that the position of the label is now relative to the button Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load lblA.text="A" lblA.Parent=Button1 lblA.Location = New Size(0,0) lblB.Text = "B" lblB.Parent = Button1...
vb.net,linq,properties,interface
If i have understood it correctly you want to get all selected parents and all selected children. You could use a recursive method: Public ReadOnly Property checkedList As List(Of TreeSelectorAttributes) Get Return rootList.Where(Function(t) t.SelectedInTreeSelector). SelectMany(Function(root) GetSelectedChildren(root)). ToList() End Get End Property Function GetSelectedChildren(root As TreeSelectorAttributes, Optional includeRoot As Boolean =...
Assuming the two have the same schema, try this. Replace: lbProduct.DataSource = myDataTable lbProduct.DataTextField = "product_name" lbProduct.DataValueField = "product_id" lbProduct.DataBind() With this: CType(lbProduct.DataSource,DataTable).Merge(myDataTable); lbProduct.DataBind(); ...
In the second? example here(VS2015RC) Microsoft is using IIF to illustrate how the If operator is short circuited, so I think IIF is still with us.
The Designer creates property getters and setters for the images etc you add to Resources. So, for an image named dicedark1.jpg, it creates: Friend ReadOnly Property diceDark1() As System.Drawing.Bitmap Get Dim obj As Object = ResourceManager.GetObject("diceDark1", resourceCulture) Return CType(obj,System.Drawing.Bitmap) End Get End Property You can see these in Resources.Designer.vb. So...
database,vb.net,winforms,textbox
I don't think you need to first query the db to get the count of records before then going back to the db to get the phonenumbers, you could just do this: mycom.CommandText = "SELECT Cellphone FROM tbl_applicant where Gender='Female';" myr = mycom.ExecuteReader While myr.Read() TextBox1.Text = TextBox1.Text & myr(0)...
It seems to be a permission problem. You need to pass a user name and a password of an administrator user to your command ..... process.StartInfo.UserName = "yourAdminUser" process.StartInfo.Password = GetPassword() ..... Public Function GetPassword() as String Dim ss = new SecureString() ss.AppendChar("p") ss.AppendChar("a") ss.AppendChar("s") ss.AppendChar("s") return ss End Function...
change the smtpserver from smtp.outlook.com to smtp-mail.outlook.com web.config settings <mailSettings> <smtp deliveryMethod="Network" from="[email protected]"> <network host="smtp-mail.outlook.com" userName="[email protected]" password="passwordhere" port="587" enableSsl="true"/> </smtp> </mailSettings> ...
You should change your code to something like the following. Note that Everything that returns an object like OleDbConnection, OleDbCommand, or OleDbDataReader is wrapped in a Using block. These objects all implement the IDisposable interface, which means they should be cleaned up as soon as you're done with them. Also...
.net,vb.net,linq,compare,compareto
Change: OrderBy(Function(x) x.index.CompareTo(lineNumbers(x.index))) To: OrderBy(Function(x) lineNumbers.ToList().IndexOf(x.index)) Alternatively, if you changed the type of the lineNumbers parameter from IEnumerable(Of Integer) to List(Of Integer), then you wouldn't need to call the ToList method. Although, I have to say, while I love LINQ because it makes the code so much more readable, this...
Top folders (root nodes in the navigation pane) are store. If you need to add a new store in the profile you can use the AddStoreEx method of the Namesapace class which adds a Personal Folders file (.pst) in the specified format to the current profile. See How to: Add...
If you don't know if the DataSet is initialized: If ds IsNot Nothing Then ' ... ' End If If you don't know if it contains four tables(zero based indices): If ds.Tables.Count >= 4 Then ' ... ' End If So the final super safe version is: If ds IsNot...
You keep adding parameters over and over. Try clearing them at the beginning of the loop: For x As Integer = 1 To DataGridView1.Rows.Count - 1 cmd.Parameters.Clear() and avoid empty Try-Catches. You are ignoring problems in your code when you do that. For one thing, the "Age" field probably shouldn't...
asp.net,vb.net,gridview,datagridview
I inspired with your answer. So, here is my resolution : For data As Integer = 0 To InvestorGridView.Rows.Count - 1 Response.Write(InvestorGridView.Rows(data).Cells(0).Text) Response.Write(InvestorGridView.Rows(data).Cells(1).Text) Response.Write(InvestorGridView.Rows(data).Cells(2).Text) Next ...
The objects have values in them because they are called after Mapping.Map function is called and that's where actual object with values is passed and then AfterMap function is called and that's how it has the values in it.
I have found a workaround. If you do Me.ShowIcon = False after the form is loaded, then it will display in the taskbar, but not on the program. One way to do this is to have a timer enabled/begin as soon as form load ends, and then on tick, do...
you miss the closing parenthesis for the values list: Dim cmd1 As New OdbcCommand("insert into party values('" + pcode_txt.Text + "','" + Trim(UCase(name_txt.Text)) + "','" + Trim(UCase(addr_txt.Text)) + "','" + phone_txt.Text + "','" + combo_route.SelectedItem + "','" + combo_area.SelectedItem + "')", con) My answer is perfectly fit to your question...
Accessing your view components from inside your viewmodel is not the way to do things in MVVM. Because it is specifically not designed to work this way, you will have to go out of your way to make it work. You should probably investigate how to accomplish your goals using...
System.Globalization.DateTimeFormatInfo.InvariantInfo doesn't contain format pattern dd-MM-yyyy(26-06-2015) From MSDN about InvariantCulture The InvariantCulture property can be used to persist data in a culture-independent format. This provides a known format that does not change For using invariant format in converting string to DateTime your string value must be formatted with one of...
asp.net,vb.net,outlook,office-interop
No Office app (including Outlook) can run in a service (such as IIS). Your options are Extended MAPI (C++ or Delphi only), Redemption (which wraps Extended MAPI and can be accessed from any language, including C#), EWS (Exchange only) or straight SMTP.
You must handle the timed event in a handler for the Timer's Tick Event (or Elapsed if using System.Timers.Timer): Private m_strTest As String = String.Empty Private Sub Form1_Click(sender As Object, e As EventArgs) Handles Me.Click m_strTest = Application.StartupPath & "\" + tte4 Timer1.Enabled = True End Sub If using System.Forms.Timer...
You can use LINQ: DataTable nonDups = parsedDataset.Tables("Detail").AsEnumerable() .GroupBy(row => row.Field<string>("Authorization_ID")) .OrderBy(grp => grp.Key) .Select(grp => grp.Last()) .CopyToDataTable(); This selects the last row of each dup-group. If you want to order the group use grp.OrderBy....
javascript,html,vb.net,web,scrape
You can use WebBrowser.ScriptErrorsSuppressed = true; property. Details: https://msdn.microsoft.com/en-us/library/system.windows.forms.webbrowser.scripterrorssuppressed%28v=vs.110%29.aspx...
You're still using c# syntax for your lambda expression. See http://msdn.microsoft.com/en-us/library/bb531253.aspx for details of Lambda expressions in vb. In your case its as simple as val1 = val1.OrderBy(Function (c) c ).ToArray ...
UPDATE Using an XDocument vs an XmlDocument, I believe this does what you're asking without using loops. This is dependent on the elements being in the order of <PhoneType> <PhonePrimaryYN> <PhoneNumber> string xml = "<?xml version=\"1.0\"?>" + "<Root>" + " <PhoneType dataType=\"string\">" + " <Value>CELL</Value>" + " </PhoneType>" + "...
The problem is that Process.Start does not take command line arguments in the first parameter. Use the overload that allows command line arguments. For example: Process.Start("format.com", "H:"); ...
As I mentioned on another site, if I'm understanding you correctly then something like this should do as you want: Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim number = 1 For Each scr In Screen.AllScreens.OrderBy(Function(s) s.Bounds.Left) Dim f As New Form With {.Text = number.ToString(), .StartPosition...
vb.net,winforms,visual-studio-2010
Here's a method that will detect only letters but there is far more to your problem than just that. Private Function IsAllAlpha(text As String) As Boolean Return text.All(Function(ch) Char.IsLetter(ch)) End Function Notice that I have written a Function rather then a Sub. Your original method is poorly written. What you...
You can use LinQ to count the number of brackets: Dim Count = (From s In i Select s Where s = "{").Count And you should rename i to something sensible in my opinion. For when you have just any delimiter in your text and want to count single numbers...
Since you want to change existing forms to inherit another base class you need to change each form that you want to take effect and change what they inherit. Go to each of your forms designer code class. Inside towards the top you will see the inherits statment. Change what...
c#,.net,vb.net,visual-studio-2013
You could to this at start (take Title out of the XAML) this.Title = DateTime.Now.ToString(); But a dynamic ticking clock in the task bar would not be easy ...
vb.net,winforms,visual-studio-2012
Forms comes as partial class meaning the code is separated in two files. The "empty" code you shown is from "mcastmain.vb" (if the file is named as the class). With that one there is a (probably hidden) file "mcastmain.designer.vb" file which contains the generated code by the designer ; and...
I think you can filter the list first and then get the average: MeasuredValues _ .Where(Function(measure) cDate(measure.Key) >= dateFrom And cDate(measure.Key) <= dateTo) _ .Average(Function(measure) measure.Value) REGARDING UPDATE 2: If I understand the new issue corrently, you're getting an error on the Average if Where returns no elements. I know...
.net,vb.net,winforms,datagridview,datatable
what can I do to manage a DataSource instead of directlly manage the rows collection of the control A Class and a collection are pretty easy to implement as a DataSource and will also it will be pretty easy to modify your MoveUp/Dn methods for it. Class DGVItem Public Property...
This is what regular expressions are ideal for, although this is a fairly basic match for them: Dim str as String = "Serial Port Name (COM 1)" Dim inbrackets as String = Regex.Match(str, "\((.*)\)").Groups(1).Value This expression looks for parentheses - the \( and \) - with any number of characters...
vb.net,interface,implements,generic-interface
You need to indicate on the declaration of the Number function that it is the implementation of the Number Function defined in the Interface Interface IBuilder(Of T) Function Number(ByVal literal As String) As T End Interface Class BracketsBuilder Implements IBuilder(Of String) Public Function Number(number__1 As String) As String Implements IBuilder(Of...
Try setting IsUnicodeText to true: 'VB.NET Dim newEntry = New ZipEntry(entryName) With { _ Key .DateTime = DateTime.Now, _ Key .Size = size, _ Key .IsUnicodeText = True _ } //C# var newEntry = new ZipEntry(entryName) { DateTime = DateTime.Now, Size = size, IsUnicodeText = true }; ...
You can use Enumerable.All: dim linqMeddata = From m In medicineDataList Where keys.All(Function(k) m.MedicineData.Contains(k)) Order By m.MedicineName Ascending Select m ...
vb.net,encryption,cryptography,aes
Despite all comments, I still lack understanding of your intentions. Therefore, the sample code below may not provide what you exactly want, but at least should give an idea how to employ cryptographic functions. Particularly, the most notable difference from your approach is that the encryption key and initialization vector...
Try going Project>"Project Name" Properties>Resources>Add Resource>Add Existing File This should add the file into your resources folder. You can then access any file by going My.Resources.Name_Of_Resource...
vb.net,visual-studio-2010,memory-management
When they refer to reading something "into memory" it is simply a way of saying that you are reading it and storing it in a variable (which stores it in memory). Use ReadAllLines to read the entire file into memory: Dim readText() As String = File.ReadAllLines(path) See File.ReadAllLines Method (String)...
vb.net,multidimensional-array,arraylist
Preliminaries: You should turn on Option Strict, and consider using a List(of String) in place of the ArrayList. Your second line, splits the string by "," into Sequence, so there is no need to split it again - you get the error because they cant be split further (and you...
sql-server,vb.net,stored-procedures
No. System.Data.CommandType.StoredProcedure does it for you. It will be helpful: How to: Execute a Stored Procedure that Returns Rows See too: Using EXECUTE with Stored Procedures You do not have to specify the EXECUTE keyword when you execute stored procedures when the statement is the first one in a batch....
vb.net,sendkeys,keyboard-wedge
With SendKeys, the control key is ^. Then any additional keys can follow. So copy would be: SendKeys.Send("^c") And paste: SendKeys.Send("^v") Instead of copying, you can just directly put it on the clipboard (like you suggested), like: My.Computer.Clipboard.SetText("This is a test string.")...
There are several SHFILEOPSTRUCT.fFlags options you'll want to consider. You are asking for FOF_NOCONFIRMATION, &H10. You probably want some more, like FOF_ALLOWUNDO, FOF_SILENT, FOF_NOERRORUI, it isn't clear from the question. Check the docs.
.net,vb.net,winapi,pinvoke,getlasterror
From the documentation of GetLastError: The Return Value section of the documentation for each function that sets the last-error code notes the conditions under which the function sets the last-error code. Most functions that set the thread's last-error code set it when they fail. However, some functions also set the...
mysql,.net,database,vb.net,sql-injection
MySQLCon.Open() Dim SQLADD As String = "INSERT INTO members(member,gamertag,role) VALUES(@memberToAdd, @memberGamingTag, @memberRole)" COMMAND = New MySqlCommand(SQLADD, MySQLCon) COMMAND.Parameters.AddWithValue("@memberToAdd", memberToAdd.Text) COMMAND.Parameters.AddWithValue("@memberGamingTag", membersGamertag.Text) COMMAND.Parameters.AddWithValue("@memberRole", membersRole.Text) COMMAND.ExecuteNonQuery() memberToAdd.Text = "" membersGamertag.Text = "" membersRole.Text = "" MySQLCon.Close() MySQLCon.Dispose() You don't need to use...
"Chatters" is actually a Type in the root object. If you were to create classes, they would look like this: Public Class RootChatter Public Property _links As _Links Public Property chatter_count As Integer Public Property chatters As Chatters End Class Public Class _Links End Class Public Class Chatters Public Property...
Since you are using a predefined username and password in the connection string, your options are limited to the .NET side. Through the database you'll have access to what machine name the update/insert/delete was executed from, but NOT what user. SYSTEM_USER will always return the account specified in the connection...
vb.net,windows,visual-studio-2010,ms-access
There a number of other problems with the code (sql injection, sharing a connection among several commands), but here's a step in the right direction: Try conn.Open() cmdfoods.ExecuteNonQuery() cmdservices.ExecuteNonQuery() cmdreservations.ExecuteNonQuery() bill.ExecuteNonQuery() success = True Catch success = False Finally conn.Close() End Try A more-complete solution: Private Function save_to_data() Dim sql...
Don't use string methods for this, use DateTime.TryParseExact: Dim str = "12/23/2015 12:00:00 AM" Dim dt As DateTime If DateTime.TryParseExact(str, "MM'/'dd'/'yyyy hh:mm:ss tt", Globalization.CultureInfo.InvariantCulture, Globalization.DateTimeStyles.None, dt) Then Dim yearOnly As String = dt.ToString("yy") ' 15 End If Update: with CultureInfo.InvariantCulture and this format you don't even need to use TryParseExact,...
c#,sql-server,vb.net,microsoft-sync-framework,localdb
The C# code contains doubled backslashes in the connection strings, because that's needed to escape them in string literals (or using a verbatim string literal). In VB that's not needed as \ isn't an escape character (as far as I'm aware) so you shouldn't double them: Dim clientConn As SqlConnection...
Is it possible that your datagridview isn't loaded fully when you try to recolor the rows? Since you are setting the datasource, you should put your code that affects the grid after you can make sure that it is finished loading. The column widths change because it is not dependent...
You can put them in a collection and use String.Join: Dim allStrings As String() = {Ten11, Ten12, Ten13, Ten14, ...} Dim notEmpty = From str In allStrings Where Not String.IsNullOrEmpty(str) Dim TenantList As String = String.Join(",", notEmpty) I'm using LINQ to filter out the empty strings, so you need Imports...
Looking at your desired output it seems you want to get the index of word in your string. You can do this by splitting the string to array and then finding the item in an array using method Array.FindIndex: Dim animals = "cat, dog, bird" ' Split string to array...
vb.net,excel,visual-studio-2010
Use StringBuilder.Clear before each row. For rr As Integer = 10 To rowct str.Clear() For cc As Integer = 1 To colct I would also suggest calling My.Computer.FileSystem.WriteAllText once per row since you are writing to the file on each columns....
There are a few basic ways of checking for a value in an integer array. The first is to manually search by looping through each value in the array, which may be what you want if you need to do complicated comparisons. Second is the .Contains() method. It is simpler...
.net,vb.net,reflection,delegates,pinvoke
I would not do this. It would be simpler to pass a string var representing the error message you want to display or a portion thereof (like the function name). The "simplest" way would be to use an Expression Tree. For this, you would need to change the signature of...
You're passing the contents of a ListBox to a method that is just displaying them in a MsgBox(). There are two approaches you can do to accomplish what I think you're wanting. You can pass ListBox.Items to the method and iterate through each item concatenating them into a single String...
One quick way to shuffle items is to sort by a "random" value - Guid.NewGuid() usually works well enough. Then just pull the first row from each group: Dim query = _ From rows As DataRow In surveyAnswerKeys.Rows _ Order By Guid.NewGuid() _ Group By questionSortKey = rows(answerGroup) _ Into...
Well, are you looking for a hashcode like this? "OZVV5TpP4U6wJthaCORZEQ" Then this answer might be useful: Guid g = Guid.NewGuid(); string GuidString = Convert.ToBase64String(g.ToByteArray()); GuidString = GuidString.Replace("=",""); GuidString = GuidString.Replace("+",""); Extracted from here. On the linked post there are many other useful answers. Please take a look! Other useful links:...
xml,vb.net,visual-studio-2010,xsd,xml-validation
Attribute declarations have to come after complexType, otherwise you'll get an error such as the following: [Error] try.xsd:26:40: s4s-elt-invalid-content.1: The content of '#AnonType_CResultsResStuff_EXT' is invalid. Element 'complexType' is invalid, misplaced, or occurs too often. Resolution: Move the attribute declarations below the xsd:complexType element (and remove the extra xsd:complexType). There's another...
My final code (working): Public Function FlipDataSet(my_DataSet As DataSet) As DataSet Dim ds As New DataSet() For Each dt As DataTable In my_DataSet.Tables Dim table As New DataTable() table.Columns.Add(New DataColumn("f")) table.Columns.Add(New DataColumn("v")) Dim r As DataRow For k As Integer = 0 To dt.Columns.Count - 1 r = table.NewRow() r(0)...
I would advise to use another control rather than a TextBox. The way it repaints is just bad. You might have some luck when enabling double buffering on the control (something like here: How to prevent a Windows Forms TextBox from flickering on resize?), but I usually use a ListView...
You probably want String.Equals() and not String.Compare(). Compare is used to order things and not test for equality. What's happening is String.Compare is returning a non-zero number so the condition is being satisfied. The reason for that is because in VB "0" is False but any non-zero number evaluates to...
database,vb.net,for-loop,indexing
Try going backwards - For i As Integer = (.Rows.Count - 1) to 0 Step -1. The issue is that you are deleting rows in the ReservationTableDataGridView as you try to iterate over them, thus changing the index. By going backwards you always have a valid index....
c#,.net,vb.net,winforms,custom-controls
If you want to get results that reliably look like the BorderStyles on the machine you should make use of the methods of the ControlPaint object. For testing let's do it ouside of a Paint event: Panel somePanel = panel1; using (Graphics G = somePanel.CreateGraphics()) { G.FillRectangle(SystemBrushes.Window, new Rectangle(11, 11,...
Your approach doesn't work because you are using ToString on a DataColumn which has no such overload like DateTime. That doesn't work anyway. The only way with the DataTable was if you'd add another string-column with the appropriate format in each row. You should instead use the DataGridViewColumn's DefaultCellStyle: InvestorGridView.Columns(1).DefaultCellStyle.Format...
^\d{1,2}[A-Z]?(?:,\d{1,2}[A-Z]?)*$ Try this.See demo. https://regex101.com/r/hI0qP0/25...
If the data dropped contains a UniformResourceLocator format, you can get the entire URL from that, for example: Private Sub Form1_DragDrop(sender As Object, e As System.Windows.Forms.DragEventArgs) Handles Me.DragDrop If e.Data.GetDataPresent("UniformResourceLocator") Then Dim URL As String = New IO.StreamReader(CType(e.Data.GetData("UniformResourceLocator"), IO.MemoryStream)).ReadToEnd End If End Sub It first checks to see if a...
Looks like you just forgot get(). Proper syntax is: .h file: public ref class ThirdPartyInterfacingBar : Bar { public: property array<Quux^>^ Quuxes { virtual array<Quux^>^ get(); } }; .cpp file: array<Quux^>^ ThirdPartyInterfacingBar::Quuxes::get() { return delegateGetQuuxes(); } ...
You are setting TripleDES.Mode = CipherMode.ECB after you have called TripleDES.CreateEncryptor(), so the first encryption is using the default value of CipherMode.CBC. Since TripleDES is reused, after the first call to EncryptData its Mode is set correctly. Move TripleDES.Mode = CipherMode.ECB into New and it should work consistently....
That would be the .Wrap property: upDownControl.Wrap = True ...
Just have a look at the generated machine code to see what happens. You first need to change an option to ensure the optimizer is enabled, Tools > Options > Debugging > General > untick the "Suppress JIT optimization" checkbox. Switch to the Release build. Set a breakpoint on the...
And is bitwise. AndAlso is boolean. Correctness wise, if we disregard short-circuting, And can always be used in all cases where AndAlso can be used (unless you get creative), but the other way round is not true. That is, And is a "universal" operator that will "do the right thing"...
vb.net,silverlight,datatemplate,children
You are approaching the problem incorrectly. Accessing the DataTemplate and searching for a TextBox will get you nowhere. The template is only a blueprint, only when it is used somewhere (like for each item in your ItemsControl) its content is instantiated (once for each item). One of several possible solutions...
I don't know if you can write to a specific line in a file, but if you need to you can write your lines to a List then write the list to a file 'Declare your list Dim lines As New List(Of String) For Each lineToWrite In YourLines If toInsert...
First when you add the DropDownList, give it an ID (use your cursor variable to avoid having a duplicate ID): EmployeeDDL.ID = "EmployeeDDL" & j.ToString() Secondly, since the DropDownList was dynamically added you need to use FindControl to get an instance of it. Also, make sure SelectedItem is not null/nothing....
vb.net,postgresql,postgis,psql,npgsql
Npgsql is an simply a driver for interacting with the database, HTML formatting of results is completely out of its scope (unlike psql, which is a user-facing console app). Note that there wouldn't be any "universal" way to format the HTML in a way that would satisfy everyone. However, it...
asp.net,vb.net,visual-studio-2012,converter
The result isn't wrong, it only has lower precision than you expected. Floating point numbers have a limited precision by design, and you simply can't expect to get a result that is more precise than its limit. You can use a Decimal to get higher precision. In this case it...