Shell open Notepad and write text

Hi is it possible to open Notepad and write text and let the user print or 
/and save the file, I tried using the SendKeys strText, True after opening 
Notepad but this wont work. Any help would much appreciated.
Charles
0
Utf
12/14/2009 11:55:01 AM
excel.programming 6508 articles. 2 followers. Follow

2 Replies
1725 Views

Similar Articles

[PageSpeed] 10

It seems you are having problems puting text into Notepad.  Why not
write the data as a text file then open the text file with note pad and
print.


ID = shell("C:\windows\notepad.exe c:\myfile.txt")


-- 
joel
------------------------------------------------------------------------
joel's Profile: 229
View this thread: http://www.thecodecage.com/forumz/showthread.php?t=162269

[url="http://www.thecodecage.com"]Microsoft Office Help[/url]

0
joel
12/14/2009 12:29:55 PM
If your code knows what to write, you could create/append the text file in code.

Look at "Print # Statement" in VBA's help.

vqthomf wrote:
> 
> Hi is it possible to open Notepad and write text and let the user print or
> /and save the file, I tried using the SendKeys strText, True after opening
> Notepad but this wont work. Any help would much appreciated.
> Charles

-- 

Dave Peterson
0
Dave
12/14/2009 1:46:10 PM
Reply:

Similar Artilces:

Make shell:UsersFilesFolder = shell:Personal
The best way to describe it is, "how do I Make shell:UsersFilesFolder = shell:Personal via Group Policy? -- Steve ...

open attachments
I'm using XP and Outlook 2002. For some reason I am no longer given the option to "open" attachments just to save them to the disk. Seems to apply to all attachments and doesn't seem to be virus related. any ideas? ...

How can I show the Month in Text with the =month command
I am trying to display the month in text after I use the =month command. This gives me the month number I need to the month name.. Thanks Ovid If a date is in A1 then: =DATE(2006,MONTH(A1),1) will show October formatted as mmmm -- Gary's Student "Ovid" wrote: > I am trying to display the month in text after I use the =month command. This > gives me the month number I need to the month name.. > > > Thanks > > Ovid Another way - you could display the month without using the month function (unless you need the month number for something else): =...

Double opening #2
Hi Thanks to all who responded to my query regarding the 'double opening' of an Excel file. The problem has been resolved after a visit to http://www.contextures.com/xlfaqApp.html#AlreadyOpen Thank you -- Dick ...

Adding default comment text
Does anyone know if there is a way to add default text to a comment so whenever I insert a comment that text is there? For example, if I have a financial spreadsheet and every comment I add looks like this: Current Month: $##.## Adjustments: $##.## Can I make a default comment with the current month and adjustments field pre-loaded so whenever I insert comment all I have to do is fill in the dollar amount. Thanks much, Dan I am wondering why you don't want to put this in columns on the worksheet? Is there no chance you will ever need to use the data in calculations? That's m...

Open a message box if a worksheet is opened
This is a 2 parter. I need a simple macro that states how many times a worksheet has been opened today. I want the results to reflect in cell A1. Then when A1>0 (as the sheet is opened), I need a message box to open to display a simple sentence which can then be closed by clicking an OK button. Here's thanking you in advance. Michael Private Sub Worksheet_Activate() With Me.Range("A1") If .Value > 0 Then MsgBox "Sheet opened " & .Value & " times", vbOKOnly .Value = .Value + 1 End If End Wit...

I cannot open up files from Excel 2004 for Mac on WIndows XP Pro .
When I open up an attachment from a Macintosh that has an excel file with it, I get an unrecognized file format, and it does not display the file. Any ideas???? Do you have XL loaded on your Windows XP Pro machine? If so, XL03 will open XL04 files, since the file formats are identical. Can you open it from the File/Open menu? If so, you've got a windows file association problem. Mac OS doesn't require file extensions, so adding the ".xls" extension may help if it's not there already. In article <31A37645-1D1A-4FCC-8F54-AA675B889D3D@microsoft.com>, "...

excel will not open #4
when i try to open excel it starts to open (the 'welcome' dialog is displayed) but then it just goes away and excel is never loaded See some things to try on Chip's site........ http://www.cpearson.com/excel/StartupErrors.htm Vaya con Dios, Chuck, CABGx3 "pucmann" wrote: > when i try to open excel it starts to open (the 'welcome' dialog is > displayed) but then it just goes away and excel is never loaded ...

