Sha256: 2c65d051a3f2c64b04ff81028618d808853593380babe3c85fa565763e7066b1
Contents?: true
Size: 916 Bytes
Versions: 4
Compression:
Stored size: 916 Bytes
Contents
# this method adds a new address record def saverwdaddressesconfiguration require 'fileutils' newname = "rwdaddresses.cnf" # grab the filename to create newdata =@a_adconfigline1.to_s + "\n" + @a_adconfigline2.to_s + "\n" + @a_adconfigline3.to_s + "\n" + @a_adconfigline4.to_s + "\n" + @a_adconfigline5.to_s + "\n" + @a_adconfigline6.to_s + "\n" + @a_adconfigline7.to_s + "\n" + @a_adconfigline8.to_s + "\n" + @a_adconfigline9.to_s + "\n" begin # exception trapped block fileName = File.join( ConfigurationDir, newname ) fd = File.open(fileName,"w") fd.print(newdata) # save the record info to the file fd.close @newconfigurationresult=newdata # show the record info in the browser rescue SystemCallError, StandardError $stderr.print "system call error: " + $! end # exception rescue end
Version data entries
4 entries across 4 versions & 1 rubygems