Get waveform from TDS2012

Hello,
      the attachment is an example whose function is to acquire the waveform from an oscilloscope  from a reference book. Now I'm wondering whether the waveform displayed in the waveform graph is just the waveform the oscilloscope acquires. My oscilloscope is TDS2012. I connect the oscilloscoe probe to the channel 1 input connctor.Attach the probe tip and ground lead to the PROBE COMP connectors.The  PROBE COMP signal is a square wave with a frequency of 1KHz and a peak voltage of 5V. If I choose channel 1 as the trig source, and let the programme run for 1000 times,it will take more than 1minute to complete this task. I just want to know whether the  waveforms  refreshed in the waveform graph are generated by the source during the  1 second since the programme starts.
Attachments:
get waveform from an oscilloscope with VISA function.vi ‏17 KB

Hi yaoyao,
Your question all depends on the behavior of the CURVE? command.  If it generates a new acquisition each time it is called, then you should be seeing 1000 different waveforms.  If CURVE? simply transfers the existing waveform without initiating a new one, you will be transferring the same waveform 1000 times.  The programming manual should have more details about the behavior.  You may need to call
You should look at the LabVIEW instrument driver that we have for this instrument:
http://sine.ni.com/apps/utf8/niid_web_display.download_page?p_id_guid=047216EC20B66FABE0440003BA7CCD...
The instrument driver should simplify programming and you can look at the block diagrams to see which instrument commands are being sent.

