VS 2010 Copying Arrays?

Feb 21, 2012

I have an array of the following structure:

<Serializable()> Public Structure Piece
Dim id As Integer
Dim pos As Point

[code]....

View 1 Replies


ADVERTISEMENT

VS 2005 - Copying The Internet Cache Folder But Getting Copying Error?

Apr 22, 2009

I have a copying error with my program. I am trying to copy the internet cache folder, and the error states that some files cannont be copied (read only maybe?) How can i make it copy, or just skip the uncopyable files?

My.Computer.FileSystem.CopyDirectory(Environment.GetFolderPath(Environment.SpecialFolder.Internet Cache), "d:My Documents")

View 12 Replies

Copying Information From A Website Into VB 2010?

Jul 16, 2011

on my form i have a button and five textboxes... when i click the button it takes me to a website. on this website is a list of five items. i want to take these five items and place them in the 5 textboxes. up to now what i have been doing is highlighting the first item in the list on the website, right clicking and using the copy feature, then going back to the vb form and pasting the first item in textbox1... then go back to the website and highlight item two... return to the form and paste in textbox2.. then the same procedure for the next three items

is there a way to highlight all five items from the website, right click, select copy and then paste the information into the 5 textboxes on the form... one in each of the textboxes provided without doing it one at a time

View 2 Replies

VS 2010 : Copying Contents But Not Whole Folder?

Mar 30, 2012

I am trying to show a list of folders then copy only the selected folders.It displays the folders correctly but copies only the contents not the folder itself, how can I correct this?

Display files

Private Sub ListDirs()
SrcFolder = (("\" & (OldPCTxtBx.Text) & "" & "C$"))
Dim dir As New IO.DirectoryInfo(SrcFolder)
For Each subFolders As IO.DirectoryInfo In dir.GetDirectories

[code]....

View 4 Replies

VS 2010 Copying Db Fields To Variables?

Apr 5, 2011

I have been using VB a fair bit in the past developing a Access Database, recently I wanted to give my front end interface a bit more power so I have started learning VS 2010.

Anyways, I am still using Access for my databases and i am having a bit of trouble working with the data in VS 2010, what i would like is the following:

A way to form a string or integer from a SQL query (from a single field or multiple on that row) assuming the query will always return one row.

Then a way to write string or integer variables back in to db fields.

example:

Dim cn As New OleDb.OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|ItemRegisterDB.mdb")
Dim cmd As New OleDb.OleDbCommand With {.Connection = cn, .CommandText = "select * from tblItemregister where ItemID = 1"}

[Code]....

Example = ??? 'What would i need here to copy fields from that row to string?

View 4 Replies

VS 2010 Copying Listview To Clipboard?

Jun 6, 2011

I googled some code that takes listview contents and puts it into the clipboard, but it doesn't work, when I paste the contents into Excel it looks weird!Here's the code that copies listview contents to clipboard:

Public Sub CopyListViewToClipboard(ByVal lv As ListView)
Dim buffer As New StringBuilder
For i As Integer = 0 To lv.Items.Count - 1

[code]....

The code makes sense to me when I'm trying to see what it's doing but why in the world when I paste the contents into Excel it looks like this:I don't understand...everything is fine when I'm adding new items to the listview and all, but when I click "copy" and then paste it into ms excel this is it how it looks like...

View 2 Replies

VS 2010 Copying A File To Many Remote Computers

Jul 20, 2011

I have to periodically (2-3x/wk) copy a file or two to approximately 70 remote computers. I have full control of the remote computers and they all follow the same directory structure and security permissions. I have asked in the General PC forum to see

[Code]...

View 11 Replies

VS 2010 Copying/Removing/Replacing Files?

Jan 10, 2010

I have a file that is constantly altered, and if an error happends, I want to have a backup. I was wondering if there's a way to make a script that will copy all the files in the selected folder, and post/overwrite them every 20 minutes in a back-up folder or something, and I say overwrite so it doesnt take up 298347234 gigs of data.

View 2 Replies

VS 2010 Reliably Know When Large File Is Done Copying?

Jul 5, 2011

Is there anyway to reliably know when a large file has completely finished copying to a particular folder? For example, Computer1 copies a large file to Server1Share1. On Server1Share1, I want to do something AFTER the file is done copying, without Computer1 intervention.

[Code]...

View 9 Replies

VB 2010 - Thumb Drive - Formatting, Partitioning, And Copying The Image

Oct 24, 2010

I have to create a program to manage a large number of USB Thumbdrives. In short, the drives will contain corporate images used by technicians to prep machines in the field. I do not have to create the images as they are already provided. Since I have to create 50 plus of these at one time, I am looking at writing a program to automate the process. As it stands now, formatting, partitioning, and copying the image to each key individually is, as you can understand, not efficient time wise. I have already purchased two industrial quality 7 port powered hubs.

The plan is to be able to: Fill all 14 slots in the hubs with USB ThumbdrivesUse the program to select the drives to prepareHave the program format and partition the drives (bootable)Copy the contents of the image folder provided to the USB keys. The idea is to do the above by filling all the slots and hitting one button, then walking away to do other work. When done, the drives would be ejected, and the next set of 14 installed.

I have already created the User Interface. It consists of: 5 buttons (Scan For Drives, Format Drives, Build Drives, Build And Format Drives, Exit).One "Select Source" entry field to select the source of the Image Files.One Checked Entry List. This is where all available drives will be listed, and the one's desired to be checked.

Now, it has been 20 years since I did any coding, and all of that was done in languages that are pretty much dead today (Turbo Pascal, Clarion Professional Developer and R:Base), so to say I'm behind the curve is an understatement. While I was never a real fan of Basic, I have some experience with it. But today's VB.Net ain't your daddy's basic, and there's no way I have time to learn C or C++. I have the Express version of Visual Studio 2010, which should be fine for this project.

View 2 Replies

VS 2010 Finding Text In A Textbox And Copying It To A String Variable?

Jan 9, 2011

I'm trying to make a program that can export my schedule into a CSV file to upload on to google calender.I need to extract some text within a textbox control. I'll show you an example.This is the text in the textbox:

Quote:

Monday, 10 January, 2011
09:45 - 18:00
Phone Work09:45 - 12:15

[code]....

I need to get just the date and times from this list, and put them in variables. so that I'll end up with:

1) A string with a value as a date, which would be "10 January, 2011" for example: strDate1 would have the value of "10 January, 2011"

2) A start time, for example: strStartTime1 would have the value of 9:45

3) An end time, for example strEndTime1 would have the value of 18:00

View 1 Replies

Lock From Reading/writing/copying A Loaded XML File With XDocument.Load [VB 2010]?

Aug 1, 2011

lock from reading/writing/copying a loaded XML file with XDocument.Load [VB 2010]?

View 1 Replies

VS 2010 Can't Use Arrays With CType

Oct 25, 2011

does your IDE ever get amnesia?in the line before it is clearly defined.in the following line it is not.Maybe it's a faulty translation from Tangible Software.the C example i'm looking at:

IAnimatedMeshSceneNode* newNode = (IAnimatedMeshSceneNode*) oldNode->clone();

translated as:

Dim newNode As IAnimatedMeshSceneNode = CType(oldNode.clone(), IAnimatedMeshSceneNode)

had to make a dummy for it because i can't use arrays with CType.

View 1 Replies

VS 2010 How To Compare Arrays

Jun 12, 2012

I'm trying to determine the highest customers in a single month of the year. I also need to add the corresponding month to that.

View 4 Replies

VS 2010 - Loading CSV File Into Set Of Arrays

Nov 1, 2011

I need to load a CSV file into a set of arrays, and show the output into a listbox, which are associated with other textboxes(labels). earlier i had the names all loading into the listbox, but the values in the label were only correct for the last line in the csv file, not corresponding correctly to the listbox values.

