Jump to content

open .txt in wordpad


Recommended Posts

hello all

i have written a program that uses the scripts written in .txt format from a particular location (C:\Scripts) and reads it by opening in wordpad. now the problem is that when i used this program in an another computer it opened it in 'notepad'. so the program was not able read the files opened with notepad and returned error.

i just need that program should only open the scripts in wordpad. i know i can change from the properties of the scripts, but a new user that will use my program will not be aware of that and he will face 'errors'. pls help......

thanx

[font="Palatino Linotype"]Randeep Singh[/font][sub][/sub]

Link to comment
Share on other sites

@Inverted

actually i am trying to use

run('WordPad.exe "C:\T-MATRIX\Database\Scripts\Single_Site\Create_empty_database.sql"')

then it works............

but i want to open it with wordpad. :D

How do you open the scripts ?

You can use the command :

wordpad.exe *fullpathofthefile*

(wordpad.exe is always in the path, so you don't need the full path to it)

Edited by randeep

[font="Palatino Linotype"]Randeep Singh[/font][sub][/sub]

Link to comment
Share on other sites

@DjDeep00

very useful info. it really works. :D

thanx for sharing

@randeep...

#include <Process.au3>
$rc = _RunDos("Start Wordpad C:\T-MATRIX\Database\Scripts\Single_Site\Create_empty_database.sql")

:D

[font="Palatino Linotype"]Randeep Singh[/font][sub][/sub]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...