|
Joseph R. Thomas wrote:
if rich edit box is just ONE OF THE THINGS that is saved inside a random access file..
then how do i make sure that i get the contents of the rich edit box when i retieve it and not anything else?????
You always put it a the exact same place in the file, so that you know where it will be, and then you put something at the end of the rich text section to tell you where it stops, or you tell at the beginning of the section how long the section is so you can tell where it stops.
"Blessed are the peacemakers, for they shall be called sons of God." - Jesus
"You must be the change you wish to see in the world." - Mahatma Gandhi
|
|
|
|
|
coul du gimm an example or something please???
i have been trying and have been unsuccessfull all the way... confused:
what if i have to write in a string then a type then a Rich edit bx content..???
i cant seem to make it work...
tks a lot..
Have a Super Blessed Day!
-------------------------
For God has not given us a spirit of fear, but of power and of love and of a sound mind.
2 Timothy 1:7
"For God so loved the world that He gave His only begotten Son, that whoever believes in Him should not perish but have everlasting life."
John 3:16
"Therefore you also be ready, for the Son of Man is coming at an hour you do not expet."
Luke 12:40
|
|
|
|
|
Hi,
printing to the printer with vb.net
how do i print to the printer from right to left with vb.net
example in vb6:
Printer.RightToLeft = True
Printer.Print "abcd"
Printer.EndDoc
please send me small example
thanking you in advance
From:
yulyos@yahoo.com
|
|
|
|
|
hi,
i have a question...If i open up a Random Access file in a vb form...witha file number..
lets say then i need to unload the form and go to another form...and use the same file number....
can i take the file number acquired while opening one form to another???
how can i do it??
OR
is it better to open and close file at every form??instead of keeping the file number???isn't that bad..keep opening and closing the same file in every file???
can u tell me which way is better??
tks for help...
Have a Super Blessed Day!
-------------------------
For God has not given us a spirit of fear, but of power and of love and of a sound mind.
2 Timothy 1:7
"For God so loved the world that He gave His only begotten Son, that whoever believes in Him should not perish but have everlasting life."
John 3:16
"Therefore you also be ready, for the Son of Man is coming at an hour you do not expet."
Luke 12:40
|
|
|
|
|
If your want to pass the file number around, keeping the file open, you can pass it as a global variable in a .vb module or class file.
On the downside, what your doing isn't considered proper programming technique because it is no longer a modular design.
If your going to be doing file access from multiple modules (or forms), it's best to write up a set of public functions that handles file access for you. Oh yeah, it is NOT a bad thing to be opening and closing the same file all the time...
But, of course, it all depends on what your doing...
RageInTheMachine9532
|
|
|
|
|
I want to know IP Addresses of all machines on a peer to
peer network. How can i do this ?
The network consists of Win 9x machines and there is no
DNS server.
|
|
|
|
|
There a couple of methods you could use to do this, but nothing easy...
First, you could ping a range of IP addresses to get a list of machines that respond, then you would have to port scan each of those responding addresses to figure out what kind of machine is at that address...
Second, you could write a client that you deploy to all of your machines that reports back to a central server and reports the address in use...
But why go through all that trouble when you could download a good IP/Port scanning tool to do that for you or...
If your network is using DHCP to assign addresses, look at the logs/database for the DHCP server to see what addresses have been handed out...
RageInTheMachine9532
|
|
|
|
|
Hey!
I really would like to know if anyone had an idea on how to see who's logged on the domain.
I've thought of using a userlist from the ADSI and compare that to the logon/logoff events in the eventlog. But that isn't the smartest way..
So what i want to know, is there anyone out there who knows a relative simple method to see who's online or not?
All answers will be appreciated!!
Thanks in advance
mwinther
|
|
|
|
|
You would have to check with each server in the domain, seperately , to get the list of users who have attachments to that box.
AD, nor any other directory service I know of, keeps track of who is logged on in the directory. For several reasons, there is no way to keep that kind of information accurate.
I think the closest your going to get to that kind of information, in the directory, is looking at the last known login time for each user.
|
|
|
|
|
Hello,
Can anybody plz tell me how do i retrieve URL from a Web Browser in VB.
i dont want only for Internet Explorer but it shuld be general and work for
every browser. Atleast tell me the API or the steps of how to start. Some
explainations would be nice.
Thanks
Angad
|
|
|
|
|
It's different for every web browser because they are architected differently. For IE, you can either host the WebBrowser control and use the LocationURL property. To do it from an outside process, you'll have to search the running Windows classes for the correct class, search it's child windows for the address bar, and read the text out of it (or get an instance of the IWebBrowser2 interface from the app, but this can be more difficult).
For Mozilla/Netscape, there's different ways. You could use the same approach from an outside application as I outlined above, but the Windows classes would be different for both the browser and the address bar. Same goes for Opera and the other browsers.
There is no single way of doing this for all browsers.
-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
|
|
|
|
|
What are you trying to accomplish? Are you writing vb code in an .aspx file and need to get the current URL (server end programming)? Are you writing (client end) vb script in a web page? This might be a simple answer depending on what you're trying to do. Can you be more specific?
|
|
|
|
|
Hi All.
I have a ListView in VB.NET and I want to be able to execute a save command the will save the contents of my ListView to an XML file but I'm stuck on the first step...I can't figure out how to extract the contents of my ListView. I need to somehow cycle through the rows(items) and extract any existing data.
I figured out how to add, change and update the items and I'm almost certain that copying is similar but I'm new to programming and I just can't seem to see the relation.
Can anybody help?
Thanks
Brad
|
|
|
|
|
hi
i need to implement an e-commerce site,
i can do all the stuff of the invitation already (i hope...).
but, i want to use SSL to secure the data entered in the Invitaion Form (Credit card etc.)
i know i need to do something with the directory in IIS, but not shure.
i want to know what are the steps to secure ASP.NET form with SSL.
(any links to related site its great !)
Thanks,
Yair Cohen
smallfish@walla.co.il
|
|
|
|
|
You can generate an SSL certificate request in IIS by right-clicking on the web site you want to generate a request for in the IIS manager, selecting the "Directory Security" tab, and click the "Server Certificates". Follow the directions to generate a request. Then you submit this request to a certificate authority like VeriSign or Thawte (owned by VeriSign but cheaper with the same grades of encryption). After they sign your certificate (might take a couple days), go back into IIS. Click that button again and follow the directions to add your signed certificate.
This is how you would generate one that browsers will accept by default. If you need a test certificate, you can generate one yourself. See my (old) article at http://www.devhood.com/Tutorials/tutorial_details.aspx?tutorial_id=209[^]. Browsers without your CA installed (they come with default CAs installed most times) will prompt your users, so I wouldn't use this in a public production server.
-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
|
|
|
|
|
thanks.
but this is what i do in IIS. ok.
do i need to do something in my ASP.NET code ?
or its automaticly ?
|
|
|
|
|
ASP.NET doesn't care (it's automatic) because the SSL handshaking is done before the HTTP connection is established, and any communication is both encrypted before being sent out and decrypted before being received by such things like ASP.NET. It still sees everything as it would had it been non-encrypted because, by the time ASP.NET gets it, it isn't encrypted anymore - just encrypted over the wire.
-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
|
|
|
|
|
Is it possible? I need to create a standard form and then populate it with text from a database, putting the text into label controls. The rows in the database will vary so I can't pre-fab the form with X number of labels and then just set their caption property. The form will need to be created on the fly each time it is loaded.
As an alternative (and a very weak one at that) I can add labels for the max possible rows and then set the ones without captions to not be visible. If this is my only choice, is there a way to resize the form using VB?
Mike
|
|
|
|
|
Yes!
Mixture of code and pseudocode is here. Hope that this will work.
text = get a text from Data Base
dim myLabel as new Label
myLabel.Text = text
myLabel.AutoSize = True
mylabel.location = some location
myForm.control.add(mylabel)
myForm.height = myForm.height + myLabel.height
sorry for my bad English.
|
|
|
|
|
I suppose you could.
I am not very sure about this because although I've been thinking about it for my next project, I haven't tested it out yet.
Here's an example you might develop on (change it according to your need):
1. A function to create the dynamic form (it gets the parameters from database)
Public Function CreateForm(ByVal formName As String, ByVal location As Point, ByVal size As Size) As Form
Dim frmDyne As Form
frmDyne.Name = formName
frmDyne.Location = location
frmDyne.Size = size
CreateForm = frmDyne
End Function
2. A function to create the dynamic controls
Public Sub CreateControls(ByRef frmObject As Form)
Dim intX As Integer
Dim intTotalControls As Integer
Dim arrControl(5, 5) As String
'Read database and put into array (for example)
For intX = 1 To intTotalControls
If arrControl(0, 0) = "Textbox" Then
Dim txtBox As TextBox
txtBox.Name = arrControl(0, 1) 'Name of control
txtBox.Text = arrControl(0, 2) 'The text to display
txtBox.Top = arrControl(0, 3) 'Top
txtBox.Left = arrControl(0, 4) 'etc...
txtBox.Width = arrControl(0, 5)
txtBox.Height = arrControl(0, 6)
'and so on...
frmObject.Controls.Add(txtBox)
ElseIf arrControl(0, 0) = "ComboBox" Then
'Create a combobox here
End If
Next
End Sub
You can pass the form as a reference or call the function to create the controls when you create the form too, so they're all in one function or sub.
The point is you can create a dynamic form using this.
PS: Please tell me whether your project works or not, thanks!
Edbert P
|
|
|
|
|
Itanium and Edbert:
Thanks for the speedy replies. I'll try this method today and let you know what happens.
Mike
|
|
|
|
|
Ok, does anyone know where I can begin to look for examples of some certain system events that occur on a PC.
I need to know the following:
1.) Computer LogOn / Bootup Event
2.) Computer LogOff / Shutdown Event
3.) Computer Idle / Sleep / Awake Events
4.) Screensaver activate / deactivate events
I know there is a way to hook the System to receive the Idle event, but can anyone point me in the right direction for some of the other events? Maybe using WMI is an option?
|
|
|
|
|
You might want to start here:
<a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/security/security/event_handler_function_prototype.asp">http:
What you ask is not easily done because of the events your asking for.
Are your writing a service, a user app, or what?
|
|
|
|
|
Actually, it doesn't matter what kind of app...whatever way is the best to implement it...I don't really care about the "easy" factor of programming.
I'll check out the link.
|
|
|
|
|
I am serializing an object and sending it through networkstream to another computer. However when i try to deserialize it, it is giving me a error "BinaryFormatter Version incompatibility. Expected Version 1.0 Recieved version 1566270836.0"
I am using socket programming and not remoting. I am creating the application on a stand alone machine having only one version of .NET framework.
How can i resolve this error?
|
|
|
|