|
I need some help with printing. I can easily print a plain text document, but I can't seem to figure out how to print into Rich Text. This entire thing is driving me insane as I really need this for a big project of mine. I really need an example project with all the page setup, print preview, print dialog features... Why didn't Microsoft make this easy?
Please help me!
|
|
|
|
|
Dr. Pool wrote:
I really need an example project with all the page setup, print preview, print dialog features...
Try to check from:
1. Page setup.[^]
2. Print and print preview.[^]
Dr. Pool wrote:
need some help with printing
Try to check here[^] but it demonstrate in vb5, and you should convert it to vb.net
Let me know if it is working or not!!!
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
I want to create an application that has no user interface. The application will be started and stopped using the process class. Creating an app that starts with a Sub Main is no help because it still compiles as a Windows or Console app. Any ideas?
|
|
|
|
|
|
Thanks. I'll try this. I was hoping for something that doesn't create any UI overhead. I don't know if using this setting does or doesn't.
|
|
|
|
|
You might be want to create windows service application.[^] Let me know is this match what you need or not.
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
Thanks for the reply. I tried a service app but got a message saying it had to be installed and I didn't want to take that route. May I didn't try for long enough.
|
|
|
|
|
L.s.
I have written a program vb.net and i have compiled it in to an .exe
Part of this .exe is a module with one argument.
I want to run this .exe from the DOS prompt.
Actually, I want that certain module to be executed giving it an value for it's argument.
I hope someone can help me,
I really need an solution.
Best regards,
Steven
Steven de Vries
|
|
|
|
|
Steven de Vries wrote:
I want to run this .exe from the DOS prompt.
What type of application that you create in vb.net? Do you create console application. If so, try read this lab.[^] Let me know if it is match what you need or not.
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
I have a DataSet set up as an XML file and a DataGrid bound to that DataSet that displays all of the columns in the XML database except for three, one of those being the primary key. I want the user to be able to double click on a row in the DataGrid and have it display the entire record on another form. But I'm having trouble getting the data since the primary key isn't in the dataGrid. I tried using the CurrentRow index but it doesn't necessarily match the same row number of the DataSet, especially if it's been sorted. So how can I link the row selected in the DataGrid to the matching row in the DataSet?
I'm a newbie at DataGrids and DataSets so I've been searching for the answer to this for a few days. I found out this morning that the ASP.NET DataGrid has a property called DataKeys. Does the VB.NET DataGrid have something similar?
C code. C code run. Run code run!
|
|
|
|
|
Is there no way to do this in VB.NET? Basically all I'm looking for is a way to determine the primary key of the row that the user double clicked on in the DataGrid.
Thanks in advance!
C code. C code run. Run code run!
|
|
|
|
|
You have to use the BindingContext to determine the current dataviewrow. From there you can get the datarow and pull out the Primary Key. Ex:
Private Sub DataGrid1_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles DataGrid1.DoubleClick
Dim dvRow as DataRowView = Me.BindingContext(DataGrid1.DataSource, DataGrid1.DataMember).Current
Dim dRow as DataRow = dvRow.Row
MsgBox("dRow Primary Key: " & dRow.item("Key"))
End Sub
From what I've read, this may not work if you're using a filter to display your data.
C code. C code run. Run code run!
|
|
|
|
|
hi everyone
i need an urget urgent urgent help
well what i need help in is, that i want to develop a call card solution , let me exaplin simply, my customer will buy a card, then dial a number, this number asks him to insert the pin code, the authentication is done, then the system will give him a tone and he will dial is number!
ofcourse using .NET
well thats its!
so is there anyone can lead me to anything to start with, any link or code or tutorial and wwillllll be realllyyyy thankfulllll
Kind Regards
Mahmoud Manasrah
|
|
|
|
|
In my opinion, I guest that this is homework that you got from school. Most of our member help to the member that face the real problem in project and give the answer for the peiece of the problem in the project.
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
I'm not sure how to find freespace on a diskette. I've searched MSDN, but only found examples of VB6 and scripting examples.
I'm trying to find a VB.NET solution. Does anyone have any sample code where they look up how much space a file will take and then check how much space is available on the target drive the file is going to be transfered to?
Any help is appreciated.
Lost in the vast sea of .NET
|
|
|
|
|
Hello Kai!
Does anyone have any sample code where they look up how much space a file will take and then check how much space is available on the target drive the file is going to be transfered to?
I'm afraid my suggestion requires the .NET Framework 2.0 but with the new classes the solution is quite easy. Use the DriveInfo.AvailableFreeSpace [^] property to determine how much space is available to you. If it's at least the size of your file (to get that information you can use the FileInfo.Length [^] property) you call FileCopy [^].
Imports System.IO
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles Button1.Click
Dim MyDrive As DriveInfo = New DriveInfo("A")
Dim MyFile As FileInfo = New FileInfo("C:\boot.ini")
If MyDrive.AvailableFreeSpace >= MyFile.Length Then
FileCopy(MyFile.FullName, _
MyDrive.RootDirectory.ToString() + MyFile.Name)
End If
End Sub
End Class
If you're using the .NET Framework 1.1 it seems you will have to use the WMI (see Finding the Amount of Disk Space Available (Visual Basic)[^]).
Best regards
Dennis
|
|
|
|
|
Hi Dennis,
I'm going to keep this message, and reference it later when 2.0 is readily used. For now I used the following information that I found on freevbcode.com:
http://www.freevbcode.com/ShowCode.asp?ID=5588&NoBox=True
I created a class library using this code sample, and any programs I have that need this info can reference the class for info.
I will use the information you gave me to update the class library when our shop has gone to 2.0.
Thanks for the information
KreativeKai
Lost in the vast sea of .NET
|
|
|
|
|
I have an edit box called Login. How do I set the focus on Login at THE END of the string currently in Login? calling Login.SetFocus sets the cursor at the beginning of the string. I want it at the end.
Thank you,
Red Sunday
-----------------
http://www.zachcalvert.com
|
|
|
|
|
Try:
<br />
TextBox1.SelectionStart= TextBox1.Text.Length<br />
TextBox1.Focus()<br />
|
|
|
|
|
Try this code:
With txtLogin
.SelStart = 0
.SelLength = Len(.Text)
.SetFocus
End With
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
Hi
First I'm sorry because I wrote
the code for C# and not for VB.NET! ;P
I think the code you wrote for answering Red's problem,
that will also select the whole text of the textbox,
is not what Red was looking to.
The correction to your code (If my guess in the problem
is correct) is this:
<br />
With txtLogin<br />
.SelLength = 0<br />
.SelStart = len(.Text)<br />
.SetFocus<br />
End with<br /> code>
|
|
|
|
|
Oh, thank you very much for your information. Because I did not look the question carefully that make me confuse. Thank you very much that you correct my mistake
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
Hi there guys...
Have a "fun" new project to work on. What is required is the ability to download a file from a specified webserver (jpg) to my local machine....
Unfortunately, this needs to be done in a UIless dll, so I can't (AFAIK) use the InetTransferCtrl. To add some complexity, we are not able to expose the images directory as a virtual dir, so I have to use SA File up on the server to actually transfer the file.
So what I need is a way of invoking an ASP page on the server, and recieving the file at the client. Am looing at the WinHTTP stuff, and seems to fit the bill - believe I can invoke the page, but have no idea how to get the image out the other side.
Any ideas?
"Now I guess I'll sit back and watch people misinterpret what I just said......"
Christian Graus At The Soapbox
|
|
|
|
|
How do I return an array of strings from a function? Just like the way String.Split does?
|
|
|
|
|
Try returning the array as Variant (in VB6) or Object (in VB.NET)
|
|
|
|