Some questi9ons regarding managing an application ini/config file

Dear all, I am new t Java, so please forgive any fundamental errors, and many thanks in advance for any help.
I have an application that stores various runtime parameters in a basic text file. Such parameters include: Date last run, Last user logged on, etc.
An example of a line in this file is:
DateLastRun=08/06/2007
Currently I access this text file with the
BufferedReader.readLine()
This works fine for reading.
Also, I have created a class that is intended handle all the processing required to manipulate this file and its values.
However, I would really appreciate some guidance on my approach, and an answer to a specific question.
1. Is my approach of wrapping this file inside a class a good one?
2. As the use of a text file to hold application parameters would seem to be a very common practice, is there a class within Java that will do all this for me?
3. Reading the file seems quite easy; however, there are several occasions when I want to update a single line of text within the file. At the end of the application for example, I would like to get the "DateLastRun" line, and update it with the current date. I can see that the read() and write() method read a line and write a new line respectively, but how to update a line?
I have looked at the IO tutorials, but without light dawning. I have also looked at random access files, but I do not see how they can easily help, as I don't know the record number; only the value "DateLastModified" (effectively a key). I have also searched the net in vain.
Any general guidance, and or specific advice would be greatly appreciated.
Steve

Thanks very much for the pointer. I had a look around, and this would seem the thing to use. Do you know where I might find some examples of a program that uses this class? As I said, I am very new, and although the class description makes sense, turning that into code is proving quite difficult.
Thanks once again.

Similar Messages

  • Query regarding running Java application from Batch file

    Hi,
    I have written an application in Java and I have packaged it as a JAR file.
    In my system I use a batch file called 'run.bat' to execute the program. The batch file is as follows:
    java -classpath "%CLASSPATH%;editor.jar" editor.JPad
    This works fine in my system. But when it is executed in other systems where JRE is not configured properly, I am not able to correctly start the Java application.
    Please can anybody tell me, how to detect the JRE from the Batch file and refer to it correctly, so that it will run in any system with JRE.
    Can we do this from a Batch file ?
    Hoping for a quick reply.
    Thanks,
    S.Sampath

    You can't really "detect" whether a JRE is available from a batch. All I can think of is to check for the typical Java variables (JVM_HOME, CLASSPATH etc) to exist. If they don't, especially JVM_HOME, a JRE is probably not installed.

  • Should I use .INI or .XML config files on cRIO?

    I'm looking to make a configuration file for an application running on a cRIO-9022. It will contain a small amount of configuration data (like numeric offsets, file paths, and IP addresses). I have 2 questions:
    1) Which file format should I use (.ini or .xml)? I have used .INI in the past because it is human readable/configurable with notepad, but it seems like .xml is becoming the new standard
    2) I would like to be able to modify config parameters on the PC that connects to the cRIO. What is the best way to modify the config file if it is stored on the cRIO hard disk (FTP the file to PC, make changes, FTP back? Network Streams?)
    --CLD--
    LV 6.1, 8.6.1, 2011 SP1, 2012 SP1

    JimMacD wrote:
    Thanks for the info.
    Any clever ways of accessing and changing the Config File data from a LV application running on a PC that doesn't require manually editing the file? I want the operator to just be able to click a button that says "cRIO Config", open a dialog, and change the values from there.
    uhm.... Yes!
    In This Post I show a bit of my hand on just exactly what I keep in a ini.config file (wel,l 1 section of a config file)  It would be nearly idiotic of me to not provide a Config editer since there are numerous Enum type defs in the delimited value for each key.  so since I, as the developer, know what sections (and possibly keys) are there I can read the file and load them to indicators on a config editor GUI.
    I've actually done this two ways-
    1) a seperate app that only "admin Engineers" know the location of "Launch Config editor.exe.
    2) In the application referanced above I have a button that opens a MODAL panel to edit the file (remember- I know what is in the file).   Users need permissions (Users- Passwords and permissions are kept in a config file, of course!) to even display the "Edit Sequence" button. but the "super user" can edit the step parameters. 
    HINT: one of these "Steps" loads a xml file to expose telnet commands and config for the uP on the DUT.   I expect the firmware on the Linux DUT will change in the future and did not want to rebuild my app whenever a typo was fixed in a command line tool.  BUT, since there are "special characters" that do not fit nicely into a .ini I exposed the telnet commands and line ends IP address and the login script  in a xml file.
    I know this did not directly answer your question!  but It should provide some food for thought.
    If you can share your data structure- I can be more specific. 
    Jeff

  • Please ensure that the applicationhost.config file is correct and recommit the last configuration changes made

    I am receiving event ID 5189 on Server 2008 R2, IIS 7.5.  I experience this error across a number of servers, each of which is running only the default web site, but have 600+ applications running on the default web site.  Each application
    has its own application pool.  My point is, the applicationhost.config is rather large.
    I have seen a number of posts on this error message, but my issue itself seems to differ somewhat.  I am aware of a similar post: http://social.technet.microsoft.com/Forums/en-US/3128ee93-1319-4cc2-9257-003512caf476/event-id-5189-microsoftwindowswas?forum=exchangesvrgeneral
    which points to KB http://technet.microsoft.com/en-us/library/cc734988%28v=ws.10%29.aspx
    However, in my case, it doesn't seem that the extreme measures for this resolution are required.  The error usually indicates a corrupted applicationhost.config that must be manually fixed, or otherwise the WAS service needs to be restarted, or the
    server itself, etc.
    In my case, the issue can usually be fixed by an application pool recycle, or at worst a stop/start.  I have an application which is sensitive to recycles, and so we do not have periodic recycle events configured for this application, which is the bulk
    of the applications on the servers.  It seems to me that this issue is usually caused by the application being in use when there is an applicationhost.config change.
    For instance, we have one application that we deploy using msdeploy.  We found that when we ran an installation for this application via msdeploy, we were receiving this event, and we would subsequently get 500 errors in the application (sometimes the
    application pool corresponds to that which is identified in the event log, sometimes it doesn't).    It seems like applications that were being hit at the time the applicationhost.config was modified by msdeploy were affected.  In an attempt
    to correct this, we moved from msdeploy to a batch file containing appcmd commands.  This also did not resolve the issue.
    I have another application which is installed using PowerShell commandlets.  We started to notice that this script also caused the issue to occur on occasion.  As I continued to identify different processes that resulted in the same issue, I came
    to the conclusion that this is likely due to any change in the applicationhost.config.  I assume the issue is that the applicationhost.config is modified during a read operation to the file by the application pool, or WAS service, and that the recycle
    event, which corrects the issue, forces a re-read of the applicationhost.config, resolving the bad-read issue.
    Has anyone else experienced this, or do you have any recommendations?  My current work-around is to not install any applications during peak hours, and performing an IISRESET after installs are completed, to ensure application stability.
    Message              : The Windows Process Activation Service failed to generate an application pool config file for application pool 'myAppPool'. The error type is '7'. To resolve this issue,
    please ensure that the applicationhost.config file is correct and recommit the last configuration changes made. The data field contains the error number.
    Id                   : 5189
    Version              : 0
    Qualifiers           : 49152
    Level                : 2
    Task                 : 0
    Opcode               : 0
    Keywords             : 36028797018963968
    RecordId             : 324108
    ProviderName         : Microsoft-Windows-WAS
    ProviderId           : 524b5d04-133c-4a62-8362-64e8edb9ce40
    LogName              : System
    ProcessId            : 0
    ThreadId             : 0
    MachineName          : MyComputer
    TimeCreated          : 3/3/2014 9:03:24 PM
    ContainerLog         : system
    MatchedQueryIds      : {}
    Bookmark             : System.Diagnostics.Eventing.Reader.EventBookmark
    LevelDisplayName     : Error
    KeywordsDisplayNames : {Classic}
    Properties           : {System.Diagnostics.Eventing.Reader.EventProperty, System.Diagnostics.Eventing.Reader.EventProperty, System.Diagnostics.Eventing.Reader.EventProperty}

    As an update to this issue, after doing some research, it appears the behavior is related to a new feature in IIS7 called Application Pool Isolation (http://technet.microsoft.com/en-us/library/dd163536.aspx).
    This new feature prevents cross-application spillage by isolating the configuration for each application pool in IIS.  So in reality, an application pool never actually reads the applicationhost.config - that is just a master file, and each time it
    is update, it triggers a change to the individual application pool configuration files, located in C:\inetpub\temp\apppools.
    We did try setting Advanced Settings > Disable Recycling for Configuration Change to true, but after an IIS reset we were still able to reproduce the issue - worse actually, because in our test program, which continually hits the web
    service, and also continually makes apphost.config changes, when the two events collide, the 500.19 issue precipitates; but after an additional change to the apphost.config, it seems that the additional changes will actually correct the issue (seemingly forcing
    another recycle, which is also how we resolve the issue manually); after making this setting adjustment, once the 500.19 issue precipitates, additional changes to the apphost.config does not correct the problem, only a manual recycle corrects it.  This
    is the recycling.disallowRotationOnConfigChange property of the app pool.  We also set the setting for recycling.disallowOverlappingRotation to True as well, with the same result.
    We ARE able to prevent this issue by setting the C:\inetpub\temp\apppools\myapppool\myapppool.config to read-only, but for obvious reasons, this is not a desired work-around.
    It seems like what is happening is that any change to the ApplicationHost.config is resulting in each of the C:\inetpub\temp\apppools temp application pool config files being updated as well, in addition to triggering an application pool recycle.  It
    seems to me the desired behavior would be that these files are only updated if the applicationhost.config changes are specific to that application pool - but that doesn't seem to be the behavior.
    After turning on failed request tracing, I was able to narrow the error down more:
    ModuleName
    AnonymousAuthenticationModule
    Notification
    2
    HttpStatus
    500
    HttpReason
    Internal Server Error
    HttpSubStatus
    19
    ErrorCode
    2147942413
    ConfigExceptionInfo
    \\?\C:\inetpub\application\application\web.config ( 9) :Failed to decrypt attribute 'password'
    Notification
    AUTHENTICATE_REQUEST
    ErrorCode
    The data is invalid. (0x8007000d)
    This seems to be pretty static.  Trying to look into possible causes of this issue.

  • What the use of piublicKeyToken in App.Config file

    Hi Experts,
    I'm trying to get some answers related to "piublicKeyToken" in App.Config file if its needed at all! if so do I need to change it for different WS or I can use the same key with different project?
    Thanks

    Anyone!

  • Work Management Service Application

    does anyone have a step by step guide on how to create from scratch a work management service application, i have deleted mine due to issues with task syncs i think it was the configuration of this application that was causing this issue, 
    any help welcome. 
    Cheers

    Hi,
    According to your post, my understanding is that you wanted to create Work Management Service Application.
    The following Service Applications must be provisioned before you can deploy the Work Management Service Application:
    Search
    User Profile
    In addition to this, the Work Management service account must have some further permissions configured:
    Full Control on the User Profile Service Application
    Grant Access To Process Identity
    To Create Work Management Service Application, Navigate to Application Management in SharePoint central administration, select Manage Service Application link. In Service applications page, create new Work Management Service Application, and specify the
    details.
    After re-create a new Work Management Service Application, we need to:
    Create a new Application Pool, but use the same account as for the Application Pool hosting your My Sites/Social or Portal.
    Run a crawl
    Incremental, continuous or full crawl should suffice.
    More information:
    http://consulting.risualblogs.com/blog/2013/10/23/sharepoint-2013work-management-service-application/
    http://sureshpydi.blogspot.in/2013/11/work-management-service-application-in.html
    http://zimmergren.net/technical/tip-work-management-service-application-keeps-telling-us-last-updated-at-111901-1200-am-fixes
    http://blogs.technet.com/b/praveenh/archive/2013/08/22/work-management-service-application.aspx
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Quality Manager Deskop application recording tab

    Dears, I have installed a Quality Manager, a contact centre, and a CUCM, and i have the following problem:
    While running the quality manager Desktop application, I can see recordings in the archive tab for all agents, but on the recording tab i can only view some of them:
    I checked the troubleshooting guide, and i noticed the following problem:
    Problem:
    In QM Desktop, an agent's recordings show up in the Archives tab but do not appear on the Recordings tab.
    Solution:
    The agent is not part of a workflow. Agents must be part of a workflow in order for their recordings to appear on the Recordings tab. Their recordings do show up on the Archives tab as long as archiving is enabled.
    In my case i am assigning a team to a group, and the same team is assigned to the workflow. And the recordings of some agents of this team are seen in the recording tab while others are not. When i go to the workflow i see that the team is assigned to the workflow, my question is that how can i check that each individual agent is a part of the workflow?
    And how can i make all agents appear in the recording tab?
    Please help,
    regards,
    Moustafa

    Hi JT,
    Thanks for the reply, but actualy it was me (Regi) who ask the questions
    I have a few questions about your reply :
    a) Recording desktop logs in WFO_QM\logs (im assuming this is endpoint recording) to see if those recording are tagged for both Quality & Archive reason. If its not marked for Quality then you'll need to check your configuration again.
    Q: Yes I'm using endpoint recording. Do you know what log file and entry I should look for ? Because there are some different log files and each contains a lot of entries. Or can you lead me to a guide in Cisco about this ?
    b) If its marked for Quality, check ProgramFiles\CommonFiles\SQM\recordings\daily to see if there are any files (*raw) in there. The file size should be increasing when the recording is on going. You should only see current day recording files.
    Q: Is the files for Archive Recording should the appear in this folder ? Because right now I'm away from the server and still haven't got the chance to check on this.
    c) By default, the recording files should be transferred into storage location at 6pm each day (default location ProgramFiles\CommonFiles\QM\recordings\audio). If the recording files are not in this folder, then it will not appear in the Recording tab. There could be an issue with the uploading process
    Q: The recording files exist only in the audio folder but not in the video folder (FYI, I also configure QM for Screen Recording).
    Thanks again for the help, JT.
    Regards,
    Regi

  • I need some information regarding the Enable-SPSessionStateService commandlet

    I am our TFS Admin and by default a pseudo SharePoint 2010 admin as well.  We have a couple users who can design and build pages, portals, web parts, etc..  Anyway, one of those users tried to add a web part for SQL Reporting Services
    and in doing so caused an error to occur any time someone attempts to access that page/portal (It is actually a dashboard for TFS).
    After some digging around, the real error (behind the unexpected error with correlation ID) is "Microsoft.Reporting.WebForms.SessionDisabledException: Session state has been disabled for ASP.NET.  The Report Viewer control requires that session
    state be enabled in local mode."
    As a potential solution to this error I found this: 
    http://geekswithblogs.net/naijacoder/archive/2010/06/14/140408.aspx
    among others referencing the same commandlet.
    To my actual questions.
    1.  This commandlet creates a state service database.  Where?  Locally or on the DB server SharePoint is using?  In my case this is a separate machine.
    2.  I noticed on my server running SharePoint 2010 I have an ASP.Net State Service running and a state DB on my DB server.  Do I need to create a new one?  I restarted the service without errors, this did not correct my error.
    3. This commandlet alters the web.config files for the farm. In what way? Is there an easy revert which will change them back should this not solve my problem or make my problem worse somehow?
    I tried to find some deeper documentation on this but couldn't, so maybe a link to that is all I need. 
    Thanks Everyone,  Stu

    The database is created on the default SQL Server/Instance in use by SharePoint, unless you use the -DatabaseServer parameter to specify the server/instance.
    Do you have a State Service Service Application in Manage Service Applications in Central Admin?
    I believe it adds session state to enabled. Just disable or remove the State Service Service App to revert.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • I have some questions regarding setting up a software RAID 0 on a Mac Pro

    I have some questions regarding setting up a software RAID 0 on a Mac pro (early 2009).
    These questions might seem stupid to many of you, but, as my last, in fact my one and only, computer before the Mac Pro was a IICX/4/80 running System 7.5, I am a complete novice regarding this particular matter.
    A few days ago I installed a WD3000HLFS VelociRaptor 300GB in bay 1, and moved the original 640GB HD to bay 2. I now have 2 bootable internal drives, and currently I am using the VR300 as my startup disk. Instead of cloning from the original drive, I have reinstalled the Mac OS, and all my applications & software onto the VR300. Everything is backed up onto a WD SE II 2TB external drive, using Time Machine. The original 640GB has an eDrive partition, which was created some time ago using TechTool Pro 5.
    The system will be used primarily for photo editing, digital imaging, and to produce colour prints up to A2 size. Some of the image files, from scanned imports of film negatives & transparencies, will be 40MB or larger. Next year I hope to buy a high resolution full frame digital SLR, which will also generate large files.
    Currently I am using Apple's bundled iPhoto, Aperture 2, Photoshop Elements 8, Silverfast Ai, ColorMunki Photo, EZcolor and other applications/software. I will also be using Photoshop CS5, when it becomes available, and I will probably change over to Lightroom 3, which is currently in Beta, because I have had problems with Aperture, which, until recent upgrades (HD, RAM & graphics card) to my system, would not even load images for print. All I had was a blank preview page, and a constant, frozen "loading" message - the symbol underneath remained static, instead of revolving!
    It is now possible to print images from within Aperture 2, but I am not happy with the colour fidelity, whereas it is possible to produce excellent, natural colour prints using its "minnow" sibling, iPhoto!
    My intention is to buy another 3 VR300s to form a 4 drive Raid 0 array for optimum performance, and to store the original 640GB drive as an emergency bootable back-up. I would have ordered the additional VR300s already, but for the fact that there appears to have been a run on them, and currently they are out of stock at all, but the more expensive, UK resellers.
    I should be most grateful to receive advice regarding the following questions:
    QUESTION 1:
    I have had a look at the RAID setting up facility in Disk Utility and it states: "To create a RAID set, drag disks or partitions into the list below".
    If I install another 3 VR300s, can I drag all 4 of them into the "list below" box, without any risk of losing everything I have already installed on the existing VR300?
    Or would I have to reinstall the OS, applications and software again?
    I mention this, because one of the applications, Personal accountz, has a label on its CD wallet stating that the Licence Key can only be used once, and I have already used it when I installed it on the existing VR300.
    QUESTION 2:
    I understand that the failure of just one drive will result in all the data in a Raid 0 array being lost.
    Does this mean that I would not be able to boot up from the 4 drive array in that scenario?
    Even so, it would be worth the risk to gain the optimum performance provide by Raid 0 over the other RAID setup options, and, in addition to the SE II, I will probably back up all my image files onto a portable drive as an additional precaution.
    QUESTION 3:
    Is it possible to create an eDrive partition, using TechTool Pro 5, on the VR300 in bay !?
    Or would this not be of any use anyway, in the event of a single drive failure?
    QUESTION 4:
    Would there be a significant increase in performance using a 4 x VR300 drive RAID 0 array, compared to only 2 or 3 drives?
    QUESTION 5:
    If I used a 3 x VR300 RAID 0 array, and installed either a cloned VR300 or the original 640GB HD in bay 4, and I left the Startup Disk in System Preferences unlocked, would the system boot up automatically from the 4th. drive in the event of a single drive failure in the 3 drive RAID 0 array which had been selected for startup?
    Apologies if these seem stupid questions, but I am trying to determine the best option without foregoing optimum performance.

    Well said.
    Steps to set up RAID
    Setting up a RAID array in Mac OS X is part of the installation process. This procedure assumes that you have already installed Mac OS 10.1 and the hard drive subsystem (two hard drives and a PCI controller card, for example) that RAID will be implemented on. Follow these steps:
    1. Open Disk Utility (/Applications/Utilities).
    2. When the disks appear in the pane on the left, select the disks you wish to be in the array and drag them to the disk panel.
    3. Choose Stripe or Mirror from the RAID Scheme pop-up menu.
    4. Name the RAID set.
    5. Choose a volume format. The size of the array will be automatically determined based on what you selected.
    6. Click Create.
    Recovering from a hard drive failure on a mirrored array
    1. Open Disk Utility in (/Applications/Utilities).
    2. Click the RAID tab. If an issue has occurred, a dialog box will appear that describes it.
    3. If an issue with the disk is indicated, click Rebuild.
    4. If Rebuild does not work, shut down the computer and replace the damaged hard disk.
    5. Repeat steps 1 and 2.
    6. Drag the icon of the new disk on top of that of the removed disk.
    7. Click Rebuild.
    http://support.apple.com/kb/HT2559
    Drive A + B = VOLUME ONE
    Drive C + D = VOLUME TWO
    What you put on those volumes is of course up to you and easy to do.
    A system really only needs to be backed up "as needed" like before you add or update or install anything.
    /Users can be backed up hourly, daily, weekly schedule
    Media files as needed.
    Things that hurt performance:
    Page outs
    Spotlight - disable this for boot drive and 'scratch'
    SCRATCH: Temporary space; erased between projects and steps.
    http://en.wikipedia.org/wiki/StandardRAIDlevels
    (normally I'd link to Wikipedia but I can't load right now)
    Disk drives are the slowest component, so tackling that has always made sense. Easy way to make a difference. More RAM only if it will be of value and used. Same with more/faster processors, or graphic card.
    To help understand and configure your 2009 Nehalem Mac Pro:
    http://arstechnica.com/apple/reviews/2009/04/266ghz-8-core-mac-pro-review.ars/1
    http://macperformanceguide.com/
    http://www.macgurus.com/guides/storageaccelguide.php
    http://www.macintouch.com/readerreports/harddrives/index.html
    http://macperformanceguide.com/OptimizingPhotoshop-Configuration.html
    http://kb2.adobe.com/cps/404/kb404440.html

  • How to find solution for avoiding WARNING J2EE SECUR-00100 ********** user-manager (see application/server descriptors) will no longer be supported in the next release of this product

    HI All,
    We are using Oc4j version 10g 10.1.3 , and while starting conatiner  getting below warning , let me know if anyone have solution for this,.
    14/01/10 01:01:29 ********** user-manager (see application/server descriptors) will no longer be supported in the next release of this product!
    Please take the appropriate actions to migrate to an alternative strategy! **********
    2014-01-10 01:01:29.833 WARNING J2EE SECUR-00100 ********** user-manager (see application/server descriptors) will no longer be supported in the next release
    of this product!

    I just checked my BIOS and my current setting is set at IDE although it also mentions that the default should be AHCI. Currently I have a dual boot of Windows 7 (need it for Tax software) and Arch
    So I guess, when I get the new HDD, I will first set it to AHCI and then install the OSes on it. See if NCQ helps any, and if not I will turn it back and re-install (if I have to). I am planning to have Windows only in virtualbox in the new drive.
    Anyhoo, while I was in the BIOS I found two things which I had questions about :
    1) Under Onboard Devices --> Integrated NIC , my setting is currently set at "On w/PXE" and it says the default should be just "On". Would it be ok to change it back to On since its a single machine and its not booting an OS on any server. I just don't want to have to re-install anything now since I will be doing that in the new HDD.
    2) How would I know whether my BIOS would support a 64 bit OS in Virtualbox? I checked some setting under Virtualization, but they weren't very clear.
    I will edit this post and let you know exactly what settings were present under the Virtualization sub-section.

  • Can u tell some  source codes of java application

    can u tell some source codes of java application?
    i want to get some source codes .such as a proxy source code .
    any help will be appreciated.

    hi
    check www.rgagnon.com for more source code in java.
    regards
    Pradheep

  • Hi Sir! I have some questions regarding word report generation please.1.How can i add border to a word page?.2.How can i add grid lines to a table generated in word report?.3.How can i add border to a table of word report?.Thanks Imran Pakistan

    Hi !
    Sir I have some questions regarding word report generation using(C language in labwindows) Please.
    1.How can i add border to a word page?.
    2.How can i add border and grid lines to a table generated in word report(Not the " cvi table control" inserted from gui,i am asking about the table generated in word report)?
    3.How can i fill a cell of word report table withe the data type other than "character"?.
    And sir one question about use of timer in cvi labwindows please.
    Sir i'm trying to set minimum delay interval of timer control to 1millisecond(0.001s),as i set ,timer don't cares of the interval that is set by me it responds only to the default minimum time interval which is i think 10milliseconds(i'am using windows xp service pack3 version 2002).
    Regards
    Imran
    Pakistan
    Solved!
    Go to Solution.

    Hello sir!
    Sir i'm using daq6251.But Sir before implimenting it to my final application now i'm just trying to achieve 1millisecond time interval for timer in a vary simple programe i mean at this time no hardware (daq device) is  involved i,m just trying to achieve minimum time interval of 1millisecond.
    Sir i read form "help" of labwindows how this time interval can be set,i'm trying for,as described in help notes but i could'nt.I'm attaching a screen shot sir for you it may helpful for you to explain me.
    And sir also waiting for your kind reply regarding word report generation.
    Thanks.
    Imran.
    Attachments:
    screen_shot_rigistry.docx ‏65 KB

  • Application - current vi path different - config file

    If I want to use config files (ini files) with an application, to store settings between runs of the application,
    I would like to name the conifg file the same as the application, just with a different ending:
    application.ext with config file application.ini
    For this, I am using the 'current vi's path' and work from there.
    I realised that the 'current vi's path' of the application is different from the one of the vi itself, even with the original vi being in the same directory as the application.
    The application returns the vi in a path that includes the applicatinon as a directory.
    e.g.
    \programs\application.exe
    gives path
    \programs\application.exe\original.vi
    Thus, it seems that I need a different way of stripping/appending the path for the original vi and for the application, when creating the path for the configuration file.
    Is there a way around it?
    Is the only way to program a 'smart' stripping tool, that checks if the current path includes an xxx.exe part, and then creates the path for the config file accordingly? (This is what I will do, if there is no simpler solution)
    Thanks for any help,
    Stephan

    Hi Stephan
    You don't need a 'smart' stripping tool. Just check in your main vi if it is run by the LV runtime environment or the LV dev. system. Depending on this, either strip the path once or strip it twice.
    Thomas
    Message Edited by becktho on 12-21-2005 03:12 PM
    Using LV8.0
    Don't be afraid to rate a good answer...
    Attachments:
    StripPath.vi ‏16 KB

  • Photosmart 8750, color managed by application

    I have not used my printer for high quality printing in over a year; also the software is downloaded (not from the disk supplied which is lost). The updated software is slightly different from the original. I have two questions regarding printing with "color managed by application": 1. In the list of printer profiles, there does not seem to be a selection for the three color cartridges of tri-color, blue photo, and gray photo; to be used with high quality photo paper. I have learned the hard way that the right setting here is imperative. 2. In selecting color management, I have picked "color handling by PhotoShop Elements" (I used to use Adobe Photoshop 7, if that makes a difference). A message "Did you remember to disable color management in the printer preferency dialogue" appears, but there are only two options for that: "ColorSmart/sRGB" and "Adobe RGB." In the past I selected "Managed by application," which is no longer an option (except on the previous screen as previously noted). Do I select "AdobeRGB" since I am using Adobe Photoshop Elements? Thanks for any assistance you can offer. Of course, I can print with "managed by printer," but I believe "managed by application" gives a bit richer color.

    My prints recently have had a green cast. Any suggestions?

  • Firefox worked briefly but now I get xul cannot find application.ini message and it will not start. Tried reinstalls.

    Love Firefox but now it will not open. When I try to open it, I get an error message that xul can't find the application.ini.
    == This happened ==
    Every time Firefox opened
    == two days after I installed it. ==
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; GTB6; Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1) ; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)

    Hello.
    Hopefully this support article is what you need:
    https://support.mozilla.com/en-US/kb/Firefox+will+not+start
    In any case, it's possible that you are having a problem with some Firefox add-on that is hindering your Firefox's normal behavior. Have you tried disabling all add-ons (just to check), to see if Firefox goes back to normal?
    Whenever you have a problem with Firefox, whatever it is, you should make sure it's not caused by one (or more than one) of your installed add-ons, be it an extension, a theme or a plugin. To do that easily and cleanly, run Firefox in [http://support.mozilla.com/en-US/kb/Safe+Mode safe mode] (don't forget to select ''Disable all add-ons'' when you start safe mode). If the problem disappears, you know it's from an add-on. Disable them all in normal mode, and enable them one at a time until you find the source of the problem. See [http://support.mozilla.com/en-US/kb/Troubleshooting+extensions+and+themes this article] for information about troubleshooting extensions and themes and [https://support.mozilla.com/en-US/kb/Troubleshooting+plugins this one] for plugins.
    If you need support for one of your add-ons, you'll have to contact its author.
    If the problem is not disappears when all add-ons are disabled, please tell me, so we can work from there.

