Multithreading - Multiple SyncLocks If Want To Lock Multiple Things?

Jan 26, 2011

My question is, imagine I have two List(Of T) objects and a subroutine in a multithreaded environment that modifies both of these objects. I don't understand locks very well, so I'm unsure whether I can just do:

SyncLock CType(List1, IList).SyncRoot
List1.Clear()
List2.Clear()

[code]....

View 2 Replies


ADVERTISEMENT

Get Things To Print On Multiple Pages?

May 29, 2011

I am trying to get things to print on multiple pages. I am just printing the same thing over and over with slightly different values. At the moment the print out is only one page and it overwrites it's self. How do I make a page break?

Private Sub PrintDocument1_PrintPage(ByVal sender As System.Object, ByVal e As System.Drawing.Printing.PrintPageEventArgs) Handles PrintDocument1.PrintPage
' Set up earnings statement information and send to graphics page object.

[code]....

View 4 Replies

How To Open Multiple IE (multithreading)

Jun 22, 2010

what i did was i use a select statement in opening multiple IE just for testing but the main function is what you put number on a textbox then the number the IE's will open for example i put 100 on textbox then when i click a button then 100 IE's will open so if im going to use select statement when opening 100 IE my code will be crazy... heres my sample code..

[Code]...

View 2 Replies

.net - Multiple Notification Icons Appear When Using Multithreading

May 13, 2011

Context: I'm working with a relatively simple winforms application, written in VB.NET on the .NET 3.5 framework in Visual Studio 2010. Issue: The FormLoad event creates two threads when the program is opened. One handles automatic update checking and the other performs a time consuming task syncing files with the internet. These threads are initialized as follows:

[Code]....

View 2 Replies

Multithreading - Running One Sub Multiple Times At Once

Jul 17, 2011

I have one Private sub that runs in a loop. I want the sub to run multiple times at once. For example the program runs, you press start; you run the program again and press start, again and again... the same program doing the job at once. now i just want one program do to it alone. But i would like it to be user defined. exp. run program. type in a text box 10. press start. and it works as if 10 of them work open working on the same thing.

[Code]...

View 1 Replies

Multithreading - Code For Running Multiple Threads?

Apr 17, 2010

How to I run multiple threads in VB.NET? Say I need 2 threads - one that prints 100 numbers in a loop and the second one that asks for the user's name and prints it inside a message box.

View 1 Replies

Run Multiple Funcations Simultaneously Using Multithreading Concept?

Jun 6, 2012

How to run multiple funcations simultaneously using multithreading concept?

Actually i am making a software which has backend tool as MS ACCESS. it has 15000+ records in database and i need to display that records as my software loads..but it is much time consunable and sometimes it even goes out of time exception

View 7 Replies

VS 2008 Download Multiple File's Using Multithreading?

Jun 2, 2011

vb
Public Class download
Public Event AmountDownloadedChanged(ByVal iNewProgress As String, ByVal rowno As Integer)

[Code].....

How I can download Multiple file's using multithreading and

How I will display progress report in Datagridview Column ("Progress")

View 9 Replies

Locking Multiple Sections Of Code With Same Lock?

May 30, 2011

I have 3 web methods in a WCF, called 'DeleteGroup', 'AddGroup', 'ModifyGroup'.Each method has its own code. I want to place a lock on code within each method, so that only one method executes at a time. For example, if 'DeleteMethod' is being executed then no request for 'AddGroup' or 'ModifyGroup' can be executed. So may be I could use something like what is below, but not very sure ? Also, where in the WCF would I declare the locker object, and would it be private, public or static (i.e. shared)?

SyncLock locker
--Delete Method Body
End SyncLock

[code].....

View 3 Replies

VS 2010 : Make A Form With Multiple Buttons Opening Different Things Than Having A Form That Has Lots Group Boxes For Each Tab?

Jul 25, 2011

Is there a better way to make a form with multiple buttons opening different things than having a form that has lots group boxes for each tab. So in the begining each box will be invisible and when you click the button the corresponding group box will become visible. Is there any other way?It will be like a background image and it'll have buttons that will mask it with invisible buttons. when the button is clicked it will open the corresponding group box.

View 5 Replies

Multithreading - .NET 4.0 Execute Multiple Threads But Threads Are Completed Before Resuming?

Oct 19, 2011

I just had a new, last-minute idea on to take on a task, so I am running to StackExchange for quick help.

What I want to do is execute a series of methods right in a row, each in their own threads. I want the application to wait until all of these threads are completed, after which the program will resume. It also has to use managed threading (thread pool).