Similar Messages

  • Error getting waveform from LT264 by GPIB

    Hello,
    I installed the lclvxxxx driver for LeCroy scope LT264. I tried the example which came with the instrument driver. When I run it I get an error saying
    Error -1074126845 occurred at lcltxxxx Read Waveform.vi
    Possible reason(s):
    Driver Status:  (Hex 0xBFFA2003) Maximum time exceeded.
    Primary Error: (Hex 0xBFFA4001) Invalid instrument response.
    It seems that the example works fine until the moment that the waveform will actually be read.
    Anyone familiar with this problem?
    Thanks,
    Bart.

    Hi Srinivasa,
             What is the error you are getting?Did you try setting in all the values required for the Input paramater fields and structures?
    Regards,
    Uma.

  • How is dt from "Get Waveform Components" calculated?

    I am acquiring data, making waveforms, and writing to TDMS.
    I physically took data for 2 hours and did timed events.
    When I "Get Waveform Components" and determine array size of components I get the following result for data length:
    dt = 0.002 sec/sample (500 hz)
    Array Size of waveform components = 129350 samples
    0.002 x 129350 = 258.7 sec = 4.3 min of total data length
    When I view the waveform in Labview, I see an accurate representation of my timed events.
    It looks like the full 2 hours of data is captured to some degree.
    If I am losing data, does that mean my dt isn't always equal to 0.002 like "Get Waveform Components" says?
    Any other ideas?
    Thanks!

    Waveforms assume a constant dt with each sample occuring every dt.  If you are missing data, then the waveform will show a shorter acquisition time and what you actually took.  Since you claim your times look right, then it is safe to assume you had no data loss.
    DAQmx will give you warnings if you miss data from the DAQ card's buffer (data overwritten).  So if you didn't get a warning about that, then you didn't miss any data.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Derivate a waveform from a Function generator

    I want to use the derivate of a waveform from a Function generator in a Formula node,  but unfortunatelly I dont no how can i do this. I need the exact value of the derivate ("qpg" input variable) to use in the equation in the Formula Node.
    I found a Derivate sub VI, but it gives me the derivate as a vector so i cant wire it as an input to the Formula node.
    I attached pictures about my VI.

    As I understand it, you are using a Waveform Generator VI, and want (in addition to the Waveform) an additional output that is (an estimate of) the derivative of the Waveform.
    If you consider the Waveform Generator as a "black box", something whose internals you don't know, but something that produces a new output every delta-t time increment (I'm going to call this "dt"), then you really do need to estimate the derivative.  Note that since you cannot "predict the future", to estimate the derivative, you need the current data and previous data.  One very common estimate for the derivative x'(t) at time t is (x(t) - x(t-dt))/dt, that is, the difference between the current point and the previous point, divided by the time increment.  For a waveform generator, this will probably be a pretty good estimate, as the data should be relatively "smooth" and noise-free.  Do note, however, that this estimate is really over the time interval t-dt and t, so you could consider it shifted backward in time by dt/2.
    If you want a more accurate estimate of the derivative, one "centered" on the current time, t, then your formula needs to take into account not only the current value and past values but also future values.  This is the reason many "derivative functions" use vectors, as this contains past and present values (with some worry about what to do at the beginning and end of the data).
    On the other hand, if you are generating the data yourself (that is, if you have a VI that you input t and it outputs f(t)) and you have a "nice" function f (say a sinusoid or other non-random function), you can get the "exact" derivative just by programming it.  For example, if f(t) = sin (omega * t), then f'(t) = omega * cos (omega * t).
    Bob Schor

  • Get waveform subset vi lagging

    Hello all,
    I'm running into an issue with a Get Waveform Subset.vi taking an awfully long time to run (~15s). I'm working with a large-ish data set (5431296 data points). I double checked with the Performance and Memory tool and it's defiantly something with this VI.
    The program is suppose to grab a new subset from the waveform and look for a trigger, record where the event happens, then move onto the next subset and repeat. 
    Am I doing something wrong with the VI to make it lag so much? Or better yet, is there a better way to do what I'm trying to accomplish? 
    Attachments:
    Problem with GetWaveformSubset.JPG ‏66 KB

    Hi Lynn,
    What values are you using for Start samples and Duration?
    Start: 333131 initially then it increments depending on where the triggered edge is 
    Duration: 55 samples
    Do you get any errors?
    None that I could see. The Get Waveform Subset vi rounded my duration and start sample values which I was fine with.
    How many iterations does it run. 
    The current code runs ~800 - 900 iteration. 
    So since it last posted, I removed the Get Waveform Subset vi and replaced it with a ArraySubset thinking it would speed things up. Turns out the Get Waveform Subset vi is fairly optimized already...go figure.I also decimated my waveform using the Resample Waveform vi to reduce the number of samples in each subset. By playing with my re sampling interval, I was able to reduce the run time to ~ 3 seconds.
    So here's what I'm actually trying to do and for full disclosure, yes, it is for a school assignment.
    I have a signal from a NOAA satellite that I'm trying to convert into a image. The data is sent using APT format and is not real time, rather just an audio file. I have managed to demodulate the signal and removed the carrier wave and filtered the signal appropriately. What I'm having issues with is detecting synchronization pulses in my signal. Right now, my sync pulse detection scheme involves running a FIR bandpass filter at the sync pulse frequency and then using trigger detection to find where my sync pulses start.
    Am I going about this the wrong way? Is there a more efficient method I should be looking at. 
    Honson

  • Missing Audio waveforms from Project window

    I'm hoping anyone can help me.  I'm trying to customize volume within a range of a song.  I've dragged the audio into my project timeline, however no matter what I try  I cannot get the waveform to appear.  I've tried absolutely everything I can think of including reverting layout of the project window. 
    I've worked with audio in projects before and feel I have a fair bit of experience with it but this one has really baffled me.
    As you can see from the image attached, waveforms from other audio clips are showing up just fine but the song running along the bottom, no workie. 
    Any help would be greatly appreciated.
    FCP X 10.0.5
    ML 10.8.2
    MBA 13inch June 2012

    Karsten Schlüter wrote:
    •you should re-name it (before importing to FCPX) - that "." could cause issues.
    (avoid any characters that have a 'function' in Unix, such as . : / )
    A period only has a UNIX function if it is the FIRST character in the name! (hide file from Finder view), so that is not the issue here. ;-)
    And Tom, why should the audio be AIFF?? I drag mp3/m4a files from iTunes ALL the time, without any issues - FCPX even has a native, build-in iTunes browser, so requiering AIFF seems strange, unless FCPX transcode it when it's dragged in!

  • "Get Waveform Subset": version incompatibility

    Hello everybody!
    I was studing an already developped software and there was something relative to waveform uses that I didn't get it (concretly it was that I didn't know very well what I have to put in the Duration input when I was using the Get Waveform Subset function in the Relative Time mode. Should the duration be "T0 + sth" or just "sth"?)
    Then, to understand it, I tried to simulated it. I was working at the same time with 2 computers with 2 different versions of Labview (7.1 and 8.6). The funny thing is that I created exactly the same VI for the oldest version and the new one, however it only works for the oldest one. When I try to run the new version I get that mistake message:
    "Error -1801 occurred at Start value too large in Get Waveform Subset.VI.
    Possible reason(s):
    LabVIEW:  (Hex 0xFFFFF8F7) Duration input is not an integer multiple of dt. Value was coerced to nearest integer multiple of dt."
    What's wrong with my new Labview version subvi?
    Thank you!!
    Attachments:
    8.6 version.JPG ‏18 KB
    7.1 version.JPG ‏41 KB

    GovBob,  
     Thanks a lot for your solution. Writing zero in the start input it does work.  However there are 2 things I don't understand: 
    1-.Why does it work in the oldest version using the  elapsed second function?Is the output of this function a longer number now? I think it should also work for the newest versions.
     2-.If we can't write a time stamp, what do we have to do to skip the samples of a period of time? If we use like a starting time zero, what is the difference now between the relative time mode and the sample one? 
     I have wondered that, and I have been doing some tests and now I am more confused that before I was. :s  
    First of all, I was thinking: If we don't want to skip the first samples is logical that it does work for zero. I imagined that if for instance our wave starts in the second number 1000, so if we write a number below 1000, we are going to get always samples from the first positions (we could also get samples from other position but the first one would be always in the output wave).However when I wrote a signal, using as a t0 the elapsed second function and dt:1. Then I used "get waveform subset" in the relative time mode, and I set start:1 and duration:1, I got the second sample instead of the first one. (I was expecting the first one for the reason I have already explained) 
    Also, thinking about the behaviour of the function in the relative time mode I have done some test, in order to get a pattern, but I haven't successed. I will attached a file with the ideas got from the tests.
    Attachments:
    subwaveform.txt ‏3 KB

  • HT1349 How do you get help from apple if you don't know where to find the serial number of my "product."  I don't know if they mean my itunes program, my iphone, my computer, which one, the number on the computer (is there one), or something in Windows or

    How are you supposed to get help from Apple if you don't know what your serial number is?  They say to input the serial number of the "product" that you are asking about.  Since my problem is how to deauthorize/authorize computers, and they are saying I have more than 5 (which I have never owned more than 5 computers in my life), I can't imagine what serial number they mean.  Does it mean your desktop computer?  If so, which one?  Do they mean your device?  LIke your iPhone, iPod or whatever?  Do they mean the software ON one of your computers and/or devices?  If so, which program, and on which computer/device?
    We have three operational computers, one does not have iTunes on it.  Since Apple is saying I have more than 5 authorized computers, and I can't imagine what they are, I am afraid to deauthorize all my computers.  See what I mean?  I just wanted to ask the question about how I can find out WHICH computers Apple thinks I have authorized, so I can decide if it's safe to deauthorize them all or not.  I only know of 2 computers that have iTunes on them, so how can there be 5?  We also have 2 iPhones and 2 iPods in this family, but one of the iPhones has his own apple id.  He may have been using mine, since his computer died.  I read that those don't count as "computers" to the 5.  Do they, then?
    Help!  I can't contact apple because I have no idea what they mean about serial number.  I doubt they would help me anyway.  In order to get the serial number off my desktop computer (that has iTunes on it already), I will have to move furniture, so I don't want to if that's not it.  Is there some way to find the serial number in the software, either on my desktop or my iPhone?

    sunshinecowgill wrote:
    We have three operational computers, one does not have iTunes on it.  Since Apple is saying I have more than 5 authorized computers, and I can't imagine what they are, I am afraid to deauthorize all my computers.  See what I mean?  I just wanted to ask the question about how I can find out WHICH computers Apple thinks I have authorized, so I can decide if it's safe to deauthorize them all or not. 
    You could have more 5 computers authorized if you ever, for example, reformatted a hard drive or replaced a hard drive without deauthorizing the computer first. Apple's system would see that as a different computer, even though you don't. There's nothing to be afraid of in deauthorizing everything and the reauthorizing what you actually have. You won't lose any data. Mistimp is correct, they can't tell you which computers are authorized.

  • Is there another way of getting apps from the appstore without putting your credit card number in, ive heard about the itunes gift card thing can anybody just give me more info about that and how i can buy free things free things from the appstorepls help

    Is there another way of getting apps from the appstore without putting your credit card number in, ive heard about the itunes gift card thing can anybody just give me more info about that and how i can buy free things free things from the appstore...pls help as im only a teenager and have no credit credit and my parents dont trust me with theres and they dont care about the fact that you can set up a password/.... PLEASE SOMEONE HELP I WILL BE SO GRATEFUL... And i would really like to get the iphone 4 but if there is no way of etting apps without your credit number then i would have to get a samsung galaxy s3 maybe ...

    You can set up an Apple ID without a credit card.
    Create iTunes Store account without credit card - Support - Apple - http://support.apple.com/kb/ht2534

  • Creating Variable with Replacement Path to get value from ANOTHER Variable

    Hi all,
        Is anyone has created the Variable with Replacement Path to get the value from another User Entry Variable, PLEASE ? 
    First created the User Entry Variable (ZV_X) and it accepts the date range like '01/01/2009 - 01/31/2009'. Next created the Characteristic variable (ZV_Y) of Replacement Path for which source variable will be ZV_X and we should get the 'FROM Date' (01/01/2009) from the selection (ZV_X) into it (ZV_Y).
    While creating the Characteristic variable (ZV_Y) of Replacement Path, I didn't find my newly created ZV_X variable in the list of available variables under 'Variable' header in 'Replacement Path' tab and it is causing the error 'Source to replace variable ZV_Y is not defined'. How could I create the Characteristic variable of Replacement Path for my requirement, PLEASE ?
    The following is from help.sap..com:
    Replace with Characteristic Value
    Text and formula variables with the processing type Replacement Path can be replaced with a corresponding characteristic value. In the variable editor, on the General tab page, you specify under Reference Characteristic the characteristic that is to be referenced by the replacement. On the Replacement Path tab page, you can choose whether the variable is replaced with the From or the To Value and with the Key or the Name of the characteristic value. You can also specify the Offset Start and Offset Length for the output.
    Replace with Variable
    Characteristic value variables, hierarchy variables, text variables, and formula variables with the Replacement Path processing type can take their values from a different variable.
    The following prerequisites need to be fulfilled:
    Variable
    ●      The variable must not be input-ready
    ●      The variable must represent a single value
    Source Variable
    ●      The source variable must not be a hierarchy node variable
    ●      The source variable must be input-ready
    ●      The source variable must be available in the query
    ●      The source variable must represent a single value or an interval
    In the variable editor, on the Replacement Path tab page, you specify the source variable from which the value is to be determined. The value is either determined from the key, the external attribute of the key, the description, or the attribute value. You can specify an Offset Start and an Offset Length for the output here. The variable is replaced on the variable screen upon each data release.
    Thanks,
    Venkat.

    Hi Eve,
    It is possible to connect the 2 queries using a Replacement Path characteristic variable. You would need to create the variable on the char whose values you want to pass from Q1 to Q2. The variable will be of type replacement path and you will need to enter the name of Q1 from which it will get the values. Make sure that you include this char in the query definition of Q1 and Q2. In Q2 you will restrict the characteristic using this variable. DO not use this variable (replacement path) in Q1.
    In your query properties check if you have turned on the checkmark for Release for OLE DB for OLAP (3rd tab). If the check mark is there, then remove it.
    We are using the scenario in a couple of places, and it works very well.
    Hope this helps...

  • In ADOBE BRIDGE CS6 "folder can not be created" appears when getting photos from camera

    Has anyone seen this when getting photos from camera in ADOBE BRIDGE CS6?
    "Folder cannot be created"

    I solved the problem myself.
    jwerth2

  • Can we get data from business views  in CR 2008/XI?

    Hi All,
    Can we get data from business views  in CR 2008/XI?
    If its possible, pls let us know how to get connect with Business View in both of these versions and what is the tool that we have to use to create Business Views.
    Thank you,
    Krishna Pingali

    Hi Krishna,
    Crystal Reports/BusinessObjects Enterprise ( BOE ) Business Views can only be created using the BV build which comes with BOE and installed using the Work Station installer for BOE. for both XI and 2008.
    You cannot mix these two versions on the same PC not can one talk to the other, the BV designer must match the same version as BOE. XI ( version 11.0 ) is no longer available but if you mean XI R2 ( version 11.5 ) then it still is.
    It's not completely clear which Business View you are referring to? BOE has a Business View Designer so not sure if this is just a naming problem or not? If you are referring to the BOE Business View Designer then the above is true. If your reference is about some other BV designer or data source then you need to clarify.
    Contact our Sales department for pricing and availability.
    Thank you
    Don

  • Can not get data from mySql

    I prepared a GUI user connection application in NebBeans 5.5 accessing mySql database in the company server. The application run very well in desktop.
    However, when I post it to the company server web, it gets nothing from the database.
    Can any one give advice???
    Thank you in advance.
    The following is my application
    import java.util.Vector;
    import java.awt.event.*;
    import java.awt.*;
    import java.awt.event.*;
    public class UserConnection extends javax.swing.JFrame {
    //constants for database
    private final String userName = "labmanage";
    private final String password = "labmanage";
    private final String server = "jdbc:mysql://svr.corp.com/labmanage";
    private final String driver = "com.mysql.jdbc.Driver";
    private JDBCAdapter data = new JDBCAdapter(server, driver, userName, password);
    //variables
    private String user, pwd;
    private Vector<Vector<String>> userTable = new Vector<Vector<String>>();
    private Vector<String>colUserNames = new Vector<String>();
    * Creates new form UserConnection
    public UserConnection() {
    initComponents();
    /** This method is called from within the constructor to
    * initialize the form.
    * WARNING: Do NOT modify this code. The content of this method is
    * always regenerated by the Form Editor.
    // <editor-fold defaultstate="collapsed" desc=" Generated Code ">
    private void initComponents() {
    userLabel = new javax.swing.JLabel();
    pwdLabel = new javax.swing.JLabel();
    userTextField = new javax.swing.JTextField();
    passwordField = new javax.swing.JPasswordField();
    submitButton = new javax.swing.JButton();
    statusLabel = new javax.swing.JLabel();
    jScrollPane1 = new javax.swing.JScrollPane();
    statusTextArea = new javax.swing.JTextArea();
    changePwdButton = new javax.swing.JButton();
    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setTitle("User's Connection");
    setBackground(new java.awt.Color(153, 204, 255));
    setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
    setFont(new java.awt.Font("aakar", 1, 12));
    userLabel.setText("User Name:");
    pwdLabel.setText("Password:");
    submitButton.setText("Submit");
    submitButton.addMouseListener(new java.awt.event.MouseAdapter() {
    public void mouseClicked(java.awt.event.MouseEvent evt) {
    submitButtonMouseClicked(evt);
    submitButton.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    submitButtonActionPerformed(evt);
    submitButton.addKeyListener(new java.awt.event.KeyAdapter() {
    public void keyTyped(java.awt.event.KeyEvent evt) {
    submitButtonKeyTyped(evt);
    statusLabel.setText("Status:");
    statusTextArea.setColumns(20);
    statusTextArea.setEditable(false);
    statusTextArea.setLineWrap(true);
    statusTextArea.setRows(3);
    statusTextArea.setText("Initial assigned password is \"dime\".");
    statusTextArea.setWrapStyleWord(true);
    jScrollPane1.setViewportView(statusTextArea);
    changePwdButton.setText("Change password");
    changePwdButton.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    changePwdButtonActionPerformed(evt);
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(
    layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(layout.createSequentialGroup()
    .addContainerGap()
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(userLabel)
    .add(pwdLabel)
    .add(statusLabel))
    .add(35, 35, 35)
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(layout.createSequentialGroup()
    .add(submitButton)
    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
    .add(changePwdButton))
    .add(passwordField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 230, Short.MAX_VALUE)
    .add(userTextField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 230, Short.MAX_VALUE)
    .add(org.jdesktop.layout.GroupLayout.TRAILING, jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 230, Short.MAX_VALUE))
    .addContainerGap())
    layout.setVerticalGroup(
    layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(layout.createSequentialGroup()
    .addContainerGap()
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
    .add(userLabel)
    .add(userTextField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
    .add(pwdLabel)
    .add(passwordField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(statusLabel)
    .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .add(15, 15, 15)
    .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
    .add(submitButton)
    .add(changePwdButton))
    .addContainerGap(27, Short.MAX_VALUE))
    pack();
    }// </editor-fold>
    private void submitButtonKeyTyped(java.awt.event.KeyEvent evt) {                                     
    if(evt.getKeyCode() == KeyEvent.VK_ENTER) {
    submitButton.doClick();
    submitButton.requestFocus();
    changePwdButton.requestFocus();
    private void changePwdButtonActionPerformed(java.awt.event.ActionEvent evt) {                                               
    String command = evt.getActionCommand();
    if(command.equals("Change password")) {
    passwordField.setText("");
    //Get connection to the changing password panel
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    new ChangePassword().setVisible(true);
    private void submitButtonActionPerformed(java.awt.event.ActionEvent evt) {                                            
    // TODO add your handling code here:
    String command = evt.getActionCommand();
    if(command.equals("Submit")) {
    user = getUser();
    pwd = getPwd();
    data = new JDBCAdapter(server, driver, userName, password);
    data.executeQuery("SELECT * FROM USERTABLE");
    colUserNames = data.getColumnNames();
    userTable = data.getDataTable();
    if(colUserNames.elementAt(0).equals("")) {
    statusTextArea.setText("Can not connect to database");
    boolean checkUser = false;
    int i = 0;
    while(!checkUser && i<userTable.size()) {
    if(user.equalsIgnoreCase((String) userTable.elementAt(i).elementAt(0))) {
    //Find the user in database
    checkUser = true;
    //Check user's password
    if(pwd.equals((String)userTable.elementAt(i).elementAt(1))) {
    //Check for initial default password. The user is requested
    //to change his password
    if(pwd.equals((String) "dime")) {
    statusTextArea.setText("You are requested to change your " +
    "initial assigned password. Click 'Change password' please.");
    else {
    //Set UserConnection Panel to invisible
    setVisible(false);
    dispose();
    //Get connection to the table
    if(userTable.elementAt(i).elementAt(2).equals("0")) {
    //Get connection to non-editable table
    javax.swing.SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    PVRackReportNonEdit rackReport = new PVRackReportNonEdit();
    rackReport.createAndShowDialog();
    else {
    if(userTable.elementAt(i).elementAt(2).equals("1")) {
    //Get connection to editable table
    javax.swing.SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    PVRackReport rackReport = new PVRackReport(user);
    rackReport.createAndShowDialog();
    //PVRackReport rackReport = new PVRackReport();
    else statusTextArea.setText("You do not get approval for viewing data. " +
    "Please contact the administrator for details.");
    else {
    passwordField.setText("");
    statusTextArea.setText("Please enter corrected password or" +
    "the administrator for details.");
    i++;
    if(!checkUser) {
    passwordField.setText("");
    statusTextArea.setText("Not find such user's name." +
    "contact the admistrator for details.");
    private void submitButtonMouseClicked(java.awt.event.MouseEvent evt) {                                         
    // TODO add your handling code here:
    * @param args the command line arguments
    public static void main(String args[]) {
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    new UserConnection().setVisible(true);
    public String getUser() {
    return userTextField.getText();
    public String getPwd() {
    return passwordField.getText();
    // Variables declaration - do not modify
    private javax.swing.JButton changePwdButton;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JPasswordField passwordField;
    private javax.swing.JLabel pwdLabel;
    private javax.swing.JLabel statusLabel;
    private javax.swing.JTextArea statusTextArea;
    private javax.swing.JButton submitButton;
    private javax.swing.JLabel userLabel;
    private javax.swing.JTextField userTextField;
    // End of variables declaration
    Here is my JDBCAdapter
    package rackdemo2;
    * This is an adaptor which transforms the JDBC interface
    * to the PVRackTableDialogue
    import java.util.Vector;
    import java.sql.*;
    import javax.swing.table.AbstractTableModel;
    import javax.swing.event.TableModelEvent;
    public class JDBCAdapter {
    Connection connection;
    Statement statement;
    ResultSet resultSet;
    Vector<String> columnNames = new Vector<String>();
    Vector<Vector<String>> rows = new Vector<Vector<String>>();
    ResultSetMetaData metaData;
    public JDBCAdapter(String url, String driverName,
    String user, String passwd) {
    try {
    Class.forName(driverName);
    connection = DriverManager.getConnection(url, user, passwd);
    statement = connection.createStatement();
    catch (ClassNotFoundException ex) {
    System.err.println("Cannot find the database driver classes.");
    System.err.println(ex);
    catch (SQLException ex) {
    System.err.println("Cannot connect to this database.");
    System.err.println(ex);
    public void executeQuery(String query) {
    if (connection == null || statement == null) {
    System.err.println("There is no database to execute the query.");
    return;
    try {
    resultSet = statement.executeQuery(query);
    metaData = resultSet.getMetaData();
    int numberOfColumns = metaData.getColumnCount();
    // Get the column names and cache them.
    // Then we can close the connection.
    for(int column = 0; column < numberOfColumns; column++) {
    columnNames.addElement(metaData.getColumnLabel(column+1));
    // Get all rows.
    while (resultSet.next()) {
    Vector<String> newRow = new Vector<String>();
    for (int i = 1; i <= columnNames.size(); i++) {
    String tempString = resultSet.getString(i);
    if(!tempString.equals("null")) {
    newRow.addElement(tempString);
    else {
    newRow.addElement("");
    rows.addElement(newRow);
    //Modify dataTable to add empty row to separate chassis
    if(numberOfColumns>1) {
    int nRow = rows.size();
    Vector<String> row = new Vector<String>();
    for(int i=0; i<numberOfColumns; i++){
    row.add("");
    if(nRow>0 || numberOfColumns>0) {
    //Adding blank row to separate chassis
    int i = 0;
    while(i<nRow) {
    if(!rows.elementAt(i).elementAt(0).equals("")) {
    if(i>0) {
    rows.add(i, row);
    i++;
    nRow = rows.size();
    i++;
    close();
    catch (SQLException ex) {
    System.err.println(ex);
    public void close() throws SQLException {
    resultSet.close();
    statement.close();
    connection.close();
    // MetaData
    public Vector<String> getColumnNames() {
    return columnNames;
    public Vector<Vector<String>> getDataTable() {
    return rows;
    public int getColumnCount() {
    return columnNames.size();
    // Data methods
    public int getRowCount() {
    return rows.size();
    }

    Thank you for your answer.
    I'm very new to mySql as server. When I was assigned
    to write the application, the administrator has set
    up mySql database in the company web server for my
    application. My program runs very when using my
    workplace desktop with java web start or with java
    web start in netbeans (all paths should be link to my
    desktop hard disk, i.e. users/application/). I can
    not run the application at home because I can not
    access to the company intranet server (for security
    purpose). The problem happens when I post the
    application in the company web page (I have to modify
    all paths in jnlp file to the company web address).
    The program then runs without exception except it
    seems that it gets no data from the database (for
    example, when I type my username, it returns that
    "There is no such user name. contact.." as what I
    code in the application for not correcting user name)
    It happens for not only using my company desktop but
    also for others.
    Please help me.
    Thank you in advance.And all this could have been answered yesterday, in your other thread, when I asked you "Is the DB configured to allow that user to connect to the DB from where that user is attempting to connect from?"
    Seeing as how you get that error, the obvious answer was, "No." At which point we could have continued.
    Configure the needed users into the DB, without forgetting to allow them access from the machines from which they are going to access from.
    Although, I agree with Rene, that you should set up a server of some sort, located on the same machine as the DB, for communicating with the DB.

  • Trouble capturing waveform from PXI-4472

    I'm really a very green newbie at this stuff, so bear with me...
    I've got a PXI-4472 data acquisition board and a PXI-5411 waveform generator. I've connected the arbitrary out of the 5411 to the channel 0 in on the 4472. An external oscilloscope shows a 1v-amplitude sine wave being generated.
    I created a very simple VI to show what the 4472 is capturing. It connects a NI-DAQ channel I generated to the standard "AI Acquire Waveform.vi", then out to a Waveform Chart, all within a while loop with a Stop button. Problem is, all the waveform chart seems to be showing is the running average of the waveform instead of the form itself (solid line, a tad above zero).
    I can hook the 4472 input channel up to a DC-out power supply, a
    nd when I vary the voltage, the waveform chart changes as well.
    So my question (whew!): What's wrong here that's not allowing me to capture a waveform from the 4472 (in turn from the 5411) and display it on my waveform chart?
    Thanks in advance for the help.

    Never mind.... it was a sample rate problem. I upped the sample rate and it came out ok.

  • No matter what acct I send an email from it gets sent from my gmail

    I only have 2 accts set up on my iPhone: gmail (personal) and bethelmaine.org I can receive email into both accts with no problem, but when I try to reply from my bethelmaine acct the recipient gets it from my gmail acct. I know for a fact the Cc/Bcc, From: line is bethelmaine.org and I also know that the recepient gets it as gmail because I tested it several times by sending to my wife's yahoo acct. This happens when the primary server (under settings: mail, contacts, calendars: accounts) is turned off.
    The bethelmaine acct outgoing server is set up in Outlook as smtp.megalink.net. When that is set up as the primary server and turned on I get a message that says "the recipient was rejected by the server" no matter who I try to send to.
    Not sure what to do!

    It seems pretty clear to me.
    When you turn off your primary account the only active account the phone can send via is your Gmail account, and that's what you're seeing.
    The question is why do you need to turn off the primary account.. which you answer:
    When that is set up as the primary server and turned on I get a message that says "the recipient was rejected by the server
    That's because your ISP (megalink) is using access controls to manage who sends mail through their mail server. The first thing they're probably doing is using IP address restrictions - essentially saying they'll only relay mail from any machine on their network (including dialup/DSL/etc. customers), but you're not on their network, you're on an AT&T (or Verizon) 3G connection which isn't in their IP address range, and therefore not valid as far as their mail server is concerned.
    The typical solution to this is authentication - by authenticating to their server (via username and password) you identify yourself as a customer and they should relay your messages. So check your phone to ensure that you have authentication enabled for your primary mail account.
    If that fails (e.g. they don't support authenticated SMTP) the next option would be to relay the message through your cell provider's mail server - as an AT&T wireless customer you should be able to relay through AT&T's mail server... likewise for Verizon (or whatever national carrier your iPhone is on). You'll need to check with your carrier's site for the specifics of the mail server address to use.

Maybe you are looking for

  • Strange Issue with windows Vista

    Hello Friends, My user is not able to connect Cisco 5400 with windows vista while the same user is able to connect via windows XP.Dialer settings for both the windows are same .I am using windows dialer for both windows.I am using PAP authentication

  • RFC - PL/I function on IBM Host OS/390

    I want to implement the following scenario: call from R/3 via RFC a PL/I function on the IBM host which reads the DB2 on IBM host in order to exchange data. I know OSS note 119496 but can't locate the file OS390RFC.TXT mentioned there. Can anybody se

  • Logic to capture the Error records

    Hi All ,            I have one scenario like this ,one report program runs in R/3 system to fetch some data from BW system . It uses Remote FM to do this . The problem is the FM has got error table with error msgs , if there is any problem in fetchin

  • Security mechanism

    Hi Jhs team: We are planning using "oracle single sign-on" with "programmatic Dynamic Role Based Authorization" as our security control mechanism, The example in jhs_tutorial_3.pdf using Struts-Uix architecture and through ValidateLoginUser Action to

  • Please help - Content Analyzer - NW 04s

    Hi, Can anyone please let me know the steps to use BI Content Analyzer. Thanks, Nisha