Question: I am trying to import `from lxml.html import fromstring` in VSCode but I am getting the error: `ModuleNotFoundError: No module named 'lxml'` I have installed lxml with `pip install lxml`

I am using a virtual environment and VS code

```
Version: 1.52.1 (user setup)
OS: Windows_NT x64 10.0.18363

```

My python version is 3.7.4 and I forced a reinstall of the wheel file

<https://files.pythonhosted.org/packages/7f/7e/e74f03e6e56184f8af8e33055223cb1d8ecec91a7084ca626b8070b2c67f/lxml-4.6.2-cp37-cp37m-manylinux2014_aarch64.whl>

This did not solve the issue, and the 32bit wheel version wont work on my 64 bit machine.

The only solutions I could find were the install from wheel and also try the 32bit version.

Answer: 
Variable $File does not contain the content of your file but the name. Using
$File = Get-Content 'D:......\logs\Nikos\_text2.txt'
will solve your problem.
Your `Select-String` input is the path, not the file content, so you will never get a match. You have to first get the content and then operate on that.

```
$content = Get-Content $File

If ($content | Select-String 'Trigger action error') {

```

Actually you don't really need `Select-String` as you are not interested in the match result, but instead just want to know if there is a match. Even RegEx is overkill, so I would use the [`-like`](https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_comparison_operators?view=powershell-7.1#-like-and--notlike) operator instead:

```
If ($content -like '*Trigger action error*') {

```

You may also look into [`switch -wildcard -file`](https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_switch?view=powershell-7.1) as an alternative way to solve the problem.