Maybe you are looking for

  • LOST PHOTOS IN PHOTOS BUT NOT IN EVENTS !

    After the latest update of iphoto '11 to version 9.1.1 one photograph has replaced all the others in the majority of the older folders. It has repeated its self hundreds of times. However when one clicks on the events folders the original pictures ca

  • Slow Motion Looks Bad

    Hi, I have FCE 4, and in my movie, i have slow motion. However, when I create a master sequnce, the slow motion looks jerky because my video is sd and the master sequnce is HD, but the sequence needs to be HD because I have pictures, and the pictures

  • Subtitles causing "video bit rate too high" error

    At least I think they are. My media was all encoded through compressor and when the build gets to: - Preparing Subtitles... - Muxing VTS011.VOB the next message is red... - Video Bitrate Too High - Build cancelled - Formatting finished. me... weeping

  • PO forward issue

    When attempting to forward an PO approval document from the Approval Details tab I am recieving the following error message: APP-PO-14056: User Exit #PO FIND_FORWARD returned error Cause: #PO FIND_FORWARD encountered an internal error. Parameters: FI

  • How to create new authorisation object for Transactions?

    Hi, How to create new authorisaton object and how to assign that object on a transaction code? Case -> The transaction code VL01N have the object called V_LIKP_VST under Class "LE_V" that have two auth. fields. one is 'Activity' and other one is "Shi