Here's my current
Option Explicit On
Option Strict On
Imports System.IO
Public Class frmMain
Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
[Code] .....

And here are the contents of my csv file:
Randy,Johnson,100,95,80,85
Martin,Lin,90,90,90,90
Tony,Nowakowski,100,100,100,100 .....

View 12 Replies

VS 2010 Multi-dimensional Arrays

May 24, 2011

I have a string, which can easily be splitted by seperators into an array.The output has to be splitted again an move into a multi-dimensional array (2nd index)[code]

View 2 Replies

VS 2010 Two Separate Arrays And Then Compare Them?

Jul 2, 2011

I want to put the matches from a regular expression into an array or something that i can use to compare it with another array, it being the lines from a txt file names "users.txt". Code A:

[Code]...

And the second code will do the exact same thing. What i want to do is compare each line in the Txt file (Code B) to the reg expression matches (Code A) and for it to alert me if any is missing. So it needs to compare Code B to Code A. (PS. Order is irrelevant, it can be in different places as long as its there) In my other thread i got a little confused and couldn't clearly communicate what i was trying to do.

View 32 Replies

VB6 Used Recordsetsor Arrays - .Net Framework In VB2010. Datasets, Dataviews. Tableadapters, Arrays. Enums ?

May 9, 2010

In VB6 I load a recordset containg all of the records (6 fields per record)in a table into an XArray and then manipulate the records in the array and then write them back to the original table. The array issorted by the first field (1 to maybe 8000 or more) I need to find records in the array by an ID field and then move them (because of some external criteria that happens many times) from say number 400 to number 375. Then all of the other records between 375 and 399 were renumbered up 1 to fill the gaps left by the move.

The XArray worked well as it could find and also move to a next record easily to facilitate the revisions to each record quickly. Everything is done in VB6 in code and nothing visual needs to be shown to the user until say 2000 of these external changes are complete. What is the best, most efficient way to do this in the .Net framework in VB2010. Datasets, Dataviews. tableadapters, arrays. enums ?

View 3 Replies

Integer Arrays - User Enter In Big Integers Using - Two Parallel Arrays

Dec 10, 2009

My assignment is to have a user enter in big integers using what i think is two parallel arrays. I got this far but now im stuck. I think i need to actually convert the text box input into an array but i do not know how to do that. I am all over the place in this project.

'Created/ Revised by: Jessica Falcetta
'Cap 204 Final Project: Big Integer Project
'Project Purpose: To calculate large integers through parallel arrays

[CODE]...

View 5 Replies

Passing Arrays Through Fortran Dll From App Turning To Single Element Arrays?

Feb 2, 2010

I have a VB.net console app and I am opening a function in a dll written in fortran. I am passing 3 arrays through the function by reference. When they come back out the otherside they ahve all tunred to arrays of only one element And that element is 0.I read on the internet somewhere that when doing this kind of thing it is a good idea to only pass the first element of the array into the function.I tried changing my function declaration to accepting single elements rather than single dimensional arrays, and now the arrays are the same length before and after the function call, but they don't seem to be changing at all, so i'm not sure that this is working

View 1 Replies

Arrays And Storing Data To A File VB 2010

Feb 6, 2012

I am trying to store 8 separate pieces of information in a text file (like a database) [but not a SQL database], consisting of integers and strings. How would I use an array to do this? Will an array collect data from text boxes (I also want to display the 8 pieces of information in separate boxes). also how would I save the text file so I can open it again or open a different text file (database?), from within the program?

EDIT: I see I need to use readline and writeline to read/write from a text file but how would I find specific data to show in my boxes?

View 1 Replies

Compare Arrays And Listboxes Values In VB 2010

Jul 22, 2011

I have a program that has to store a pre-made array that contains strings (moviename, moviegenre).

I setup all the items in the array already, example:

moviearray(0,0) = "Green Lantern"
moviearray(0,1) = "Action"

