Problem on use of files

Hi all,
This was the problem i was asked in my exam and i could not think anything on this.plz any body if makes me understand this i will be very thankful.
Write a program that reads an integer from a file. The initial name of the file
is known to be "data" but its extension is either "dat" or "txt" or "asc" or nothing.
In other words the name of the file is either "data" or "data.asc" or "data.txt"
or "data.dat". The program must systematically try to read one after one.
Indeed we assume that only one such file exists. As soon as it succeeds it
should not attempt any more. Then print the number.

Dear Friends,
i know that all people on this forum are wonderful and very helpful.
i don't know why you all are not helping this kid who has posted this prob. and just demanding help.
plsssssssss just help me.

Similar Messages

  • Two problems in using LKM file to sql

    hi all,
    i met two problems during use "LKM file to sql" for loading data from csv file to oracle db. please try to help me, thanks a lot!
    my environment:
    os: win 7
    odi version: 11g
    The 1st condition is: in the 10th step of the execute session, a table called ".SNP_CHECK_TAB" which could not be created in oracle will be created!
    If i modify it to SNP_CHECK_TABLE, the step will pass...
    why naming table like this?
    create table .SNP_CHECK_TAB
         CATALOG_NAME     VARCHAR2(100 CHAR) NULL ,
         SCHEMA_NAME     VARCHAR2(100 CHAR) NULL ,
         RESOURCE_NAME     VARCHAR2(100 CHAR) NULL,
         FULL_RES_NAME     VARCHAR2(100 CHAR) NULL,
         ERR_TYPE          VARCHAR2(1 CHAR) NULL,
         ERR_MESS          VARCHAR2(250 CHAR) NULL ,
         CHECK_DATE     DATE NULL,
         ORIGIN          VARCHAR2(100 CHAR) NULL,
         CONS_NAME     VARCHAR2(35 CHAR) NULL,
         CONS_TYPE          VARCHAR2(2 CHAR) NULL,
         ERR_COUNT          NUMBER(10) NULL
    The 2nd condition is: i want to filter out certain name in the source table and the filter string is "BRE.name!='some_value'".
    When I clicked the "Testing query" button, the following error shows:"Error while executing query Invalid format description".
    It works well when the source db is oracle, why not file? Is there any format for the filter string in file? I don't think so...
    Jun

    Hi Jun,
    Can i contribute a little for ur 2nd problem.
    This error is coz, If u are using a filter against a File "data store" u can't test it, only against RDBMS query will be tested at data store level.
    Well, for using that filter and make sure its working, drag and drop the source file in the interface (u can get the filter) and make it to execute on STAGING.
    Thanks,
    Guru

  • Problem on using batch file

    Hi,
    I have an application which reads data from a text and writes them to a database. I should use batch files in my project to work classes with double clicking on them. Java application reads path of the text file from a properties file. I used relative paths like that " ..\\data\\records.txt" for text file path . But my problem is that; when I run application normally it executes. But when I tried to run it from batch file placed build folder(under project folder) it does not work. Because it tries to find the data folder under the build folder. But data folder is under parent folder of build folder. My batch file code is like that :
    SET PATH=%JAVA_HOME%\bin;%PATH%
    SET LIB_PATH=..\lib
    SET CLASSPATH=%LIB_PATH%\mysql-connector-java-3.0.17-ga-bin.jar;..\bin;..\
    java.exe yega.timesheet.MainApplication ..\\configuration\\properties.props
    pause
    Which statements should I add(and where) to make this batch file search for data folder under its parent folder... Please help me.
    Thank you.

    Thanks Paul, but I tried to use cd before running program. I added "cd .." or "cd ..\" lines to batch file but they didn't work. I decided to use absolute path instead of using relative paths. I also found one more solution. I can put a properties file in build too. And define text path as " ..\\data\\records.txt " in this properties file.
    Also I need to use "\\" because "..\\configuration\\properties.props" is the input for args...

  • Problem in using PNG files....

    Hi everybody...
    Whenever i use ImageIo.read(filename) function to read a PNG file....it returns a bufferedImage with Type = 0....
    and i cannot use this type of image to perform convolution operations....
    how can i solve this??....
    Another problem is that whenever i save it using the write method....the size of the new file is way too large than original image.
    ( ex - 250 kb(source image) - 1.5Mb(saved image))
    how can i solve this??
    plzz someone help me...
    itz urgent!!

    I'm making educated guesses here but I suspect you may be loading a palettised (ie <16M color) file and convolution probably requires true color - you can convert by creating a new image and rendering into it.
    As for writing out, you can adjust the write settings by tailoring the relevant ImageWriteParams... there should be plenty of info around if you Google.

  • Webserver Problems when using exe file

    Hey guys I could use some help with a problem I am having.
    I am working with webservers and am trying to stream my program from one computer (server) to another.  I can do this with standalone problems but am having trouble when I try to use an executable.  I have found this article for help:
    http://digital.ni.com/public.nsf/allkb/7F95D43D3F50FCAC8625710E000068E1
    I have included two print screens of the situation.
    1st is my observed stand alone file.
    2nd is my exe file that is showing an error  
    Any help would be greatly appreciated
    Attachments:
    Stand alone Program.png ‏350 KB
    With exe.png ‏87 KB

    Hey dwhamm,
    If the computer that you are trying to use as the server and deploy the executable on does not have the LabVIEW runtime engine that matches the development system, the remote front panel will not operate properly.  Below please find a link on how to build an installer that you should make to include the proper runtime engine:
    http://zone.ni.com/reference/en-XX/help/371361H-01/lvhowto/build_installer/
    There is a note at the bottom of the original tutorial that you referenced on what to be sure to include in the installer. 
    Also, were you able to try changing the URL from http://TargetComputerName/VIname.html to http://TargetComputerIPAddress/VIname.html? 
    Do you have any firewalls on the computer that is being used as the web server?
    Regards,
    Kira T

  • Problem with using swc files in Flash Player 10

    I have two Actionscript projects in Flex. One is using Flash Player 9 the other is using 10.  Both projects use the fl classes specifically FLVPlayback.
    In the Flash Player 10 project I am using the recently released version 2.5.  Both players use individual controls instead of a complete skin swf.  So the code goes something like video_player.playPauseButton = playPauseBtn.  All the swc files are imported through properties-ActionScript Build Path-Library path-add swc.  This all works great in both projects exept in the Flash Player 10 project the volumeBar swc does not load properly.  In the debug variables for a break point at the function below in FLVPlayback.as the variables handleLeftMargin, handleRightMargin, handleLinkageID and handleY are missing even though they are all in the original fla used to compile the swc.  I have tried compiling swc in both Flash CS3 and 4.  I have tried moving the Actionscript inside the fla files but nothing changes. This leads me to believe it is a bug in the Flash Player 10 or the version 10 playerglobal.swc since this part of FLVPlayback.as is identical in versions 2 and 2.5. The result is that only the volume bar renders but no handle. Debugging all through fl.video.UIManager.as handle_mc remains null?
           public function set volumeBar(s:Sprite):void {
                uiMgr.setControl(UIManager.VOLUME_BAR, s);
    In the Actionscript 9 project all the variables are accounted for so the volume bar and handle render and work fine.

    Further info for anyone who can help!
    I am opening a session from a server via the following sql
    statement:-
    http://servername/virtualdirectoryname?sql=SELECT
    * FROM table1 for XML auto&root=root"
    I only get the popup window when trying it out from our
    webserver?
    The server is MS SQLServer
    The virtualdirectory is created with access set as Windows,
    and always log on set as "myusername" + "mypassword"
    So I thought (hoped) I could pass the "myusername" +
    "mypassword"
    bits into the above sql statement (maybe appended at the
    end?)
    If I type the above sql statement into a browser it works
    perfectly with the xml returned in a web page,
    also as I state above, when I run it from within my flash
    prog on my local machine it runs OK and returns the results into
    the text area specified within the flash prog.
    BUT - When I upload my flash prog to the webserver and try it
    from there, I get a windows popup asking me for username + password
    + domainname.
    any ideas please?

  • Can I use mp3 files from different domain as the feed?

    Hi..
    I have just created a new podcast here:
    http://artistsofliving.com/?feed=podcast
    I would like to submit the podcast to iTunes sometime soon...
    However, I'm wondering if they will reject it because the feed lives on 'artistsofliving.com', whereas I keep the media mp3 files on 'livinginthepresent.com'... a different domain.
    I own the mp3 content and both domains- I'm splitting the media from the website for bandwidth reasons.
    Is this ok? If this causes a rejection straight out is there a way to indicate that I own the material fairly?
    Thanks!
    -rich

    There's no problem about using media files from any source: the feed just has to reference them (the URLs have to be 'absolute' - i.e. including the http:// and the server name - even if the file is on the same server as the feed anyway). I don't see the fact that some files have different URLs leading to accusations of copyright breach.

  • When I have video clips on my timeline, they do not play in the monitor screen. I hear the sound track but can not see the image. To test if my new files are somehow the problem, I went back and used video files that I used successfully a year ago, and th

    When I have video clips on my timeline, they do not play in the monitor screen. I hear the sound track but can not see the image. To test if my new files are somehow the problem, I went back and used video files that I used successfully a year ago, and they no longer play in the monitor window. I hear the sound track, but do not see any video. Have I changed some setting that controls video playback in the monitor window?

    Randy Ruttger
    Thanks for the follow up.
    Missing in this equation were the version of Premiere Elements that you were using and the computer operating system on which it was running. But...
    The deed is done. But.....Until now and after you went ahead and moved to version 12, we now learn what version of Premiere Elements you were using. We still do not know the computer operating system involved.
    You just said Premiere Elements 10. Premiere Elements 10 is hit by a serious known display issue if the computer uses a NVIDIA GeForce video card/graphics card. In this issue, the only remedy is to roll back the driver version to about May 2013. The description of the problem and how to do the roll back are described in one of the Announcements at the top of this forum. What video card/graphics card does your computer use?
    On another front, Adobe will be releasing a new version of Premiere Elements any day now. No one but Adobe knows the feature set for the new version. That type of information is announced at the moment of release of the new version.
    So the remedy to the problem that you presented in this thread could have been...
    1. Rolling back the NVIDIA GeForce driver version to about May 2013 if possible (Windows 8 or 8.1 64 bit, may not be possible)
    2. Move to another version of Premiere Elements (which you did)
    I offer the above for consideration so that you can review your decisions. We are pleased to learn that Premiere Elements 12/12.1 works for you.
    Please do not hesitate to ask questions and ask for clarifications, but remember that the answers are in the details.
    Best wishes,
    ATR

  • Problems converting a pdf file to a word document using ExportPDF

    I am having problems converting a pdf file to a word document (.docx) using ExportPDF. It is spends ages trying to upload the PDF file, but fails to do so. Should I just cancel my subscription?

    I suspect that you are asking for help with CreatePDF. If so, you should post in
    http://forums.adobe.com/community/createpdf
    This is the Reader forum...

  • Problem in uploading a file using Ws_upload.

    Hi Experts,
                        I am using WS_UPLOAD for uploading .xls file into SAP Standard table T558A.
    Problem is file is not uploaded to DB table.....getting error like
    ERROR DURING FILE UPLOAD/DOWNLOAD as  pop up message.....
    can any boady please help on this issue.
    Regards,
    Praveena.

    Hi,
    If you want to upload the data using EXCEL file use the function module ALSM_EXCEL_TO_INTERNAL_TABLE.
    Examples for ALSM_EXCEL_TO_INTERNAL_TABLE.
    http://wiki.sdn.sap.com/wiki/display/Snippets/Howtouse+FM'ALSM_EXCEL_TO_INTERNAL_TABLE'

  • Time machine: An error occurred while copying files. The problem could be temporary. If the problem persists, use Disk Utility to repair your backup disk.

    Time machine backups are failing. I've followed the instructions I found on the Time Machine troubleshooting page (http://pondini.org/TM/Troubleshooting.html) but have gotten to where I don't know what to do next.
    Sequence of events:
    The main error message is always:
    An error occurred while copying files. The problem could be temporary. If the problem persists, use Disk Utility to repair your backup disk.
    Yesterday, I opened Disk Utility and verified the disk. Got this error:
    Error: This disk needs to be repaired using the Recovery HD. Restart your computer, holding down the Command key and the R key until you see the Apple logo. When the OS X Utilities window appears, choose Disk Utility.
    I ran Disk Utility and repaired the hard drive. Then I manually started the backup before going to bed, figuring it was going to take a long time to run. When I got up this morning, the backup had failed with the same "could be temporary" error. I checked the log, which says:
    Starting manual backup
    Attempting to mount network destination URL: afp://Tery%20Griffin;[email protected]/Tery%20Griffin's%20Time%20Ca psule
    Mounted network destination at mount point: /Volumes/Tery Griffin's Time Capsule using URL: afp://Tery%20Griffin;[email protected]/Tery%20Griffin's%20Time%20Ca psule
    Disk image /Volumes/Tery Griffin's Time Capsule/Tery Griffin’s Computer (44).sparsebundle mounted at: /Volumes/Time Machine Backups
    Backing up to: /Volumes/Time Machine Backups/Backups.backupdb
    Event store UUIDs don't match for volume: Macintosh HD
    Error: (-36) Applying backup protections to /Volumes/Time Machine Backups/Backups.backupdb/Tery Griffin’s Computer (44)/2014-03-05-201742.inProgress/ABB10CF2-F041-4DE5-B6AE-3C228B59ADCC
    Error: (5) setxattr for key:com.apple.backupd.SnapshotStartDate path:/Volumes/Time Machine Backups/Backups.backupdb/Tery Griffin’s Computer (44)/2014-03-05-201742.inProgress/ABB10CF2-F041-4DE5-B6AE-3C228B59ADCC size:17
    Error: (5) setxattr for key:com.apple.backupd.SnapshotState path:/Volumes/Time Machine Backups/Backups.backupdb/Tery Griffin’s Computer (44)/2014-03-05-201742.inProgress/ABB10CF2-F041-4DE5-B6AE-3C228B59ADCC size:2
    Deep event scan at path:/ reason:must scan subdirs|new event db|
    Finished scan
    Found 145601 files (11.88 GB) needing backup
    16.1 GB required (including padding), 620.77 GB available
    Copied Zero KB of 11.88 GB, 0 of 145601 items
    Copied 0 files (Zero KB) from volume Macintosh HD.
    Copy stage failed with error:11
    Backup failed with error: 11
    Ejected Time Machine disk image: /Volumes/Tery Griffin's Time Capsule/Tery Griffin’s Computer (44).sparsebundle
    Ejected Time Machine network volume.
    Starting automatic backup
    Attempting to mount network destination URL: afp://Tery%20Griffin;[email protected]/Tery%20Griffin's%20Time%20Ca psule
    Mounted network destination at mount point: /Volumes/Tery Griffin's Time Capsule using URL: afp://Tery%20Griffin;[email protected]/Tery%20Griffin's%20Time%20Ca psule
    Disk image /Volumes/Tery Griffin's Time Capsule/Tery Griffin’s Computer (44).sparsebundle mounted at: /Volumes/Time Machine Backups
    Backing up to: /Volumes/Time Machine Backups/Backups.backupdb
    Event store UUIDs don't match for volume: Macintosh HD
    Error: (-36) Applying backup protections to /Volumes/Time Machine Backups/Backups.backupdb/Tery Griffin’s Computer (44)/2014-03-05-201742.inProgress/9F8E7957-9C50-49C3-8314-880E5203E3D9
    Error: (5) setxattr for key:com.apple.backupd.SnapshotStartDate path:/Volumes/Time Machine Backups/
    Does anyone know what the problem is here and what I should do?
    Thanks,
    Tery

    You have repaired your boot drive (which is good) but have you repaired your time machine drive?  I don't own a Time Capsule so I don't know if disk utility can operate on it.  If it can, you should repair it as well.  You may need to erase it and start a new backup.  That happens to time machine volumes from time to time and is why people who are serious about their data never rely on a single source of backup.

  • Problem in Receiver side File Adapter using FTPS mode

    Hello,
    Here I am facing some problem in receiver side while using FTPS mode in the channel configuration.
    The error message which i could see in the audit log is,
    Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error when getting an FTP connection from connection pool: com.sap.aii.af.service.util.concurrent.ResourcePoolException: Unable to create new pooled resource: java.lang.NullPointerException
    Can anyone help me out in solving this issue ASAP?
    I am using Per file transfer mode ni the reciever channel.
    Thanks in advance,
    Yours
    Soorya

    HI Surya,
    First check wether server started or not and then check you are connecting to FTP server by
    go to run -> cmd and write ping and ipaddress which is used and see whether u r getting reponse from teh FTP server.
    Try to login to the ftp server which you have mentioned in CC using the user name and pwd, to chk whether you have the permissions to login to the server.
    Also the check whether the folder you are trying to access is having permission for delete/read/write.
    Restart the FTP server and try it again.
    Regards
    Sridhar Goli

  • Problem: using Dynamic file naming in adapter

    Hi
    Wat  i m doing is using dynamic file configuration as given in this link
    /people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14 and trying to get file name and content of the file.
    I m getting file name in dynamic configuration in SXMB_MONI but payload is empty.Actually i have to pass this payload to BPM.

    Subodh,
    I understand that using the filename you would like to do the validations, but, am not able to get the entire flow, inclduing your BPM flow.
    If you give us the entire interface flow, it would be helpful to understand the problem better.
    Just a quick note : Try to do the mapping that gets the filename outside the BPM if you do not get this inside the BPM.
    Have not tried this, but I have seen a few posts which found that the dynamic parametrs were not accesible inside the BPM.
    Regards,
    Bhavesh

  • Problem Exporting for Web files created in FCE using Quicktime

    I have been using FCE 4.01 on Mac OSX 10.7.5 with Quicktime 10.1 (501.29).
    I convert my footage in Mpeg Streamclip (GREAT free program) and set the files to the Apple Intermediate Codec.  This makes them work really well in my timeline and I don't have rendering issues or problems.
    So, my problem comes when I File/Export/Quictime Movie.
    The original file plays fine, but they're 2-3 gbs each, so I put them into Quicktime to convert them to a webfriendly size, but every single time they come out as an audio only file.  GRRRR!
    Any help would be greatly appreciated.  Maybe I'm missing something stupid.
    Thanks so much for your help.
    Sincerely,
    Steve

    Why not bring the exported AIC file  back into MPEG Streamclip instead of QTX? You'll have a lot more control.
    Compress the file to H.264 and restrict the data rate according to the resolution you're working with and to something consistent with the guidelines of the Web Service (say, You Tube) you're uploading to, (For example, something like 6 Mb per second would be about right for a 720P file.)
    Or use Quicktime Conversion from FCE.
    Good luck.
    Russ

  • Can anyone help me?Time Machine couldn't complete the backup to...  An error occurred while copying files. The problem may be temporary. If the problem persists, use Disk Utility to repair your backup disk.  What is the problem?  I've made no changes.

    I recently starting receiving the error message "Time Machine couldn't complete the backup to... An erro occurred while copying files.  The problem may be temporary.  If the problem persists, use Disk Utility to repair your backup disk.  I have had no problems backing up my MacBook Pro 2011 to my Western Digital My Book Live through a Linksys EA4500 router until recently.  I've made no major changes.  I've ran a diagnosis on my back up drive with no problems.  The Time Machine back up starts, but about after about 5 to 10 minutes I get the error message.  I can see the shared drive in Finder.  The light on the drive blinks while it starts the back up.  I can see the shared folders on the networked drive.  The backup process starts but for some reason it just stops.  Can anyone help?

    You can't repair a network volume in Disk Utility.
    Backing up to a third-party NAS with Time Machine is risky, and unacceptably risky if it's your only backup. I know this isn't the answer you want, and I also know that the manufacturer says the device will work with Time Machine, and that it usually seems to work. Except when you try to restore, and find that you can't.
    If you want network backup with Time Machine, use as the destination either an Apple Time Capsule or an external hard drive connected to another Mac or to an 802.11ac AirPort base station. Only the 802.11ac base stations support Time Machine, not any older model.
    If you're determined to keep using the NAS for backup, your only recourse for any problems that result is to the manufacturer (which will blame Apple.)

Maybe you are looking for

  • Error - Lnks stored incompletely - How to Delete vendors

    Dear, All Experts. When trying to delete vendor via OBR2 I am getting this error. Links stored incompletely Message no. FG166 Diagnosis Customer/vendor links are to be taken into consideration when archiving or deleting customers or vendors. To do th

  • Bi publisher report

    I have incorporated more than one report template in .rtf file using if condition. When i preview the report after loading xml data,there is an extra space on the top of the report.Due to this some part of report goes to 2nd page. Plz help me out.

  • New Pricing Procedure

    Hi Gurus -- I have to set up a pricing procedure in which calculation for allowances(discounts) should not happen during PO Creation and all discounts should go to a single GL account during goods receipt and invoice verification .i am not sure what

  • SSDT Schema Compare keeps showing the same objects as different..

    Hi,  When comparing a database to my project using Visual Studio 2012 SSDT I get several stored procedures marked as changed. The body of the procedures is identical, but two properties are highlighted as different when expanding the object: IsSelf (

  • JumpOutReturn Function to Outlook Recipient with an Attachment

    From inside AW we are wanting to use the JumpOutReturn Function to open an Outlook message that has a training evaluation Word document attached and automatically plugs in the subject of the message and the Send To Address. We tried adding a calculat