Jump to content

Search the Community

Showing results for tags 'dynamically writing html file'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 1 result

  1. We have an application that needs to be able to dynamically write data to an HTML file from a subroutine. I have a routine that will write the basic structure of the HTML file only once, such as HTML, head, title, body and table. However, when the program launches again it will write these sections again. Is there any UDF's available to automate writing HTML to a file or could someone maybe let me know of a better way to accomplish writing html locally? Basically, in a nutshell my problem is that I need to write to a table more than once throughout the duration of the program without having to setup the html file over again. This should give you an idea for what I'm trying to do. #include <MsgBoxConstants.au3> #include <File.au3> Local $file = Null _Main() Func _Main() WriteHtmLog("It works!", "It works!!", "It works!!!") EndFunc Func _SetupWriter() $file = FileOpen("log.html", 1) ;FileWrite($file, "<html><head><title></title></head><body><table border='1' style='width=100%'>") ;FileWrite($file, "<tr><td>Time & Date</td>") ;FileWrite($file, "<td>Client Info</td>") ;FileWrite($file, "<td>Data</td></tr>") EndFunc Func _CloseWriter() FileWrite($file, "</table></body></html>") FileClose($file) EndFunc Func WriteHtmLog($var1, $var2, $var3) _SetupWriter() FileWrite($file, "<tr><td>" & $var1 & "</td><td>" & $var2 & "</td><td>" & $var3 & "</td></tr>") _CloseWriter() EndFunc
×
×
  • Create New...