title: Find and Replace line in text file using a wildcard
body: <p>Problem: I am attempting to replace a key-value pair within a text file. The Key is staying the same while the value is changing. I don't want to modify any other lines except the single line that starts with the keyname.</p>
  
  <p>What I have currently:</p>
  
  <pre><code>Sub REPLACESESSIONID()
  
  Dim CONTENT, SESSIONID, WORKINGDIR As String
  
  SESSIONID = "urn:uuid:A750ADE2355E6EAA2315397874423"
  
  SESSION = FreeFile()
  
  ' ESTABLISH WORKING DIRECTORY
  WORKINGDIR = Environ("AppData") &amp; "\PROJECT"
  
  ' READ SESSION.TXT AND STORE AS VARIABLE
  Open WORKINGDIR &amp; "\SESSION.txt" For Input As #SESSION   ' Open file
      CONTENT = Input(LOF(SESSION), SESSION)
  Close #SESSION
  
  ' REPLACE SESSIONID* WITH NEW SESSIONID
  CONTENT = Replace(CONTENT, "SESSIONID*", "SESSIONID;" &amp; SESSIONID)
  
  ' WRITE CHANGES TO SESSION.TXT
  Open WORKINGDIR &amp; "\SESSION.txt" For Output As #SESSION
      Print #SESSION, CONTENT
  Close #SESSION
  
  End Sub
  </code></pre>
  
  <p>I am aware that Replace does not allow wildcards, but am unsure how proceed.</p>
  
  <p>Contents of SESSION.txt:</p>
  
  <pre><code>SESSIONID;urn:uuid:A7AGBDE25436EAA231532239423
  ROLENAME;Local_Unix_Admin
  </code></pre>