VS 2008 Sql Processing Large Notes?
May 21, 2009
I got a question on sql splitting a record into peaces.I got a big record like this and all of this in one piece of record:
"
5/21/2009 1:03:49 PM
Order has been placed
5/25/2009 1:45:49 PM
[code]....
This is used for making notes, so you can keep adding notes on it until it's done.And I know this is not the 'best' way of keeping these records, this is the way how it was kept until now.So now my manager comes to me and asks to make a different structure of processing these notes.Because it is stored this way I can only retrieve full record from the database, but what I need is a way how to take for example only the 'top line' of it.Example:5/25/2009 8:45:49 PM Confirmation send
View 4 Replies
ADVERTISEMENT
Mar 18, 2011
I just learned some basics of multi threading in VB.net recently as I came across processing a large List of records and inserting them into SQL database one by one.
I have code look like this:
Private Sub btnLoadNow_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnLoadNow.Click
Dim autoLoad1 As New Thread(AddressOf AutoLoad)
autoLoad1.Start()
[CODE]...
Itemlists is a global lists i retrieved from database, everything looks fine to me but when i run this program, I found that the threads are inserting one records 9 times into the database(I have 9 threads in total), which makes me think that maybe i need to specifically assign 1/9 of a list to each thread? Is there another way to do it which doesn't require the splitting of the list, if not , how do i split it then assign?
View 1 Replies
Oct 11, 2010
Been trying to implementing ThreadPool over a large and variable amount of data like the following:
public sub ProcessWorkItem(byval state as object)
Dim originalState as CustomStateInfo = CType(state, CustomStateInfo)
'Do stuff
[Code]....
This of course will bomb out if we have more than 64 items/threads being placed on the ThreadPool.
So, how would one process say x amount of items until there are no more items left to process?
View 30 Replies
May 22, 2012
I have spent way too much time trying to sort this little issue out. I have narrowed down the issue to the exact procedure that throws the error. Yes, I have used Google..
Try
Dim tempSource as String = Nothing
Console.WriteLine("Loading document...")
[code]....
I am loading a text file, that contains about 1100 lines, and each line is going to be processed with HTML Agility Pack. From what I can tell, when it runs "doc.loadhtml(richtextbox1)", it throws the error. I also have tried to load the file into a string, and load the string with "doc.loadhtml(thestring)". It doesn't make a difference, still errors.
Here are is a sample of how each line looks:
<Site Index="" Name="" Group="" PR="" />
<Site Index="" Name="" Group="" PR="" />
[code]....
I am using HTML Agility Pack, however the above is what is on every line, about 1100 lines! For testing, I have a smaller text file made of about 50 lines before I load up the 1100 line file ;) There aren't any HTML, HEAD, or BODY tags! They aren't needed for my parsing. I am using HTML Agility Pack because it is easy to parse elements with. I can grab each value easily from each line.
I am not sure if maybe the error is because it technically isn't HTML? Meaning since the loaded code doesn't have an HTML or BODY tag, that it errors? I wanted to get this question posted, and while I am waiting on some answers, I am going to parse the document another way. Just curious as to what the deal is and why HTML Agility Pack isn't working. More of a proof of concept then anything, for my own learning and knowledge.
Here is the error I get (btw the on the doc.load() line, is where it throws the exception):
Object reference not set to an instance of an object
Last Note: The routine is on a background thread. I have used multi-threading before, and have delegates created for deeper in the code.
View 1 Replies
Apr 19, 2010
I created a program that watches about 10 folders for different excel files. Using the filesystemwatcher with filters in place and correct error handling, it still misses some files once in a while (that's ok I guess).Anyways, I'm writing this because I added another form that has a filesystem watcher, when I tried to load the form I got a stack overflow error - an error that isn't debugged (a greenish line that you can only stop debugging).Am I going about this a wrong way? Is filesystemwatcher unreliable with large amounts of processing?
View 1 Replies
Feb 18, 2012
I've been trying make a mdi notepad that can start up new instances of a "note" which is unique from the other notes as in you can save/change/cut/ copy/ paste in the individual notes without changing the properties of the other notes..something like a tabbed notepad but instead of tab control i have a mdi container. but i can't make it work. [code] problem with it is that whatever you cut/copy/paste in one mdi container richtextbox, it automatically cuts/copies/pastes in the other richtextbox controls in the other containers..
View 2 Replies
Jan 6, 2010
2008 Array Processing and Sequential File Processing
View 14 Replies
May 19, 2011
Im a college student and this is my first programming class, i am having extremely diffcult time with arrays and sequential file processing. Im not asking for the whole program, just something to get me started and hints along as i progress with it. Please help me get started on my program, its due in 2 days.
Here are the requirements....
1. The program must input any number of individual�s last and first names using two separate textboxes.
2. The array of names must be sorted by the last name using a bubble sort. You must code the sort.
3. The program must be able to recall the names from the file and add to the existing list of names so that more names can be added to, sorted, and written back to the file in sorted order.
4. Sort in ascending order: A to Z
5. All names must be displayed in a listbox in sorted order when the user wishes to see them.
6. In the listbox the last and first names must be separated by a comma and a space. Example: Smith, Mary
7. The user must be able to search for a name in the array, using the binary search algorithm. You must code the search.
8. Do not use module-level variables. Instead you may choose to use Static.
9. The program must be designed using Visual Basic 2008
View 3 Replies
Nov 24, 2009
Is there something like a doc.GETITEMVALUE("Attachment")(0) ?Also, I can't find any documentation for the domino API. Does anyone have a good resource for this?
View 1 Replies
Mar 28, 2011
As part of my current project for making student's lives easier by making an All-In-One application with many common programs carbon-copied inside it, I have a slight problem with sticky notes.
I am trying to recreate Sticky Notes as much as possible from the Windows 7 Sticky Notes Application. My problem is, I put a richtextbox on the sticky notes panel and wanted to either add a background image, or a transparent backcolor (my Panel that the textbox is in has the background image of the themed sticky notes). So my question is, is it possible to somehow dynamically make a property to allow the backcolor of a richtextbox to be transparent? or allow a background image?If you find an answer helpful, click the Helpful button. If you find an answer to your question, mark it as the answer. [URL]..
View 12 Replies
May 12, 2009
I got this code to get alll the notes loaded
Private Sub Load_History()
Dim myCnt As Integer
Dim myStr As String
[code]....
It displays 10 latest notes for me, but I also want it to display the name from the same row as notes.
View 4 Replies
May 18, 2009
I am looking on how to split data I take from a database. Because I got a database that stores Date/Time and Notes all in one record, is there any way I could Split it into date and notes when it reaches my application.
View 2 Replies
May 6, 2009
Look at the code. all i need to do is take all notes from orders table.
The connection is openned
Private Sub Load_History()
Dim myCnt As Integer
Dim myStr As String
Dim totalrows As Integer
Dim myDataset As New DataSet
[CODE]...
View 3 Replies
Apr 18, 2009
What I need to know is if there is a way to combine forms. What I mean is, that when the program is open there is only 1 item on the toolbar instead of multiple shown on the toolbar. For example, I open the main app. and click on notes. The notes would open another form, but I wouldn't want another item on the toolbar, just the main 1, and if the X is pressed on the second form, it should just close that form, not the whole program. I mainly want this so that all the forms will minimize at once... and won't have the extra clutter of all the forms having a separate item added to the toolbar. So simply, I want 1 main form shown on the toolbar and when multiple forms are opened from the same project, it doesn't add to the toolbar and just keeps the one main tool bar.
View 2 Replies
Oct 29, 2009
im trying to write a queue window for an app... here is what i need to happen.on the form:4 listboxes that aren't visible to the user, 1 column each 1 listview with three columns: type, output file and status 7 buttons including: start, pause, abort, remove, open, save and clear when the user clicks start i want it to process all the items that are marked as ready in one of the listboxes, lstStatus.i was doing this with...
Dim count As Integer = lstStatus.Items.Count()
Dim ready As String = "Ready"
Dim i As Integer = 0
If count > 0 Then
[code].....
lstCommandLine is another one of the listboxes. i need to get the index of the lstStatus item that the loop is working on now which i will store in i. ill need to change the listview subitem from ready to complete and the lstStatus item from ready to complete as well. im guessing that would be in the same loop.
View 14 Replies
Sep 15, 2009
the hex convert code seems to work etc but it freezes but it does its job eventually I read that backgroundworkers can be used to fix this issue but I have no idea how to use it for my script
[Code]...
View 2 Replies
Apr 18, 2011
Rather complicated question here. I am improving the text coloring in my custom RTB ontrol, and it is pretty simple:Quote:1. Disable drawing (SetDrawing(False))2. Get current selection
3. Select lines to colorize4. Process selection RTa Font object.
View 2 Replies
May 8, 2009
I am creating an application for learning purposes. I am using this: process.start("iexplore.exe"); That is working fine. However I would like to be able to tell when the page has been loaded all the way. I would like to know how to tell if the application is done processing or not, that is my main goal. If using the webbrowser control you can use the webbrowser documentcompleted event.
View 10 Replies
Jun 9, 2011
I want to write a program to do Markov chain, but my states are quite large. First of all I calculate all the transition probabilities and revenues for all states(1381860 total states), and store in a multidimensional array. Public RevArr(0 To 9, 0 To 750, 0 To 282) As Long
After that the iteration of markov chain should use these as inputs to calculate the steady-state probabilities. But when I try to run the main code I got this error.Exception of type 'System.OutOfMemoryException' was thrown.
The following is the declaration of second array I add just another dimension for storing all the iterations, but I get this error. Dim stateprob(IT + 1, 0 To 9, 0 To 750, 0 To 282) As single
View 1 Replies
Mar 15, 2011
as seen in picture I have in "TextBox1" some numbers and I would like to have a detailed information on "TextBox2" (marked with red) when I pressed the "Process" button about them. In other words, I want the application to tell me how many numbers in total are inside "TextBox 1" and also to tell me if there are some duplicated numbers if it finds some of course?
View 1 Replies
Jun 22, 2010
I wish to add a progress bar in code. I have a sample here but with the "Cursor.Current = Cursors.WaitCursor" to notify the user that it running.. however a progress bar maybe can make it more noticeble. how can i do that.
Private
Sub CmdOK_Click(ByVal
sender As System.Object,
[code]....
View 2 Replies
May 29, 2009
I use a SqlDataAdapter to fill a DataTable and then set that DataTable as the DataSource for a DataGridView. All works well. Then I add a column at the beginning of the DataGridView that will allow a user to check/uncheck a row for further processing. All works well. Then I display this to the user. All works well.
Since there are many times when the DataGridView could be displaying hundreds or maybe thousands of records, I have a button that will "Check All" records and another that will "Clear All" records. These work fine, but I've noticed a serious performance lag. Other test code that I've got shows that in an unbound DataGridView, even a large one with 50+ columns and 5000 rows, checking or unchecking all of these fields takes mere fractions of a second. (One test with 50 columns and 50,000 rows still only takes 0.334 seconds to check all of the rows.)
In my testing (with my current code), checking/unchecking 500 rows takes 15 seconds. Is this because the DataGridView is databound? If so, is there a way to UNbind it (making it simply a stand-alone set of data)? I don't need to push updates back to the server, so there's no danger in removing any databinding. I've even toyed around with this (to make the DGV unbound):
[Code]....
View 4 Replies
Aug 28, 2009
I have an app with 4 buttons that each generate a random number into textbox, before this number is entered i would like to have a progress bar at the bottom, well show that its processing basically.
View 4 Replies
Feb 12, 2009
In Form1 there are a lot of boxes like checkbox, label....I want to show a processing message for opening serial port after program running. So I created Form2 specifically showing "Opening Port...". So in Form1_Load() I used Form2.Show(). However this message showed behind of Form1. I think this was executed before all the other tool boxes loading. So where should I put Form2.Show()?
View 2 Replies
Oct 7, 2009
Where can i find the following notes on the internet (MIDDLE) C,D,E,F,G,A,B,C,D C #, A G #, A B#, G F# ????? ITS FOR A PIANO im making for school, ON SCREEN :) ADDITIONAL NOTES:DOWNLOADALE I like..... Understandable Answers 1 2 3 4 5 - - - - Rate yourself And Have A Kitkat 5 5 5 5 5?
View 1 Replies
Oct 16, 2009
So I can encrypt small files using Des Encryption, but whenever I try encrypting large files, The program's memory usage skyrockets! Would anybody be able to get me some code that will let me encrypt large files (It doesn't have to be Des, but I need to be able to support any length password).
View 1 Replies
Mar 12, 2012
I want a method of dealing with very, very, very big numbers (potentially a million digits). It is very cumbersome to deal with very big numbers in VB, would another language perhaps be better for that?
View 10 Replies
Mar 2, 2010
I have a listview control in my form which contains 44 columns. When user clicks on particular node in the 'tree view' it loads corresponding records to the listview. If the number of records is less then it works fine, but if there is more number of records then it takes more time to load(very slow).
View 4 Replies
Jun 27, 2009
I haven't programmed for some time, so I'm a little rusty Basically I'm storing HTML within a variable, and I need to count the amount of times a specific element appears e.g. <h3 class=r> for now.
I thought of using a for each loop, and passing the string above into the parentheses of the loop (using a variable ofc) however for many reason's, I don't think this has a chance of working (won't bother explaining why, as I assume you can guess). Then thought of using the .Contains method of the string class, but I simply can't think of how to use it with what I'm trying to do.
View 2 Replies
Mar 15, 2012
I have a large text file which I want to split into many different items.
On the next file I have a time between each item it's like this
01:20 a.m.
01:44 p.m.
In between these items is information like you would see in a log file.
How can I split these items like this?
View 13 Replies