How to use multithreading to access sensor data?

I'm trying to access sensor data on another thread but keep getting error - No overload for 'OnSensorChanged' matches delegate 'System.Threading.ThreadStart' What am I doing wrong?
        public string str
{ get; set; }
        public void OnSensorChanged(SensorEvent e)
            if (e != null)
                 str
= e.Values [2].ToString("0.0");
        public void button_OnClick (object sender, EventArgs eventArgs)
            Setup setup = new Setup();
            Thread newThread = new Thread(new ThreadStart(setup.OnSensorChanged));
            newThread.Start();
            newThread.Join();
            newThread.Abort();
                   _text.Text = str;

Hi Kringle,
>>No overload for 'OnSensorChanged' matches delegate 'System.Threading.ThreadStart'
This exception indictates that the method signature for OnSensorChanged does not match the signature defined by a ThreadStart delegate. You need to pass a SensorEvent object into this method, for example:
Thread newThread = new Thread(setup.OnSensorChanged);
newThread.Start(new SensorEvent());
Reference:
https://msdn.microsoft.com/en-us/library/system.threading.parameterizedthreadstart%28v=vs.110%29.aspx
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.

Similar Messages

  • How to use JAPI to Access Essbase 6.5

    Do anyone knows How to use JAPI to Access Essbase 6.5?
    I was told to install Enterprise Services 7.3.1.10.
    But when I test eds samples, I can connect Essbase but can not get data from Essbase.
    Need to change another Enterprise Services(I was told 7.3.1.10 is the latest version), or do some config in 7.3.1.10.
    Thanks a lot in advance

    Gee is correct. You will need to use EAS 7.x to add an analytic server. You will also have to do a few other tasks such as synch'ing security, etc.
    Further, as you are not accessing the exact same version of Essbase as your version of EDS, there is a property setting you will have to change to be successful. In eds\7.1.3\bin, open essbase.properties and modify the server.olap.direct setting to set it to false. What this setting does is forces EDS to use it's own private set of C API files and to use them for all calls to Essbase. Otherwise, EDS will attempt to use pure Java calls to the server. Unfortunately, the pure Java calls were implemented in an 'evolutionary' manner so every Essbase version got more calls until sometime in the System 9 timeframe. By the time 9.3 shipped (and maybe before, I would have to check), all calls the server are pure Java and that property setting is no longer available.
    Tim Tow
    Oracle ACE
    Applied OLAP, Inc

  • How to use a query in matrix data retrive

    hai  everybody
    how to use a query in matrix data retrive...
    pls ..

    If u have created a UDT to store the data then U can retrive the data through recordset.
    oRecordset.doquery("SQL Statement")
    If u have taken the DB Data source to Manipulate then
    then type
    oMatrix.flushtoDataSource
    then
    U can retrive the data through DB Data source.
    -Manmath

  • How to use Bind Variables in Essbase data control

    Hi,
    I am trying to use Bind Variables in MDX query while creating the Essbase Data Control. I have used the below query with the Bind Variable.. this query is working in Essbase admin console..but it is throwing error (*Invalid MDX Query)* while creating Essbase Datacontrol in JDeveloper.
    MDX Query : SELECT {[Measures].Msr_2} ON COLUMNS, [Time].Children ON ROWS FROM cube
    where ($name)
    Could any body suggest me on how to use bind variables with Essbase Data control.
    Thanks,
    Swathi

    Hello Swathi, can you please help me how you created Essbase DataControl? Also were you able to figure out this?
    Thanks, Praveen.

  • How to use Director 11.5 ByteArray data in to Flash ByteArray ?

    How to use Director 11.5 ByteArray data in to Flash ByteArray ?

    Did you configure it in Window / Preferences / Flash Builder / Installed SDKs?

  • How to use multithreading for asynchronous operation

    hi! i am really new to java, i want to improve the performance of my code, some suggested to implement asynchronous operation using multithreading. Please help me how to use multithreading for asynchronous operation. thanks in advance.

    http://java.sun.com/docs/books/tutorial/essential/threads/
    Note, however, that just making something multithreaded won't necessarily improve performance. You either need multiple CPUs or there needs to be some I/O going on that blocks while something else could be done--other I/O or computing.

  • Hi experts, how to use open sql to read data from one " maintenance view"?

    i want to use this part of data within report ,so how to use open sql statement to read data from one " maintenance view"?

    Hi
    You can't use OPEN SQl statements to fetch data from maintenance view
    You have to use only Database views
    see the different types of views and the difference
    The followings are different types of views:
    - Database View (SE11)
    Database views are implement an inner join, that is, only records of the primary table (selected via the join operation) for which the corresponding records of the secondary tables also exist are fetched. Inconsistencies between primary and secondary table could, therefore, lead to a reduced selection set.
    In database views, the join conditions can be formulated using equality relationships between any base fields. In the other types of view, they must be taken from existing foreign keys. That is, tables can only be collected in a maintenance or help view if they are linked to one another via foreign keys.
    - Help View ( SE54)
    Help views are used to output additional information when the online help system is called.
    When the F4 button is pressed for a screen field, a check is first made on whether a matchcode is defined for this field. If this is not the case, the help view is displayed in which the check table of the field is the primary table. Thus, for each table no more than one help view can be created, that is, a table can only be primary table in at most one help view.
    - Projection View
    Projection views are used to suppress or mask certain fields in a table (projection), thus minimizing the number of interfaces. This means that only the data that is actually required is exchanged when the database is accessed.
    A projection view can draw upon only one table. Selection conditions cannot be specified for projection views.
    - Maintenance View ( SE54 )
    Maintenance views enable a business-oriented approach to looking at data, while at the same time, making it possible to maintain the data involved. Data from several tables can be summarized in a maintenance view and maintained collectively via this view. That is, the data is entered via the view and then distributed to the underlying tables by the system.
    Please have a look at below link. It will help you.
    http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ed06446011d189700000e8322d00/frameset.htm
    for more detailed info look on:
    http://www.sap-img.com/abap/what-is-the-different-types-and-usage-of-views.htm
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/home/abap+dictionary&
    Reward points for useful Answers
    Regards
    Anji

  • How to use rescuecd to access NAS200 RAID drives

    I have been lurking trying to figure out how to access my NAS200 drives after a power supply failure and of course I have no backups, relying on the RAID to create my two copies.  (Lesson learned)
    I have a NAS200, with two Western Digital 1TB Green hard drives.  They are configured in a RAID 1 mirror and they are in a journaled file system
    So from what I've been reading, I believe they are in XFS. and I can use the rescuecd iso to access the drive directly to copy them off onto another drive.
    I am using Windows XP SP3.   The computer system is 8 years old - a Dell Pentium 4 Dimension system with 4GB of memory.   I do have Ubuntu, but I have no idea how to use Linux, and definitely not the command line that the rescuesystemcd drops me into.
    I've taken one of the drives and installed it in an external USB drive and plugged it in the system.
    In Windows XP SP3, I can see the drive on my virtual file manager and I can see the three partitions, one main data partition, the configuration partition and the swap partition, but of course it's not the right file system. and it's not ext2/ext3  so Ext2IFS will not work for me from what I've read.
    In ubuntu 11.10, when I've plugged in the external drive, I have no idea how to access the drive.   I suspect I have to mount it, but I have no idea how to do it or even where to begin looking for it to access it. 
    And of course in the CLI using the systemrescuecd, I am completely lost there:   The last CLI I used was MS-DOS from over 15-18 years ago.   I can ls (MS-DOS dir) and cd to navigate the folders of the file system and I believe cp is copy? and if I was using the Ubuntu CLI, I have to sudo everything I believe.
    So after this long post, what am I asking for?
     - How do I mount the external drive in either Ubuntu or the system rescue CD iso.
     - Can I mount a second external drive with a NTFS file system in Ubuntu or the system rescue CD?
     - I would prefer to do it in Ubuntu or some other graphical method so that I could just drag and drop from one disk onto another or failing that using the commandline, what command would copy the entire drive's file system from one to another?
    Thanx

    Are you able to access the web interface of NAS200 using its IP address? If, 'yes' then unplug both the hard drives? Reset NAS200, reconfigure it and connect the drives again. See if that helps.

  • How to use selectOneList in a updateable data table column

    Hi,
    Could someone tell me how to use selectOneList (source from a vo X) in an updateable data table column (from another vo Y)?
    I successfully created a page with the data table. However, strange things happened:
    1) the values populated on the selectOneList column don't match the underlying value in vo Y. in fact, every rows in the column got the same value.
    2) when I update one of the rows, the column value in every other rows turns to the new value.
    3) when I sort other columns in the table, the values shown in the selectOneList column get toggled between blank and some incorrect value.
    I believe it is something related to the fact that the same iterator is used to the source view object. If this is the case, how can I solve it?

    See #7 here:
    http://radio.weblogs.com/0118231/stories/2005/06/24/jdeveloperAdfScreencasts.html

  • How to use Javamail for accessing additional mailboxes -IMAP, Exchange 2010

    hi,
    I want to access a shared mailbox (NOT FOLDER) via Javamail API (1.4.5) using IMAP(s) with plain logon. The mailserver is a Exchange Server 2010.
    User: user1 ([email protected])
    pwd: xxxx
    shared mailbox: [email protected]
    Properties:
    mail.imaps.socketFactory.port = 993
    mail.imaps.starttls.enable = true
    mail.imaps.socketFactory.class = javax.net.ssl.SSLSocketFactory
    mail.imaps.socketFactory.fallback = false
    username = [email protected]
    password = xxxx
    I´ve managed to get access to the user1 - mailbox:
    Session session = Session.getInstance(properties, new ExchangeAuthenticator(username, password));
    session.setDebug(true);
    Store store = session.getStore("imaps");
    store.connect(imapHost, username, password);
    --> this works just fine! But now i want to access the additional mailbox by changing the login-String:
    [email protected]/shared_MB (user@domain/additional_MB)
    --> unfortunately I´m getting an "NO AUTHENTICATE" message:
    DEBUG: setDebug: JavaMail version 1.4.5
    DEBUG: getProvider() returning javax.mail.Provider[STORE,imaps,com.sun.mail.imap.IMAPSSLStore,Sun Microsystems, Inc]
    DEBUG: mail.imap.fetchsize: 16384
    DEBUG: mail.imap.statuscachetimeout: 1000
    DEBUG: mail.imap.appendbuffersize: -1
    DEBUG: mail.imap.minidletime: 10
    DEBUG: trying to connect to host "host.domain.com", port 993, isSSL true
    * OK The Microsoft Exchange IMAP4 service is ready.
    A0 CAPABILITY
    * CAPABILITY IMAP4 IMAP4rev1 AUTH=NTLM AUTH=GSSAPI AUTH=PLAIN UIDPLUS CHILDREN IDLE NAMESPACE LITERAL+
    A0 OK CAPABILITY completed.
    DEBUG IMAP: AUTH: NTLM
    DEBUG IMAP: AUTH: GSSAPI
    DEBUG IMAP: AUTH: PLAIN
    DEBUG: protocolConnect login, host=host.domain.com, [email protected]/shared_MB, password=<non-null>
    DEBUG IMAP: AUTHENTICATE PLAIN command trace suppressed
    DEBUG IMAP: AUTHENTICATE PLAIN command result: A1 NO AUTHENTICATE failed.
    javax.mail.AuthenticationFailedException: AUTHENTICATE failed.
    I was able to get access with Thunderbird and also with the Exchange OWA-Client, so I think there is something missing in my code...
    or is it just impossible to get access to a different mailbox using javamail and plain-auth?
    Thank you in advance.

    Thanks bshannon, that was a great idea!
    I haven´t found an solution yet, but I have maybe identified the real problem:
    Here is some interessting Thunderbird - Logging stuff:
    744[7161040]: try to log in
    744[7161040]: IMAP auth: server caps 0x1187235, pref 0x1006, failed 0x0, avail caps 0x1004
    744[7161040]: (GSSAPI = 0x1000000, CRAM = 0x20000, NTLM = 0x100000, MSN = 0x200000, PLAIN = 0x1000, LOGIN = 0x2, old-style IMAP login = 0x4)auth external IMAP login = 0x20000000
    744[7161040]: trying auth method 0x1000
    744[7161040]: got new password
    744[7161040]: IMAP: trying auth method 0x1000
    744[7161040]: PLAIN auth
    744[7161040]: 7082000:xmail.domain.com:NA:SendData: 2 authenticate plain
    744[7161040]: ReadNextLine [stream=7ec9e88 nb=3 needmore=0]
    744[7161040]: 7082000:xmail.domain.com:NA:CreateNewLineFromSocket: +
    744[7161040]: 7082000:xmail.domain.com:NA:SendData: Logging suppressed for this command (it probably contained authentication information)
    744[7161040]: ReadNextLine [stream=7ec9e88 nb=27 needmore=0]
    744[7161040]: 7082000:xmail.domain.com:NA:CreateNewLineFromSocket: 2 NO AUTHENTICATE failed.
    744[7161040]: authlogin failed
    744[7161040]: marking auth method 0x1000 failed
    ---> okay, so PLAIN AUTH is failing.....
    744[7161040]: IMAP auth: server caps 0x1187235, pref 0x1006, failed 0x1000, avail caps 0x4
    744[7161040]: (GSSAPI = 0x1000000, CRAM = 0x20000, NTLM = 0x100000, MSN = 0x200000, PLAIN = 0x1000, LOGIN = 0x2, old-style IMAP login = 0x4)auth external IMAP login = 0x20000000
    744[7161040]: trying auth method 0x4
    744[7161040]: got new password
    744[7161040]: IMAP: trying auth method 0x4
    744[7161040]: old-style auth
    744[7161040]: 7082000:xmail.xmail.domain.com:NA:SendData: Logging suppressed for this command (it probably contained authentication information)
    744[7161040]: ReadNextLine [stream=7ec9e88 nb=23 needmore=0]
    744[7161040]: 7082000:xmail.domain.com:NA:CreateNewLineFromSocket: 4 OK LOGIN completed.
    744[7161040]: login succeeded
    --> okay, so Thunderbird is using "old-style IMAP login" and is successful.
    Unfortunately I have no idea what that actually means or how to use it in Javamail (is it even supported?). Any suggestions?

  • How to use event structure of event data nodes event filter nodes in programming

    hi,
    I need manual of how to use 'event structure' events of 'event data nodes' and 'event data filters'...please help me....
    Regards
    Ravindranath

    I'm not really sure what you are looking for here.  Did you do a search in the LabVIEW help for Event Structure?
    The Event Data Node just returns information about the event, like control data, control reference, what caused the event, etc.
    The Event Data Filters are just used in Filter Events.  This allows you to discard an event or change the data that the event will recieve.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • How to use text in condition master data?

    I want to copy text automaticlly from condition master data to sales order, but it seems impossible.
    How can I reach my purpose?
    In addition, I found it seems impossible to copy text from delivery note to Billing.
    Why and how to realize?

    hi,
    Can u tell me why do u want to copy text , means , do you want to print somewhere ?
    I have one alternate method , just try it,
    Use the Customer master - General data - Control data - Group key  --- where u can freely define any object ,say ABC , the same can be verified in all stages like sales order , delivery and billing as customer is flowing . Based on this object maintain your text in SO10 and call the same through the function ' READ_TEXT ' wherever you want.
    saravanan

  • How to use jacob to access a com object with coldfusion7

    i want to use jacob to access a com objcet with coldfsuion7(i
    just want to do a test)
    how to do?
    Thank a lot!

    Flashcqxg wrote:
    > i want to use jacob to access a com objcet with
    coldfsuion7(i just want to do a test)
    > how to do?
    you don't. use createObject():
    mailer=createObject("COM","CDONTS.NewMail");
    http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=cfobject_08.html

  • How to use one form to submit data to 2 tables on mysql

    Can someone please help me on this,
    I am developing a jsp website and I want to use one form to submit data to 4 tables on mysql database and the tables are related by one foreign key.
    Can someone bail me out of this ....I've hit a hard brick wall!!!!...

    kwesij wrote:
    Can someone please help me on this,
    I am developing a jsp website and I want to use one form to submit data to 4 tables on mysql database and the tables are related by one foreign key.
    Can someone bail me out of this ....I've hit a hard brick wall!!!!...What's the problem? What does a brick wall look like?
    Connect to the database and execute four SQL INSERT/UPDATE statements as a single unit of work. The fact that you have one form shouldn't be an issue.
    I'll bet you're having trouble because you haven't layered the problem either in code or in your mind.
    I'd recommend that you write a POJO to take in some objects and execute the SQL. Once you have that running successfully you can worry about the form. Decouple the two.
    Computer science is all about decomposing large problems into smaller ones.
    %

  • How to use BEX query in BI data archiving?

    I see some power point presentations about  the use of BEX query in the archiving customizing setting.
    But the presentations have no text about the details.
    Can somebody help detail how to use BEX to customize archiving objects?
    Thanks!

    Yeah I would be interested in such a solution as well.
    Can anyone help here?
    Cheers,
    Andreas

Maybe you are looking for