Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / March 2008

Tip: Looking for answers? Try searching our database.

Print To File

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
HaySeed - 04 Mar 2008 01:45 GMT
I need to print to disk with a dynamic output filename.  I have read some
material that would seem to indicate that the way to do this is to use the
Microsoft defined DOCINFO structure and the StartDoc function in the Win32
API.  I have checked my Win32 API Bible and found no such reference.

Q.1 - Is this the best approach?

Q2 - What would the code look like?
Peter Duniho - 04 Mar 2008 01:54 GMT
> I need to print to disk with a dynamic output filename.  I have read some
> material that would seem to indicate that the way to do this is to use  
> the
> Microsoft defined DOCINFO structure and the StartDoc function in the  
> Win32
> API.  I have checked my Win32 API Bible and found no such reference.

Rather than reading a third-party reference, you might be better off using  
the official documentation when you're looking for something specific.

http://msdn2.microsoft.com/en-us/library/ms535793(VS.85).aspx

Beyond that, if you are doing this using unmanaged code, then this is not  
the correct newsgroup at all.  This newsgroup is for questions pertaining  
to programming using the .NET Framework.  If you're calling the Win32  
StartDoc() function, then by definition this is the wrong place to ask  
questions about that.

Pete
HaySeed - 04 Mar 2008 04:52 GMT
Thanks for the reply Pete.

I thought Win32 access was a framework issue using p/Invoke.  If not, where
would you suggest would be the proper forum for a C# to Win32 question?

> > I need to print to disk with a dynamic output filename.  I have read some
> > material that would seem to indicate that the way to do this is to use  
[quoted text clipped - 15 lines]
>
> Pete
Peter Duniho - 04 Mar 2008 06:53 GMT
> Thanks for the reply Pete.
>
> I thought Win32 access was a framework issue using p/Invoke.  If not,  
> where
> would you suggest would be the proper forum for a C# to Win32 question?

Nothing about your initial post suggested you were using C#.  But  
regardless, if you don't already know what in the Win32 API you need to  
do, your first step is to figure that out, and that should be done in the  
context of a newsgroup pertaining to the use of the unmanaged Win32 API.

If you have a specific question about using p/invoke with a particular  
Win32 function, then here would be a useful place to ask that question.  
At that point, you'd actually have a "C# to Win32 question" and that's  
on-topic here.  But the mere fact that you're intending to use p/invoke to  
get at the Win32 API doesn't mean that questions about how to use the  
Win32 API itself are appropriate here.

By the way, I'm not writing this because I'm playing net-cop or anything  
like that.  The fact is, if you want a good answer to that particular  
question, this just isn't the place to ask.  You should be asking people  
who are more likely to know, and that's in a different newsgroup.

Pete
HaySeed - 04 Mar 2008 22:04 GMT
I apologize for the ambiguity.  Let me try again.

I need to make a call to the Win32.StartDoc() method from inside C#.  Could
you give me insight into what that call would look like?

> > Thanks for the reply Pete.
> >
[quoted text clipped - 20 lines]
>
> Pete

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.