I am using Visual Basic 2008, and I am making a simple meeting planner program. The data stored for each day is stored into an array with three fields:
I have a rather simple question - how do i delete an array of buttons (not reassigning different values, but removing the buttons and keeping the array for storage of other buttons). I haven't got a clue
1) How to Delete Dynamically Allocated Array? a) delete a[] b)delete a[0] c) delete[] a d)delete [0] a
My answer a.Correct or not
2)Can we use DML statement in function? a)Yes b)No c)Temp tables d)None
My answer d.Correct or not
I read somewhere the diff b/w stored proc & functions?One of them is Stored Procedure returns more than one value whereas functions return single value.When the interviwer ask me the question,i asnwered includg my above point,but he told me no SProc do no return any value.
4)Can we return value from SPROC? a)No b)Using O/p Parameters c)Using return statement d)B & C Both
ANSWER---??
5)Views are complied or not a)Yes b)No c)Partially Compiled d)None
ANSWER---??
6)Can we user specific data in application? My answer no.Me correct 7)Diff b/w primary key & UNIQUE key excepts one diff primary doesn't allow NULLS whereas unique does.One diff i told we can craete only one primary key for a table,whereas a table can have more than one unique key. ANy more differences?????
8) Can we call a fn. widout dbo? I ans NO. Me correct or nt
9) Four types of files created by assembly?
10) What is candidate Key?
11)Can we implement CAS in config file? I ans YES. Me correct or nt
12) dim txt as textbox dim txt as new textbox Both the above statements are same or not.If nt wats d diff? I ans both are same. Me correct or nt
13)CAS is part of inbuild framework? I ans YES. Me correct or nt
14)Can constructor call itself?
15)Accept method applies to a)Textbox b)Listbox c)Combobox d)None of above MY ans a. Me correct or nt
I need a way to delete the last element in an array when I don't know how big the array is.Basically I need the VB version of php array_pop, but nothing relevant seems to be appearing in search results.
have an ArrayList of arrays and I am having issues iterating through it to delete cetain entries.I want to go through the entire ArrayList and check if the array at index 0 equals "". If it does, then put that into another array.heres the exception i get
Quote: System.ArgumentOutOfRangeException was unhandled Message="Index was out of range. Must be non-negative and less than the size of the
Dim strArray() As String = {"test1", "test2", "test3"} strArray.SetValue("", 1) Console.WriteLine(strArray.Length) Console.ReadKey()
This still leaves me with an empty array value, how can I just delete it or can't I? Do I have to use an arraylist and if so how do I convert an array into an arraylist?
I would like to delete the contents of my array in .NET code. The examples I have seen say..[code]This is way too simple to be so complicated. I just want to delete the array between populations.
I'm working on a To Do List program of sorts. I currently have a CheckedListBox on the form with an Add Button and a Delete Button. I send the items to an array and then use that array to fill in my CheckedListbox. This all works.
I wrote the following code to delete items:
Dim summarylistboxindex As Integer summarylistboxindex = SummaryListBox.SelectedIndex MonkeysTasks(summarylistboxindex) = String.Empty
[Code]....
I use a variable called INTCOUNTER to keep track of my position in the array.
My question:
How can I use the second piece of code that deletes multiple items at once from my CheckedListBox AND delete the corresponding entry in the array?
ie if my checkedlistbox items were Apple Orange and Banana
I want to delete Apple and Banana at the same time and then remove them from Fruits(0) and Fruits(2) at the same time they are deleted from the CheckedListBox.
How can be find out which file is going to delete when, user provides command like DELETE or SHIFT + DELETE or by programmatically gives DELETE command. Well I know about FileSystemWatcher Class, but this class doesn't provide information before delete...
on cloning a selected listviewitem from listview1 when a button is clicked to listview2. How do I achieve this? Here is the code I have but does not work exactly how I want it, it just makes a clone of all the listviewitems in listview1.
foreach (ListViewItem item in this.listView1.Items) this.listView2.Items.Add((ListViewItem)item.Clone());
I want to start a thread, which handles a class.That class should add a listviewitem into a listview on the main form.[code]No idea why that doesn't work.I really need threading, cause it would block the program.These codes are examples, the real one is with loops & stuff, so that blocks the program.
I am trying to find a way to associate a key with an index for a Listviewitem in VB.Net. I'm not even sure if it can be done with .Net but I know in VB6 I could do a
Listview.listitem.add "somestring", "somestring".
For the application I am using this in, I cannot have duplicate item.text so I would make the key the same as the string. this also made accessing the item easier since I didn't have to rely on index to update the subitems.
I have a ListView, wich its View property is set to LargeIcon and there isn't any ImageList attached to it.The thing is that ListViewItem's text overlaps next ListViewItem's text. With View set to Tile I have no problem at all, but It shows the items one below another.When I add columns header,I set their width to a large number,but it seems that ListViewItem doesn't care,I get the same mentioned effect.My question is wich property do I have to change to avoid ListViewItem's text overlapping?
Here is my problem, I have been learning about SendMessage and getting the Handles of Windows. In the following code example I show that I can get the number of Items in a ListView Control by API, but I have no idea of how to select an Item within the Control, ListView; in other words, how to select a ListViewItem:
I have a form that has a listview with a number of items on it. In certain circumstances, when I load the form, I want a particular item to be automatically selected. The user will select the item to be selected from another form, and I will pass this item to the form in question.
But how do I tell the listview 'hey, set this item as your selected item?" There isn't a writable 'SelectedItem' property.
I have been learning about SendMessage and getting the Handles of Windows. In the following code example I show that I can get the number of Items in a ListView Control by API, but I have no idea of how to select an Item within the Control, ListView; in other words, how to select a ListViewItem:
Public Class Form1 'Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Integer
I have Main and Detail forms. The Main form has ListView1. I would like to select new added ListViewItem in ListView1 when user click Save button in Detail form. I have problem only when I'm adding new item. When I modify and save existing item according item is selected after save command.
below is a small part of my asynchronous TCP connection code. When I connect I'm passing a ListViewItem as Object parameter. I'd like to update the ListViewItem once the connection has been established or an error occurs. ServerConnect runs on a separate thread, because it's an asynchronous connection, so I can't update the ListViewItem directly.
Does anybody know how to update the ListViewItem?
I looked at jmcilhinney's asynchronous TCP example in the Codebank forum, but it confused me. I don't know which parts I need and which parts I don't need.
::edit::
One more thing. I also need to update the ListViewItem in the Read sub, but I'm passing "buffer" as Object, so how would I update the ListViewItem there?
vb.net Imports System.Net.Sockets Public Class TCP Private Socket As TcpClient