Passing Data From A Form Back To A Thread

Sep 20, 2010

In a threadpooling situation is it possible for a modal form to be opened and data from that form to be passed back to the thread that opened it ?

View 1 Replies


ADVERTISEMENT

Passing An Amount Back To An Other Form?

May 25, 2009

I have a CheckingAccountForm and a CheckingAccount class. I have 2 variables AmountEntered and TotalAmount. The user enters an Amount and hits the calculate button. So now I send the AmountEntered to the CheckingAccount class where it is added to the TotalAmount and I have to send the TotalAmount back to the CheckingAccountForm so it can be displayed in a textbox. Can someone give me an example on how to do that? I get the AmountEntered to the CheckingAccount Class and managed to calculate, but not sure how to get the TotalAmount back so I can display it in the GUI's TextBox for the TotalAmount.

View 3 Replies

Passing Setting Value Back To Form That Had Called The Form?

Feb 1, 2010

This is what I have..Dim frmSettings As New frmOptionsfrmSettings.ShowDialog(Me)frmSettings is a settings form that you can choose the color for background of form1(Me)

View 1 Replies

Asp.net Mvc - Passing Record Id Into View And Then Getting Back On Form Post

Dec 9, 2011

MVC 3. VB.NET application.. I am trying to pass a id along to keep track of which record a file name needs to be saved in.. The problem is that the id is getting passed into the view but on post back to the controller it is being lost...I have hammered on this for hours now and I am stuck...

[Code]...

View 1 Replies

Multi Forms And Passing A Value From One Form Back To Another Using A Listbox

Apr 12, 2011

Im having trouble passing a value from one form back to another using a listbox... The user clicks a button in the main form to bring up an instance of another form (form2.show). In that form, the user then then selects a number 1-5 and then presses done:

[Code]...

View 2 Replies

Passing Array Form C++ DLL To VB6 Through Call Back Function?

Sep 6, 2005

I need to pass an uint8 array from C++ DLL to VB6 application but I receive always following error: "subscript out of range" if I try to work with the array 'pabyData' in my VB6 procedure. The C procedure is: typedef void (__stdcall *FUNCPTR2SendData) (const uint8_t* pabyData, uint16_t wDataLength); void SendData(const uint8_t* pabyData, uint16_twDataLength) { FUNCPTR2SendData vbFunc; vbFunc = (FUNCPTR2SendData) ptCBFPointers->p2NewDirectDataSMSEvnt; // ptCBFPointers are call back pointers, where is saved the call back address of VB6 functions vbFunc(pabyData, wDataLength); } The VB6 procedure is: Public Sub SendData(ByRef pabyData() As Byte, ByVal wDataLength As Integer

View 2 Replies

VS 2008 Login Popup Not Passing Back To Webrowser Form

Nov 23, 2010

I have created an application that I am using the VB webrowser control. The users needs to login to a site to display a particular webpage. The sites login is in a popup and what appears to be happening is the popup is launching outside my application (has IE in the title). If I enter uers/pass and try to login the information is not being passed back to my webrowser form.

View 5 Replies

Passing Back Lisbox Values When Going Back To Previous Page?

Jul 23, 2009

I have a search page with a couple of pulldowns. Dependig on the values of them I show a grid matching the searched criteria, basically a table with links the user can navigate to. My problem comes when the user wants to navigate back. At the moment I have a "Back" button which simply redirects the user to the initial search page. I think it would be a good improvement to have the values of the pulldowns filled in with the values the user selected, this way when he presses the "Back" button he would not have to restart the whole search process again.

View 5 Replies

Passing Data From One Running Thread To Another Running Thread?

Jan 14, 2011

I have on timer thread that needs to pass every time a different data to another running thread to make the calculations.

View 5 Replies

Call A Method That Started On A Background Thread On The UI Thread Calling BeginInvoke And Passing In A Delegate?

Aug 27, 2011

I am trying to call a method that started on a background thread on the UI thread calling BeginInvoke and passing in a delegate as follows:

Dispatcher.BeginInvoke(Function() UpdateApplicationDataUI())

to call this method:

Private Sub UpdateApplicationDataUI()
...
End Sub

However, I get an error in the call to BeginInvoke (the UpdateApplicationDataUI portion of the delegate is stating "Expression does not produce a value").

Me.Dispatcher.BeginInvoke(Function() New Action(AddressOf UpdateApplicationDataUI))

View 1 Replies

Thread Communication - Return The Information Back To The UI Thread?

Feb 20, 2011

I'm using webclient to download a webpage but obviously since it's on the UI thread it freezes.How can i change my class to be multi threaded using DownloadStringAsync? i can do this normally but since i am needing to return the information back to the UI thread i am a bit stuck

Public Class RequestExecutableInformation

Public Function FileReport(ByVal executable As String, ByVal ParameterStart As String, ByVal ParameterFinish As String) As String

Dim Source As String = String.Empty[code]...

View 6 Replies

Load The Main Form Of A WPF So That A Separate Thread Goes And Gets Data From The Database While The Form Is In An Apartmentstate?

May 15, 2012

How do i load the Main form of a WPF so that a seperate thread goes and gets data from the database while the form is in an apartmentstate? (drag-able / movable) I Know this is possible with opening a new window from your main form like this :

Private Sub openOrderWindow()
Dim OrderWindow As Orders = New Orders
OrderWindow.ShowDialog()
End Sub

[code]....

I've tried putting MyBase.ShowDialog() and .Show() and .9000+ other things The only benefit I've got out of using a seperate thread to load from the databse is i can see the screen right away (as oppose to it being a transparent box until it loads) but i cannot move it around or minimize it?is there any way to make it Movable while it loads?

View 1 Replies

Passing Data To Another Form

Apr 28, 2009

i got 2 forms.there are 2 buttons in the 1st form and what i wan is,when a user click button 1,then will show form 2 will related data,click button 2 will show related data which is different with form 1.so far wat i get is,i oni manage to make when a user click button 1,then show form2 n in d form 2 there is another button to click n get d data...which mean i nid 2 create more forms...erm...u can say that i would like to make the form 2 to become a template...and send data into it.[code]i just wana make like i click button1 in form1,it will pop out form2 wit related data.

View 7 Replies

Passing Data (variable) To New Form

Feb 18, 2010

Doing a small project where I would like to be able to print the results of certain calculations. I want to open a new form where the data can be neatly presented and printed. I just can't seem to make the data get passed along to the new form when I open it..

[Code]...

View 2 Replies

Passing Data Between Form In VB 2008?

Dec 7, 2009

i have two form in vb form1,form2form1 contains button1,textbox1form2 contains utton2,textbox2form1 button1 contains code to show form2 myfrm2 As New Form2myfrm2.ShowDialog()

View 1 Replies

Passing Multiple Data From One Form To Another

Jun 10, 2011

In reference to this post [URL] I have another more specific question about passing data between forms in VB.net I have a form with over 50 variables that I need to access on a second form and if i followed the method above, my form 2 will end up way too long and time consuming. I'm making a complex calculation software that prompts user inputs values and calculates all those unknown variables. I need to display all the resulting values in the 2nd form. and from the 2nd form , i want to give the users an option to export all those values to an ms Excel sheet.

[Code]...

View 6 Replies

VS 2008 : Passing Data From DGV To Another Form?

Jul 8, 2010

I have returned to a project I started a while ago. I have a small members database showing basic info (Title, Forename and Surname) in a data grid view with all data populated from a SQL database. I have the dataset populated with all this info as well as other data through the use of relationships/foreign keys (Addresses and Telephone Numbers, etc)I have tested the relationships using a simple form which shows the correct addresses, telephones, etc for each user as you navigate through it.

I now wish to show just the datagridview on form 1 which is read only with the row select set to full row (I have done all this so far). I have also set up a second form which displayes just the relationship data.I want to be able to load the second form (with the address and telephone number data, etc) when the row is double clicked by the user. ie - if row 15 is double clicked on, then the second form should load the address and telephone number data for record 15.

View 3 Replies

[2005] Passing Data From VB Form To InfoPath?

Mar 4, 2009

how I can pass data from my VB form to InfoPath?

I'd like to have a link on my VB form that will open an InfoPath Form with some information already pre-populated (name, date, etc.) with information that is already filled in on the VB form. I'm pretty sure there is a way to do this, just haven't figured it out yet.

View 5 Replies

Passing Values Back From Threads

May 8, 2009

Can anyone give me the best method of passing back a value from a Thread?I have some procedures that I have set up as threads that I'm starting at the same time.My main function then waits until the threads are done and I'm needing to get back some values that the threads have created.Is there a better way to get these values back rather than just having them set a global variable with the returned value? Also, what is the proper way to wait for a thread to to be completed?I've just got a loop waiting for the Thread. Thread State property to not be in the Running state.So if there is a more proper way to wait for the thread to end I would be interested in knowing it.

View 7 Replies

Passing Selected Data To Another Form And Then Retrieving Details?

Jun 22, 2009

I'm new to Visual Basic 2010, I programmed in VB a long time ago. getting back into it. I have a SQL 2008 database and I want to use Visual Basic 2010. what I want to do is bring up a form with a group of products for my company. Based on the users selection they will put a check mark next to the product and then submit the query/data filter/ selection.passing that information to another screen with the details of all the sales for that item.

View 6 Replies

VS 2008 - Passing Data From WPF Parent To Child Form

Jan 27, 2010

In my WPF Form1 I have TextBlock1 that fill from AddressTableAdapter. To edit address user must click EditButton to open Form2 to perform changes. My problem is passing data to Form2 from Form1. In Form2 I have 3 TextBoxes Street, City, Zip, and StateComboBox. I try to code in Loaded procedure of Form2 like this and got error message:

Private Sub Form2Detail_Loaded(ByVal sender As Object, ByVal e As System.Windows.RoutedEventArgs) Handles Me.Loaded
Me.AddressTableAdapter.Fill(Me.AbcDataSet.Address)
Me.StreetTextBox = IIf(IsDBNull(AbcDataSet.Address.StreetColumn), "", AbcDataSet.Address.StreetColumn))
Me.StateComboBox = IIf(IsDBNull(AbcDataSet.Address.StateColumn), 0, AbcDataSet.Address.StateColumn))
End Sub

View 1 Replies

Passing A Large Text Back To The Server?

Nov 10, 2011

I have a project now where I will have a large chunk of CSV text, like 60 lines or more, and need to pass that from the client to the server. I know it would be weird with GET, but how would I store the multiline text so that I could later split it up, etc at my application?

View 2 Replies

Marshal Back To Main Thread?

Dec 15, 2009

I am using a COM library in my VB.NET app that has an asynchronous execution method and signals my application via an event when it completes. The event handler is on a different thread from the calling thread. I want to invoke another execution on the main thread when I receive the completion event. If I call directly in the event handler for another execution it starts on the new thread. How do I marshal back to the main thread. This is done in a dll not in a form.

View 3 Replies

VS 2008 Passing A Queue To A Thread?

Jan 14, 2011

I've passed object sucessfully to threads in the past but I'm stumped on this one:-

HTML

Public Class TileDownload
Structure RequiredTileDetails
Public MapID As String

[Code].....

View 2 Replies

Yes Another 'Passing Variables Thread"

Jan 7, 2012

VBasic / VS2008 / .NET 3.5 / Meas Studio 8.5 I've searched and seen a number of convoluted ways of doing this but.... What I am trying to do should be simple and in my mind (and from previous experience) it should work. It doesn't At least not after 10 hours of tweaking, editing, researching....

Straightforward project, 3 components - MainModule, MainForm, CNCNoForm. I declare public var NCPgmNo in the module. I open the CNCNoForm from the MainForm. This form has 2 controls - Numeric Up/Down Box & Close Button. I enter a number in the Num box (read only property is set to false), then assign the value to the var. NCPgmNo in the value-changed event sub. I close the form, returning to the MainForm. The variable does not pass even though it is public and declared in the module. I tried removing it from the Numupdown event and assigned the var before 'me.close'. Still N/G.

If I put a breakpoint right after the line that assigns the var, it is correct. It just does not pass to the MainForm. I started with a textbox, then changed to a Meas. Studio Numeric control, finally Numeric up/down. Same results with all 3. I though the CNCNoForm was broken so I removed it from the project and rebuilt it with a new name (yes name references in the MainForm and MainModule are correct). One other thing. If I call the CNCNoForm repeatedly, it reads the previous value. I am ready to give up computers and take up farming or hiking.

[Code]....

View 7 Replies

Threading.thread Addressof Passing Variables

Apr 16, 2012

I am trying to pass some status from a IP call in a shared sub to a label on my form. This is the current code that i am using:

[Code]....

View 1 Replies

VS 2008 Passing A Class Method In A New Thread

May 14, 2010

I am looking for a way to pass a class method into a new thread. On my form I have a few object that contain methods.

For example obj1.doWork.

Now I want to do

Example
Dim t as new Thread
t = new Thread(AddressOf obj1.doWork)
t.start()

However I get an error on this saying:

Error1Overload resolution failed because no accessible 'New' is most specific for these arguments:
'Public Sub New(start As System.Threading.ParameterizedThreadStart)': Not most specific.
'Public Sub New(start As System.Threading.ThreadStart)': Not most specific.

View 11 Replies

Write In Worker Thread In A Data Table And Rich Text Box in Main Thread

Mar 4, 2009

I'm creating a Client Server application which involves theServer running some scripts in clients and getting back results in an automated way. In Server, other than Main thread, i have 2 worker threads, a) one monitoring response from clients and b) the other scheduling next available job to respective client which executes that job. The issue here is ,I want these worker threads to write the status of their work in the UI(which comes under Main Thread). Also i need to write things in worker thread in a Data table and Rich Text Box in Main thread. But, I can't do so, since it has been blocked to access one thread's function or property directly from others. Is there any work around to do this?

View 8 Replies

Send Data From A Windows Form To An Aspx Page And Send Back A Response - Request.Form Vs Request.BinaryRead?

Mar 29, 2012

Im trying to send data from a Windows Form to an aspx page and send back a response. Im running around in circles trying to make this work. The data im trying to send is 4 strings. So fare I have this in my code, using the build-in webclient in visual studio 2010, in the windows form sending to the aspx

[Code]...

View 2 Replies

Dynamically Call A Function With Delegates By Passing A String To A Background Thread?

May 20, 2009

How do I dynamically call a function with delegates by passing a string to a background thread in VB.NET?

Currently my code is this

Public Sub invertImageBK(ByVal image As Bitmap)
Dim snxl As System.ComponentModel.BackgroundWorker = createBW()
snxl.RunWorkerAsync(New ImageProperties(image.Clone, "invertImage", Nothing))

[Code].....

View 1 Replies







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