What quick examples could you provide to help me along the way? If it's too complex, what things should I know about so that I can Google it on my own?

View 1 Replies

.net - One Dataset With Multiple Results Sets (multiple Select Statements) SQL Reporting Service?

Oct 15, 2011

I have a question regarding the dataset usage in Reporting Services. I have a stored procedure which returns multiple select statements (result tables), and I created a Dataset in Reporting Services 2005 with this stored procedure. The problem is that I can not reference the second or third result table, and I can only use the first select statement fields. Is this the limitation on Reporting Services Dataset or is there a way to use multiple table results in one dataset?

View 1 Replies

Asp.net - Implement Security Trimming With A Website With Multiple Folders And Multiple Web.config Files?

Jun 18, 2012

I have a website that has highly granulised access and hence requires many web.config files. The problem is I would like to trim the menu so that only certain users will have access to certain folders. I have enabled trimming and setup roles in the sitemap, however when I access the page the menu is not show, as I am authorized to view the default page which is not in a subfolder. When I type the url of a page in sub folder's I have access.

How should I handle this:

A site map for each web.config file - don't know how this will work Removing the sub web.config file to only use a single one

View 3 Replies

Communicate From Client To Server From Multiple Clients On Multiple Requests In Socket Programming?

Jan 8, 2010

I have been struggling to find a solution for this problem. What I need to do is build a server application that accepts tcp client requests from different clients running on same port say:1003. I experimented by using asynchronous mode call backs etc. but it disconnects once connection is established and does not respond for further requests from the same client.

View 1 Replies

Call Sendinput In .net For Multiple Mouse Down Events For Multiple Emulated Mice?

Sep 13, 2011

Iam wanting touse sendinput in a dos or background type app (can be a regular app thats hidden) that emulates mouse clicks and sends mouse moves to another multimouse application. an project that im working on for my school i work at and i need to send the input to it. The overview of the project is i need to have this code be in a service that runs in the background that when a person does a gesture with my kinect code then it clicks the left mouse or sythesis it with sendinput (need mouse up and down sent for this to work). The end programs that receive input are: a program written in the multipoint sdk and mouse mischief. I though about using the default usb mouse driver as an emulated mouse driver to handle the part about creating a usb mouse device that works
since most newer computers are using usb.

View 7 Replies

SQL Performance Timeouts - Adding Multiple Rows In Multiple Tables In The Database

Sep 12, 2011

I have a vb.net web application and when a particular function runs , i get data timeouts in the rest of the application..(ie..row not found errors or column does not belong to table but it does) The function is adding multiple rows in multiple tables in the database and is running in a for loop. It seems to be all SQL related but I am not seeing anything in the error logs in SQL or in the application Right now I am assuming it is memory related where to start note..the for loop will be replaced with a bulk insert but right now I jest need to resolve the issue of the timeouts

View 1 Replies

VS 2008 Return Multiple Table Rows To Multiple Text Boxes

Feb 27, 2011

visual basic 2008 express
access 2007 db

I am attempting to fill a form with multiple rows from an access table based off of a parameterized query. My query works fine but I don't want to return one row at a time, I want to return all rows that match my query in multiple text boxes. I know that I can use a datagrid view to accomplish this, but I would prefer the look of a textboxes on a form. I have read through many books and searched the internet forums but think I may just not know what to search for as nothing has worked yet. Can anyone point me in the right direction. So far I have tried setting the text box value to the row().item(), creating a different dataset for each row, and even setting variables for the results of the query to then be passed to the text boxes. Since none of this work, I don't really have any starting code to post. If I could just get a starting point I could work from there, so don't feel the need to code anything for me, just set me in the right direction.

View 3 Replies

File I/O And Registry :: Listing Multiple Regkeys Under Multiple Keys?

Jun 13, 2012

I am trying to list all printers (PrintersConnections) under all users (HKEY_USERS)

problem is I dont know the user name keys in advance and need to exclude .DEFAULT and *_CLASSES so first I need to list all key names (%usernamekey%) directly under HKEY_USERS then for all keys that lists lsit all keys under HKEY_USERS\%usernamekey%PrintersConnections

Here is the code I have so far but I get errors about object variable not set, I suspect because of the way I doing the for each and listing the key names and then doing it again

Code:
Private Sub DetectPrntrs()
Try
Dim RemReg As Microsoft.Win32.RegistryKey

[Code].....

View 2 Replies

Making An Application That Uses Multiple WebBrowser Controls And Multiple Proxies?

Dec 17, 2009

I am making an application that uses multiple WebBrowser controls, and multiple proxies.The code for changing the proxy settings are as such:

