home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 9,923 of 10,840   
   Steve Gerrard to donandjane@optusnet.com.au   
   Re: Set RTF file handling   
   26 Feb 06 12:53:45   
   
   From: mynamehere@comcast.net   
      
   "D & J G"  wrote in message   
   news:44014b65$0$27464$afc38c87@news.optusnet.com.au...   
   >   
   >>   
   >> I'm cheating!!   
   >> To simplify printing, the print instruction goes like this:   
   >> Call Shell("write.exe /p " + App.Path + "\filename.rtf")   
   >> If the rtf association isn't set, it doesn't work.   
   >> Too simple??   
   > PS. Call Shell("wordpad.exe /p " + App.Path + "\filename.rtf") doesn't work,   
   > either!   
   >   
      
   As Jerry said, write.exe is in Windows, and therefore in the environment path,   
   while WordPad is somewhere in Program Files (mine is in ...Files\Windows NT\).   
      
   On my machine, .RTF is clearly associated with MS Word, not WordPad. However,   
   this prints the specified file, apparently using WordPad:   
      
   Private Sub Command1_Click()   
       Call Shell("write.exe /p C:\test.rtf")   
   End Sub   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca