From: Digest <deadmail>
To: "OS/2GenAu Digest"<deadmail>
Date: Tue, 22 Jul 2008 00:00:42 EST-10EDT,10,1,0,7200,4,1,0,7200,3600
Subject: [os2genau_digest] No. 1678
Reply-To: <deadmail>
X-List-Unsubscribe: www.os2site.com/list/

**************************************************
Monday 21 July 2008
 Number  1678
**************************************************

Subjects for today
 
1   Ini files : Peter L Allen" <allenpl at tastelfibre dot com dot au>
2  Re:  Ini files : Ian Manners" <deadmail>
3  Re:  Ini files : Dennis Nolan <dennis at jeg-og dot com>
4  Re:  Ini files : Peter Moylan <peter at pmoylan dot org>

**= Email   1 ==========================**

Date:  Mon, 21 Jul 2008 12:45:06 +1000 (EST)
From:  "Peter L Allen" <allenpl at tastelfibre dot com dot au>
Subject:   Ini files

With all the messing around to get uniaud and the full snap stuff working (W4 FP15) 
something is messed up.
System runs much better but WPS has the odd funny.
Running checkini /c crahes when writing changes with message

"PrfWriteProfile Failed Error 0x150f :  Error : file is read only"

Any significance in ini.rc carrying a date around the time of the changes?
The rest are year 96 and inisys.rc at 00 which is likely the year of original install,

				Regards,
						allenpl

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

**= Email   2 ==========================**

Date:  Mon, 21 Jul 2008 13:03:44 +1000 (EST)
From:  "Ian Manners" <deadmail>
Subject:  Re:  Ini files

Hi Peter,

>"PrfWriteProfile Failed Error 0x150f :  Error : file is read only"

goto x:\os2 and type 'attrib -s -h -r os2*.ini'
You can leave the files without the attributes set as OS/2 doesnt
really care :-)

Cheers
Ian Manners
http://www.os2site dot com/


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

**= Email   3 ==========================**

Date:  Mon, 21 Jul 2008 15:17:23 +1000
From:  Dennis Nolan <dennis at jeg-og dot com>
Subject:  Re:  Ini files

Peter L Allen wrote:
> With all the messing around to get uniaud and the full snap stuff working (W4 FP15) 
> something is messed up.
> System runs much better but WPS has the odd funny.
> Running checkini /c crahes when writing changes with message
>
> "PrfWriteProfile Failed Error 0x150f :  Error : file is read only"
>
> Any significance in ini.rc carrying a date around the time of the changes?
> The rest are year 96 and inisys.rc at 00 which is likely the year of original install,
>
> 				Regards,
> 						allenpl
>

>  

>   
..rc files are resource files.

Instead of embedding details of window controlls, text and labels etc. 
where they would have to be in digital format they are put into resource 
files which are then added to the end of the relevant .exe file.

There are two API calls for creating windows, one for the embedded data 
and another for the resource file data.

Resource files are text files and the ini.rc would have been created 
during the install as it would then have all the labels and other text 
in the installation language without having to include all possible 
languages in the exe file.

Apart from allowing for different languages they allow redesigning the 
windows design without having to recompile the exe file.

Here endith the lesson.

Regards
Dennis.

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

**= Email   4 ==========================**

Date:  Mon, 21 Jul 2008 15:59:20 +1000
From:  Peter Moylan <peter at pmoylan dot org>
Subject:  Re:  Ini files

Dennis Nolan wrote:
> Peter L Allen wrote:
>> With all the messing around to get uniaud and the full snap stuff 
>> working (W4 FP15) something is messed up.
>> System runs much better but WPS has the odd funny.
>> Running checkini /c crahes when writing changes with message
>>
>> "PrfWriteProfile Failed Error 0x150f :  Error : file is read only"
>>
>> Any significance in ini.rc carrying a date around the time of the 
>> changes?
>> The rest are year 96 and inisys.rc at 00 which is likely the year of 
>> original install,
>>
>>                 Regards,
>>                         allenpl
>>
> 
>>
>>  
>
>>   
> .rc files are resource files.
> 
> Instead of embedding details of window controlls, text and labels etc. 
> where they would have to be in digital format they are put into resource 
> files which are then added to the end of the relevant .exe file.

[Remaining details snipped]

The Prf... functions, on the other hand, are concerned with reading and 
writing INI data. I suspect, therefore, that the INI.RC file is a red 
herring in this case. The error message "PrfWriteProfile Failed" almost 
certainly means that the error occurred while CheckINI was trying to 
write to either OS2.INI or OS2SYS.INI. Furthermore, the error message 
tells us the reason: one (or both) of those files has become read-only.

Although I haven't seen it in recent years, I seem to recall that there 
was a bug in INI file handling that caused INI files to be set to 
read-only at apparently random times. I think it's related to the 
(undocumented and mysterious) file-locking system that's used to deal 
with the fact that several programs could be accessing the same INI file 
at the same time.

The odds are that the problem will go away once you remove the read-only 
attribute from the two INI files.

-- 
Peter Moylan                                    http://www.pmoylan dot org
peter at pmoylan dot org
----------------------------------------------------------------------------------
 