#Region "Proxy"
Public Structure Struct_INTERNET_PROXY_INFO
Public dwAccessType As Integer
Public proxy As IntPtr

[code]....

Note: getRandomProxy gets a random proxy from a list.Problem is that whenever RefreshIESettings(getRandomProxy()) is applied, the proxy will be applied to all of the WebBrowsers, while i would need to have a unique proxy for each WebBrowser. Not having this would just error out the page in the other browsers and so on.

View 1 Replies

Insert Multiple Data With Multiple ComboBox In 1 Click?

Jun 9, 2011

i have a big problem here when i want to insert 6 data into 6 different row in 1 click.
in field @ form it have name, staff no.,items, quantity and date. We can select 6 items to insert which i use ComboBox for save the data in form. In this case, each name can choose 6 items in one time and i want to save it in database just in 1 click. that mean it will put a same name in 6 rows in a table. the look like this but it not complete...

[Code]...

View 6 Replies

Open Multiple Socket Connects To Multiple Servers

Apr 4, 2012

i have a form where i wanted to open multiple socket connects to multiple servers. i defined "clientsocket" as a socket array

[Code]...

View 6 Replies

Select Multiple Objects Like Checking Multiple Checkboxes?

Nov 24, 2010

Is there a tool in the toolbox that i can use that replaces checkboxes. i have limited amount of space and checkboxes just keep taking up room. I need the user to select multiple objects like checking multiple checkboxes.

View 5 Replies

Dataset - Multiple Tables - Multiple Columns

Sep 18, 2009

I have a small project i am doing for work to compare our website catalogue to our actual inventory in our financial software. To do this, i have exported the online catalogue as a delimited text file using "^" as the delimiter. I then want to go into our Accpac data a find out if all the items are still active, the current price and the stock on hand.

[Code]...

View 6 Replies

Display Multiple Records In Multiple Textboxes?

Apr 23, 2010

I would like to display the multiple records in multiple textboxes Following is my tables and data:

tblJan with these data:
col id
1
2
3
col January
10
20
30

now i want to display the value 10 in one textbox and the value 20 in another textbox and so with the value 30 in another textbox..

View 4 Replies

Insert Multiple Data Into Multiple Table Of Sql

Jan 16, 2012

How to insert multiple data into mssql without using loop?

i'm developing a clinic management system, while doctor may give few medicines to patient,therefore i hope inside my database,the data will look like

[Code].....

this is my 2 tables, i hope when storing data ,the recordID will not increase based on how many ItemID inserted.

View 5 Replies

Loading Multiple Pics To Multiple Pictureboxs?

Oct 20, 2010

I have the following html code for some pictures:

<table cellpadding='0' bgcolor='#ffffff' cellspacing='0' style='border: solid 3px #470506;padding-right:1px;'><tr><td><img src='./images/counter/b.gif'></td>
<td><img src="./images/counter/3.gif" border="0"/></td>

[code].....

View 4 Replies

Multiple Textboxes To Multiple List Boxes?

Mar 13, 2012

Okay this is the simple thing I'm trying to accomplish. I can get richtextbox1 to add to listbox 1. but i cant get both to add. the compare works fine. I'm stumped.

View 3 Replies

Pass Multiple Parameters To Multiple Threads?

Sep 15, 2011

I have a loop that creates several threads as such[code]...

View 1 Replies

Printing Multiple Images On Multiple Pages?

Aug 4, 2011

I'm trying to print 2 pages of business cards with different images on each card. When I use the code below it overprints both pages on top of each other.

Private Sub PrintDocument1_BeginPrint(ByVal sender As System.Object, ByVal e As System.Drawing.Printing.PrintEventArgs) Handles PrintDocument1.BeginPrint
mPage = 0
End Sub

View 8 Replies

Searching Multiple Files In Multiple Sub-folders

Mar 30, 2010

I'm developing an application to help law enforcement retrieve and analyze logs and other files left by the use of Pidgin (a multi-protocol messenger client). Right now I'm nearly done, but I want to add the ability to search chat logs for user-defined words or phrases and I don't even know where to begin.

Chat logs are stored as html documents in a folder/sub-folder/sub-folder/sub-folder fashion, where each sub-folder can have dozens of sub-folders inside of it, and the final sub-folder can have dozens if not hundreds of chat logs. If anybody could point me in the right direction, I'd be very grateful.

(Also, this is the first program I've written since about 2005, and I'm essentially teaching myself VB as I go. If you'd like to see what I've cobbled together so far, you can find the program here.)

View 1 Replies







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