Invoices show as open, but the unapplied amount is zero
Hi Client Using GP 8. There is Open purchase Invoice even though there is no payment was made for this supplier/Invoice the unapplied amount show zero. We drill the unapplied amount it shows blank. If I try to void this invoice It is gives the message as "This document cannot be marked for voiding. It has been either partially applied or is on hold". The client confirms that he didn't applied any partial payment for this supplier and we check also there is no partial payment and it is not in hold also. I cant able to proceed further. Will you please help us to fix the pr...

Outlook hangs upon opening
My outlook hangs after it is opened. I have tried removing and reinstalling it, but this does not correct the problem. Any ideas? ...

Outlook pop-up blocker when trying to open CRM record
Hi, I'm using CRM 4.0, Windows Vista, and Office 2007. When using the Outlook Laptop client, I cannot open CRM records and get a message saying that I should add the CRM server to the allowed pop-ups. I tried disabling all IE addins and also most of the Outlook ones and it still doesn't work. Any thouthgs? ie 7 has its own popup blocker. You can add localhost and the crmserver to it under the tools menu, pop-up blocker, pop-up blocker settings. -- Richard Riddle CRM Developer Autonomix "Will Miceli" wrote: > Hi, > I'm using CRM 4.0, Windows Vista, an...

open forms
Hi, I have a form and I open in maximize mod (with docmd.maximize) How can I open another form, (over first form- this is maximize), in a fix place and with fix size ? Set the 2nd form's Popup property to Yes. When you open it from the Database Window (the Navigation Pane in Access 2007), it will then open in a window of its own, outside the Access window. If you open the form programmatically, use: DoCmd.OpenForm "Form1", WindowMode:=acDialog -- Allen Browne - Microsoft MVP. Perth, Western Australia Tips for Access users - http://allenbrowne.com/tips.html Reply ...

Opening old Publisher files
I have many Publisher 97 files created on an old computer. When I purchased o new XP machine I loaded the same 97 Publisher program, but it will not open the files. I run a small business using this letterhead, etc. Suggestions? Hi suggest you post in a publisher newsgroup - they'll probably be able to help more microsoft.public.publisher in addition to the information provided to us you might also like to let them know if you can create NEW publisher files with Publisher 97 on the XP machine? Cheers JulieD "RKlug" <RKlug@discussions.microsoft.com> wrote in messa...

Open, process & print documents without user interface
Hi, I try to create a non-user interface program which gets file name from command line, open and format the document, and print the labels. What application framework can be used? How process print with MFC? Detailed information is appreciated. Thanks, ybc You can directly invoke the Print Dialog using the flags to return the printer DC for the default printer (no UI pops up); this is one of the most expedient ways of getting the printer DC. Just give it a parent window handle of NULL. After that, it's just programming. Use a console app, enable MFC in it if you want to use CSt...

Can't open up Outlook messages
The Microsoft Outlook screen will appear. When I click on the messages they will not open up. I get a message that Outlook Not Responding. Not sure if a connection problem (Using Road Runner), a server problem or a computer problem. Any advice will be appreciated. I have Windows XP Home Edition installed. Thanks. ...

Autorefresh Fails on Open
I set up a simple pivot table that gets its data from CSV file which is set to import automatically upon opening. I worked fine for two days then stopped... I re-created another external data import, same opens to refresh automatically on open. It works once or twice then stops. HELP! ...

internet explorer opens within outlook
We have a site where there are 20 client computers in a windows 2000 domain. There are a mix of w98 and XP pro operating systems with Office 2000/2002. About half of the clients require internet access, and we want to explicitly deny access to the remainder. We thought we had the problem solved by renaming the "iexplore.exe". This stopped the users from accessing through the usual Internet Explorer interface. However, through the Outlook programme, the user's favourites are available and by selecting from here, users have been able to browse the internet. Is there a wa...

Inability to Open Workbooks Without Excel Open
Hi, The only way I can open an existing Excel file is through the application itself. I cannot open a workbook using Windows Explorer, through Start -> Documents, and so forth. When I try using these methods, I am presented with a blank Excel window, without any visible information. Any ideas of how to proceed? Thanks in advance, Henry http://www.officearticles.com/excel/troubleshooting_microsoft_excel.htm ************ Anne Troy VBA Project Manager www.OfficeArticles.com <hstockbridge5@hotmail.com> wrote in message news:1132248432.902401.204520@g43g2000cwa.googlegroups.com.....

separte text
Hi, I have a query setup as a trigger below in sql 7: declare arow cursor for select sonitem, spart, soq, sdisc, sunitprice, sprice from salesitems where sona = @xson and soq>0 open arow while 1=1 begin fetch next from arow into @xitem,@xpart,@xqty,@xsdisc,@xsunitp,@xsprice if @@fetch_status <> 0 break select @xmess1 = @xmess1 +ltrim(convert(char(4),@xitem)) + " "+@xpart + " " +ltrim(convert(char(10),@xsdisc))+ " " +ltrim(convert(char(10),@xqty)) + " " +(convert(char(10),@xsunitp)) ...

Shell Game with XML Attributes
I have a problem that I suspect shouldn't be this hard to figure out, but I'm a .NET newbie so I'm looking for help. I am reading from an XML file to populate a combo box with the value of an "Name" attribute to several elements. When the user selects an item from the combo and clicks a command button, my application needs to: 1. Find the parent element of the "Name" attribute 2. Find the value of the "ID" attribute of the same element 3. Write the value of the ID attribute to another XML file. I can do everything except steps 1 and 2 ;) I've in...

Problem opening .exe files
Hi, I am unable to open any .exe files on my computer. If I try to open any .exe it brings me "Open With" window with the list of programs. But when I right click on exe file it gives me an option "start" which would launch me the application. How can I change the default double-click behaviour to launch the application? I am using Windows Vista 64 bit Home Premium. Any help is greatly appreciated. Thanks! -- hihi7209 Sorry for opening up a new thread. After searching thoroughly in the forum, I was able to fix my issue. Please delete my thread. ...

Sheffield 12614 One Hand Opening Lock-Back Utility Knife, Red
Price:$15.33 Image: http://thediscountdatabase.info/image.php?id=B000KSR8LQ Best deal: http://thediscountdatabase.info/index.php?id=B000KSR8LQ Lightweight aluminum handle with clip. 'Quick Change' mechanism. One hand opening operation; spring blade release. Folds to convenient carrying size. SIMILAR PRODUCTS: Sheffield 12613 One Hand Opening Lock-Back Utility Knife, Black:http://thediscountdatabase.info/index.php?id=B000NI9FA0 Great Neck Sheffield Blue Folding LockBack Utility Knife (12113):http://thediscountdatabase.info/index.php?id=B0001WBSK8 ...

Query: convert multiple logical fields into single 2 character text result
I've solved this particular puzzle, although I'd like to find a better solution than mine. So my emergency is resolved, nevertheless if you like puzzles, please read on... The school district wants a CSV file with fields in a specific order and with specific formatting. Here are the seven possible results for EthnicCd: 2 Char where ML = Multiple Races UN = Unknown or Declined to Report IN = American Indian or Alaskan Native AS = Asian or Pacific Islander BL = African American HI = Hispanic WH = White Our "People" database contains eight ethnicity Yes/No...

Opening & Closing Times on Open And Blind Closed Batches
Hi, Can opening & closing times on batches be affected by a server restart( say a power cut)? We have come across an instance where a batch had a closing time of just a few seconds after it was open and another batch with a closing time earlier than it's opening time! All machines, both backoffice & tills have correct system times & are in ssync. The only significant event round the time these batches were open/closed was a server restart due to a power outage. Any ideas/feedback would be appreciated. Thanks in advance. This is a multi-part message in MIME format. ...

excel file won't open
When trying to open an excel file from an email in outlook I get this error the system could not find the file specified What could be the problem? Thanks Michael What program do you have associated with opening .xls files? --=81 Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. All unsolicited mail sent to my personal account will be deleted without reading. =20 After furious head scratching, Michael Bresnahan asked: | When trying to open an excel file from an email in outlook I get this | error=20 |=20 | the system could not find the file ...