मैं 03 01 2018 को एक अलग तारीख से बदलना चाहता हूं। निम्नलिखित या बेहतर कुछ के साथ:
----
$M = Read-Host -Prompt 'Input your MM'
$D = Read-Host -Prompt 'Input the DD'
$Y = Read-Host -Prompt 'Input your YY'
(Get-Content C:\Users\Desktop\file.txt) | ForEach-Object { $_ -replace "DOB= ", "MM DD YY" } | Set-Content C:\Users\Desktop\file.txt
----
मुझे पता नहीं है कि यादृच्छिक तिथि कैसे खोजना है। इसके अलावा DOB = ** ** ** एक ही पंक्ति संख्या में नहीं है।
----
File.txt पूर्व:
FLOPPY=TRUE
CLOSETIME=0
OPENTIME=0400
EVENTTIME=0
DOB=03 01 2018 (I don’t know the date and it not base on the system date)
xxxxxxxx = 00 00 0000
xxxxxxxx = 00 00 0000
Variable 1
Variable 2
Variable 3
....
------