For this example, if the user selected "Green Lantern" from my listbox, then the label needs to display "Action". So yeah, it's a 2-column array: first column = movie name, 2nd column = movie genre. Now, I have a listbox containing all of the movie names (not entered by the array, but entered through the Item property of the listbox). When a selection is made in the listbox and a button is clicked, I need to have the genre of the movie output to a label. That is where I am stuck, I just can't figure out to compare what's in the list box with the first column of the array to output the 2nd column to the label.

View 15 Replies

Does 2010 Support Arrays Of Anonymous Objects

Sep 26, 2010

In C#, one can create an array of anonymous objects with new []. This was not supported in earlier versions of VB.NET, but a comment by Chris Dwyer in another StackOverflow post suggests to me that it might be supported in VB.NET 2010. I haven't been able to confirm this though.

View 1 Replies

VS 2010 - Arrays And Do Loops With Rows And Columns

Feb 28, 2011

So I am writing a program that uses ArrayA(10) and ArrayB(10) and uses Do loops to output the sum of ArrayA(1) + ArrayB(1) in one column then the difference in the next column, then the product in the next column, then the quotient in column 4 of a Matrix(10, 4) in a listbox. And continues doing this until there are 10 rows of 4 columns. I was wondering for tips on how I can get this done.

View 6 Replies

VS 2010 - Making Arrays Into Panel Or DataGridView

Mar 15, 2012

I am making a array (unknown value) into a grid for a game of pairs (where you must get both of the cards). So far I have specified the array to a specific size of either 6, 6 10,10 or 16, 16. using a button. The selection is defined from the button as specified before
Dim NumberOfCards(Selection) As Integer
Dim NumberOfCards(Selection) As Integer
Now I have a panel box which I want to add the number of rows / columns as the array sizes which I cannot do. But also add a image specific to all of them.

View 1 Replies

VS 2010 - Use StringCollections Instead Of String Arrays For My.Settings

Jul 29, 2011

To use StringCollections instead of String Arrays for My.Settings. I've opened a file and have this:

CODE:

But I error on line 2, saying "Object Reference not set in Instance of an Object". So then, I try to use New before I go Into the loop: My.Settings.Trunk = New System.Collections.Specialized.StringCollection

But then i get "index outside bounds of array" still on line 2. This is weird to me. Is it because my StringCollection doesn't have an array size? If so how do i declare an array size for this? Or is this just so totally different from String Arrays?

View 2 Replies

VS 2010 Assit With Sequential Searches And Arrays?

Dec 8, 2011

I'm new to VB and my book doesn't explain sequential searches very well. I need help with the application I'm creating for school. My application has to allow the user to enter a number and then it will verify if the number is valid by searching through the list of arrays I provided.The question:Create an application that allows the user to enter a charge account number. The application should determine whether the number is valid by comparing it to the numbers in the following list: (see code)The list of numbers should be stored in an array. A sequential search should be used to locate the number entered by the user. If the user enters a number that is in the array, the program should display a message indicating the number is valid. If the user enters a number that is not in the array , the program should display a message indicating the number is invalid.

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim Account(0 To 17) As Integer

[code].....

View 7 Replies

VS 2010 Binary Search Of Arrays/Lists?

Dec 15, 2011

my binary search isnt working, i think it has to do with the fact that im using a list and its searching thru an array

List
Option Strict On
Public Class Form1

[Code].....

View 9 Replies

VS 2010 Create Sequential File Arrays?

Nov 25, 2010

reading words from a text file and displaying them at random.The format of the text file is....

verb
noun
answer1

[code]......

View 7 Replies

VS 2008 Arrays Displaying States/searching Arrays?

Oct 30, 2010

the statement Dim state(49) As String and maintain a list of certain states. The list of states should always be in alphabetical order and occupy consecutive elements of the array. The buttons in the program should give the user the following options: (a) Take the state specified by the user in a text box and insert it into its proper position in the array. If the state is already in the array, so report. (b) Take the state specified by the user in a text box and delete it from the array. If the state is not in the array, so report. (c) Display the states in the array. "

Private Sub states_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
state(0) = "Alabama"

[code]....

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved