Remove # and clear the line from txt files

Hello

I have problem with my program.

I need to remove the empy lines in my txt file.

This is file look like:

# Standard capacitance data file
# Model capacity: parallel (K = 3.0)
# Created by: ECT32v2 for Beta2.25 of Win32 (July 10, 2003 01:54:24)
# Source: rec_flow_f45_v800_n2.bcp
# Description: contents of the buffer to capture mode
# Date: 12:04:43 GMT standard time, 29 March 04
# Electrodes = 8, measures = 28
# Data for plan 1

# 1 frame (0 msec)
0.006-0,001-0.004-0, 002 - 0.028-0.031-0,002
-0.008-0, 005 - 0.007 - 0.024 0.005 0.004
-0.014-0, 002 - 0.011-0.004 0.002
-0.008 - 0.003 - 0.004 0.003
-0.011 0.001 0.002
0.005 0.004
0,008

# structure 2 (10 ms)
-0.002 0, 005 - 0.008 0.006-0,002 0,023 0.011
-0.008-0.004 - 0.004 - 0.003 0.010 0.001
-0.007-0,001-0,012 0.007 0,008
-0.015-0.004 0.002 0.001
-0.007-0,002 0.001
-0.002 0,008
0.005

I want to remove all empty lines, lines containing ' # '.

I try as an attachment, but it does not work.

How can I do this?

Regads,
Sorry for my English

Ben Merci for example. Somehow, I missed the framework which enabled search expresion. Your example has sent me to the help files to understand. I have modified my first code for the show method, I hope I have the correct explanation. Not trying to do someones homework for them, but for those who need a quick start, maybe this will help someone else along the way.

Tags: NI Software

Similar Questions

  • Remove the string from txt file

    I have a .txt file (see table) I use the spreadsheet for the array function to retrieve the data I need. I am trying to extract over time of Inspection and the number doubles alongside that separately, but I have a problem with the delimiter. The .txt file will still not of this size, but the 1st and the last line will be the same


  • How to display random lines from txt file

    Good morning (or evening all). I am creating an application and want to display random lines of a text file. I know how to create a text file using file connections, but how can I read the random lines of her?

    OK I got it.

    For beginners like me to have a problem in the future, I was not specify my path correctly. It is not enough to land your .txt in the /res folder and wait for the Simulator to load. You must load from SD card or device memory.

    Use the method found here:

    http://www.weask.us/entry/J2ME-BlackBerry-read-write-text-file

    to use it's as simple as that

    StringfName = "file:///SDCard/Blackberry/text.txt";

    String printLine = readTextFile (fName);

    label.setText (printLine);

    Somewhere in your project directory create a directory called SDCard (I did in my res folder).

    In the Simulator go to switch SD card, then load Select Directory and select the new directory of the SD card. This will create the structure of the SD card in the Simulator. Simply move your .txt in the SDCard/Blackberry directory and run your application.

  • How can I remove and restart the device from the devices pending?

    Hello

    I have a problem with the number of systems in State waiting, but I am unable to assign layer or something.

    I tried to remove the Mirage client several times already but without success - systems stay in "connected suspended" State.

    Any ideas that I can do to make it work?

    Thanks in advance

    2013-08-29 16_42_21-Remote Desktop Manager [mirage-man].png

    Hello world

    Thanks for the replies.

    I managed to past this error with VMware, no real support solution, and more:

    -These "suspended" systems seems to have an action being performed on them (e.g. layer provisioning) - clear all Task Monitor allows

    -update to 4.0 4.23 also authorized "ghost" items, new version also seems to be more stable

    It could be that useful...

  • Remove and reinsert the battery to reboot the computer from sleep mode

    When the computer goes into mode "sleep" due to inactivity, it cannot be started again until I completely remove and reinsert the battery. It is an Acer laptop with Windows 7 OS

    Hello

    References to Vista also apply to Windows 7.

    1 I want to erase the General corruption and repair/replace damaged/missing system files:

    Start - type this in the search box-> find COMMAND at the top and RIGHT CLICK – RUN AS ADMIN

    Enter this at the command prompt - sfc/scannow

    How to analyze the log file entries that the Microsoft Windows Resource Checker (SFC.exe) program
    generates in Windows Vista cbs.log
    http://support.Microsoft.com/kb/928228

    Run checkdisk - schedule it to run at the next startup, then apply OK then restart your way.

    How to run the check disk at startup in Vista
    http://www.Vistax64.com/tutorials/67612-check-disk-Chkdsk.html

    -------------------------------------------

    Check the settings (BIOS/CMOS) that you can start and ensure that this suite of lan, Wake on modem and
    similar are not enabled.

    Shoot sleep problems - hibernation
    http://www.computerperformance.co.UK/Vista/vista_hibernate.htm

    How to solve a problem of Mode for Vista and find a Solution
    http://www.Vistax64.com/tutorials/63567-power-options-sleep-mode-problems.html

    How to enable and disable Hibernation - you can try to disable and re-enable the it. http://www.Vistax64.com/tutorials/165508-hibernation-enable-disable.html

    How to restore the default power in Vista (and then go back and change as you wish)
    http://www.Vistax64.com/tutorials/198047-power-plan-restore-default-settings.html

    How to troubleshoot performance problems with sleep, hibernation and resume in Windows Vista
    http://support.Microsoft.com/kb/950686

    Panel configuration-Device Manager - look at the settings for the network card, WiFi, Modem power management.
    and other devices. (Double click on the device and the power management tab)

    Panel configuration-Control Panel Home view (non-conventional) in the top-right search pane
    type of hibernation - see turn Hibernate on / off

    All the default power plans and then set them as you wish.

    I hope this helps.
    Rob - bicycle - Mark Twain said it is good.

  • I paid creative cloud. I need first. But I had a month of trial version. And now the money from an account has been removed automatically, but I do not have first. What can I do?

    I paid creative cloud. I need first. But I had a month of trial version. And now the money from an account has been removed automatically, but I do not have first. What can I do?

    Sign out of your account of cloud... Restart your computer... Connect to your paid account of cloud

    -If you have more than one email, but of course you use linked to your subscription

    -Connect using http://helpx.adobe.com/x-productkb/policy-pricing/account-password-sign-faq.html

    -https://helpx.adobe.com/creative-cloud/help/sign-in-out-activate-apps.html

    -http://helpx.adobe.com/x-productkb/policy-pricing/activation-network-issues.html

    -https://helpx.adobe.com/x-productkb/policy-pricing/activate-deactivate-products.html

  • altitude necessary to open the doc or txt files?

    When I try to open a .doc or .txt without having to open a word processor first program I get an error message that the elevation is necessary. I am running Windows 7 Home Premium 64-bit.

    Hello

    1. What is the brand and model of the computer?

    2. have you made changes on the computer recently?

    3. is the specific question of doc or txt files?

    4. are you able to open other files such as excel, Notepad, etc.?

    5. What is the exact error message you get while trying to open the doc or txt files?

    6. were you able to open .doc and .txt files earlier?

    Method 1.

    Appropriating the file and then try to open.

    To take ownership of a file, follow these steps:

    1.right - click on the file you want to take control and then click Properties.

    2. click on the tab Security and then click OK in the security message (if one appears).

    3. click on Advancedand then click the owner tab.

    4. in the name list, click administrator, or click the Administrators group, and then click OK.

    The administrator or the Administrators group now owns the file.

    Method 2.

    You can try disabling UAC and check.

    Turn User Account Control or disable: http://windows.microsoft.com/en-US/windows7/Turn-User-Account-Control-on-or-off

    UAC disable WARNING:

    User Account Control (UAC) can help you to prevent your computer from unauthorized changes. It works by asking permission when a task requires administrative rights, such as installing software or changing settings affecting other users. We do not recommend disable user account control. If you turn it off, you must reactivate as soon as possible.

    I hope this helps.

  • Import and delete the photos from the camera

    The link you gave is not useful. I don't want to use the application Windows 8 photos. All I want to do is to plug my camera and have pictures, transfer in a folder of my title and delete the photo from my camera. It's an ability that were available in Windows 7 and not available in Windows 8. I am currently using Dropbox and it is slow and uses tons of data to my hotspot.

    Thank you!

    Split from: https://answers.microsoft.com/en-us/windows/forum/windows_8-pictures/importing-and-erasing-photos-from-camera/d8ad55da-66e7-46d5-b54e-3ef0bf45e986

    Hello Joe,

    Thanks for posting your query in Microsoft Community.

    I understand that you have questions, import and delete the photos from the camera. We are happy to help you in the matter of fixing.

    You can check the below link to import photos from the camera.

    1. First, connect your digital camera, and press the Power On button. Windows 8, which will detect the camera and will install the appropriate drivers.
    2. After the driver installation is complete, the AutoPlay menu appears.
    3. Select the option import pictures using Windows.
    4. In the lower right corner of the screen, a small window asking if you want to mark photos will appear. You can type a general images you want to import. Tags can be very useful to organize and find your photos.
    5. If you do not want to insert a tag just leave this space empty and click Import.
    6. If you want to customize the import settings, click the Options button. Now you can change the following settings: where pictures import them (the default folder is pictures - if you want another folder, click Browse and select or create this folder), the name of the folder (by default the name of the folder will be the date when the images are imported over the tag you entered) and the file naming convention.
    7. When you are finished, click the OK button. These settings apply to all the photos you want to import in the future.
    8. After you click import, Windows 8 starts to move all your photos.  If you want the pictures to be removed from your camera once the import process is completed, click the Delete after import check box.
    9. Once the process is complete, start Windows Photo Gallery and you will be able to see all the photos that have been imported.
    10. Now, turn your unit off and unplug the cable to connect to your PC.

    If this does not help then, try the steps below to get the images from the camera.

    1. Go in computer.
    2. You will find the camera under portable device or removable devices.
    3. Double-click on this unit and you can copy and paste from this location and import it onto your computer.

    I hope this helps. Otherwise, feel free to write us back for assistance.

  • I have different bookmarks I want to keep on each computer, synchronization will delete the bookmarks on a single computer and replace the bookmarks from another computer in their place

    I have not yet used sync, but I sense it's going to be a problem if I do. I have different bookmarks I want to keep it on each computer. Sync will delete the bookmarks on a single computer and replace the bookmarks from another computer in their place? So I think that will erase the bookmarks on the second computer you configured to synchronize. Is there a way to merge bookmarks on every computer in the library of a bookmark that contains all bookmarks on both computers, so I'm not all bookmarks in sync?

    Just to be clear, this is something that we have commented several times in the forum, Firefox Sync adds everything that is already in the device for the account and pushes this info for the rest of the devices.

    So if you have 2 computers with data X and the other with the data from there, once you set up synchronization in both computers you will have X + Y at the same time.

    I hope that clarifies the doubts...

  • How can I clear the cache from time to time, it improves anything

    How do I clear the cache from time to time, or that I should, and improve anything

    Which cache?

  • I understand that the watch ntbtlog.txt file drivers loaded during the startup process. I'm worried when it shows driver loaded, but it is not a list.

    I understand that the watch ntbtlog.txt file drivers loaded during the startup process. I'm worried when it shows driver loaded, but it is not a list. Why is this?

    Hello

    Yes, it can be in hidden files that may cause by the virus.

    I also suggest you to see link and check.

    Show hidden files

    http://Windows.Microsoft.com/en-us/Windows7/show-hidden-files

  • even if the margins and clear the values defined divs, overlaping

    For this site, the text in the DIV called "thumbnailshere" overlaps the div below, even if the margins and clear the values have been set.

    http://tfproperty.co.UK/checkthisout/about.html

    How can I fix it?
    Thank you

    jdldn wrote:
    > For this site, the text in the DIV called "thumbnailshere" overlaps the div
    > below him, even if the margins and clear the values have been set.
    >
    > http://tfproperty.co.uk/checkthisout/about.html
    >
    > How to fix this?
    > Thank you
    >

    This is because you have set the height on your 'thumbnailshere '.

    . Never
    the value height unless you know how high the content is going to be.
    Remove the height.

    {.thumbnailshere}
    height: 400px; / * remove the height * /.
    margin-top:-10px;
    }

  • Removing and installing the RAM several times can affect to my Mac Mini?

    My little brother back RAM on my Mac Mini many times; but it remove the RAM properly and install it correctly

    Removing and installing the RAM may affect to my Mac Mini?

    Mac Mini (late 2012)

    OS X 10.11.5

    No, it should not affect the machine when the withdrawal/re-installing memory - correctly.

    My second thought about this - why it has removed/re-installed memory several times?  Trying to upgrade the drive?  change a component any?  repair?

    Materials only I 'played' were - SSD, adding second HARD drive disk with data doubling cable, insulating modular wifi/bluetooth, etc. and of course, the upgrade memory.  Once they did that, I got very little intention of reopening the mini - except air jet, clean the fan.

    Sam

  • How can I clear the notifications from the notification Center while I can not click on the delete button?

    How can I clear the notifications from the notification Center while I can not click on the delete button? I have an iphone with ios 9.3 6

    WBY can't you click on the white circle with an X in it next to the notification?

  • What is the problem with my iphone? He says still no service but my sim card works with other phones, after a reboot it says searching until I have to remove and reinsert the sim ive done all what is the factory reset to open the phone to verify any damag

    IPhone 6 64 gb

    iOS 9.2.1

    The phone says no service but the SIM card works, everything in the phone works except the flash still lights up and flickers sometimes before becoming stable but who don't mind not 'that' much, ive tried factory reset and everything, ive also open the unit and looked for signs of damage, the phone knows there is a SIM card in the phone , but he never says the name of the carrier, also after the restart he said looking and does not stop until I have remove and reinsert the SIM card.

    You can restore the factory state after an iTunes backup

    If this does not resolve the problem then you may want to align on Apple or an approved repair shop

Maybe you are looking for