|
Dim Col1 as Collection
Dim Col2 as Collection
'Add 10 items to the Collection object Col1.
Set Col2 = Col1 'What it really does, whether "Col2" has a copy of the collection "Col1" or ref of the collection "Col1".
Thanks,
Sakthivel
|
|
|
|
|
Try changing one of the items in Col1 and then view the same item in Col2, that will give you your answer.
|
|
|
|
|
Col2=col1 as reference, if u assign a object to another objects (not only collection) it will always reference
check the following code whit lable control
I think u will understand
Dim lbl1 As New Label
Dim lbl2 As New Label
lbl1.Text = "Am label 1"
lbl2.Text = "Am lable 2"
MsgBox(lbl1.Text)
MsgBox(lbl2.Text)
lbl2 = lbl1
MsgBox(lbl1.Text)
MsgBox(lbl2.Text)
lbl1.Text = "Code Project"
MsgBox(lbl1.Text)
MsgBox(lbl2.Text)
Thanks
Rajesh B --> A Poor Workman Blames His Tools <--
|
|
|
|
|
Hi,
I'm using VB.Net 2005 and a MsChart to view my chart. I have a problem in the design of the MsChart. please see the link below to view the image.
http://i208.photobucket.com/albums/bb158/klaydze_2007/awtz.jpg[^]
Now, how can hide the numbers? The vertical numbers (0, 5, 10, 15 - 35). Can someone explain to on how to hide it?
Thank You.
if(you type your code here) {
Messagebox.Show("You help me a lot!");
}
else {
You help me = null;
}
|
|
|
|
|
|
Hi Khatri,
Thanks for giving me the link. Maybe in the future i can use that. But i found no answer in my problem. Any other way?
Thank You.
if(you type your code here) {
Messagebox.Show("You help me a lot!");
}
else {
You help me = null;
}
|
|
|
|
|
Hello,
I am developing an Smart Device application in Vb2003. I want to store objects stored in Collection in a file. While doing the process, I get IOException on first creating FileStream. It says need to set Security for File I/O permissions. Can anyone help me, what I need to do and how do I achieve it.
Any help, guidance is highly appreciated.
Thanks
Terry
|
|
|
|
|
Hi,
I got a problem when my application migrated from VB6 to VB.NET. The problem is "Couldn't resolve default property of object adresse."
Here is the sample code:
Friend ReadOnly Property adr() As rsd
Get
'UPGRADE_WARNING: Couldn't resolve default property of object adr. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1037"'
Return mA
End Get
End Property
Here rsd is structure type.
Could anyone of you please guide me how to solve this problem.
Thanks in advance,
AR Reddy
|
|
|
|
|
|
Rewrite the line to specify the property that should be returned. Using "default properties" is considered bad practice anyway, but, sadly, VB6 users rely on it way too much.
|
|
|
|
|
hi how r u ??
sry for botering u , but i need to ask 2 questions
1-how can i compress an image using VB.NET ??????
2-what is the imports system.* that i can use it with this statment:
picturebox.image=system.drawing.image.fromfile(openfiledialog.filename)
|
|
|
|
|
salam ellayan wrote: -how can i compress an image using VB.NET ??????
Most image formats are already compressed, so you're not going to get much more than what's there already. But, like I said, MOST formats... So, which image format are you looking to compress and what are you trying to achieve??
salam ellayan wrote: what is the imports system.* that i can use it with this statment:
picturebox.image=system.drawing.image.fromfile(openfiledialog.filename)
This is a bad line of code, for many reasons, but the answer is the question. It is System.Drawing . If you need the Import for the PictureBox , which you shouldn't, it's System.Windows.Forms .
|
|
|
|
|
i need the VB.net code for the camera program which exists in the pocket pc that drive the picturing and recording applications.
it is important plz
|
|
|
|
|
I repeat my previous question. Not answering it will not change my answer.
|
|
|
|
|
i need to compress jpeg
my main task is to send this picture via GPRS connection to laptop so it is very big so i need a compression technique to acheive it,
then i'll try to send a video .
capturing , streaming then sending
so plz if you have any idea help me
|
|
|
|
|
salam ellayan wrote: i need to compress jpeg
JPEG is already a compressed format. Trying to compress an already compressed file isn't going to get you anywhere.
JPEG uses a "lossy" compression, so the more you compression the image data, the more the image becomes distorted. It also cannot be "reinflated" to it's full previous quality.
|
|
|
|
|
hi
i need something called POCKET PC OCX
if u konow anything about it plz forward it to me
thanks anyway
|
|
|
|
|
There's no such thing. "Pocket PC" is just that, a PC that fits in your pocket. "OCX" is just another term for an ActiveX component.
|
|
|
|
|
I am looking for source code that able to burn audio cd from mp3 files and read audio wave that will be shown as equalizer, I've tried some codes from other sites but it won't work. Can anyone help me? Please
- No Signature Available -
|
|
|
|
|
Hello all,
I'm trying to create a user login verification for my Window Form Application using VB.NET 2003 connect with MySQL 5.0 database.
When the login form load,I have load all the USERID,USERNAME and USERPASSWORD into a dataset and put into a datatable name"cashier"
shown inside my code below:
ObjConn = New OdbcConnection(Connect())
ObjComm = New OdbcCommand("SELECT * FROM pos_cashier WHERE LocationCode='" & TerminalLocate & "'", ObjConn)
ObjConn.Open()
ObjAdapter.SelectCommand = ObjComm
ObjAdapter.Fill(DS, "cashier")
DT = DS.Tables("cashier")
ObjConn.Close()
Now I need someone can guide me how to select a row or column inside this datatable so I can check the user login name and password
are same with what inside this cashier datatable which used to authorise user login. What I wish to do is something as follow:
If textbox1.text = datatable.cashier.USERNAME Then
If textbox2.text = datatable.cashier.USERPASSWORD Then
UserloginSuccess = True
Dim MainForm as new MainForm
Me.Hide()
MainForm.Show()
Else
Messagebox.show("Sorry,Wrong Password")
End If
Else
Messagebox.Show("Sorry,Username not available on the system.")
End IF
Anyone can give me some help about selecting this datatable?
Thank you for reading.
Regards
Drex
|
|
|
|
|
You can use DataTable.Select() method. It returns DataRow array.
drexler_kk wrote: When the login form load,I have load all the USERID,USERNAME and USERPASSWORD into a dataset and put into a datatable name"cashier"
It's bad design.
Why don't you do user verification in the database when user clicks the login button ? When you are loading all the data to dataset on form load, your application will take long time to load when there are more number of users.
|
|
|
|
|
Sorry,can you give me some sample how should I used this DataTable.Select() method?
Hello Navaneeth,
I have try to change it to the following code but it doesn't work.
For i = 0 to DT.Rows(i).Count - 1
If Test =DT.Select("USERNAME='"& textbox1.text &"'")(i) Then
If DT.Select("USERPASSWORD='" & textbox2.text &"'")(i) Then
UserloginSuccess = True
Dim MainForm as new MainForm
Me.Hide()
MainForm.Show()
Exit For
Else
Messagebox.show("Sorry,Wrong Password!")
End If
Else
Messagebox.show("Sorry,Username not available on ths system.")
End If
Next
The code above can't work. Can you tell me how to fixed it?
Besides,what do you mean by do the user verification in the database? You mean directly use a SELECT statement which depend on the username and userpassword from the server to check if the server have the username with the right password??
Thanks for reading everyone,hope to hear from you all again soon.
Regards
Drex
|
|
|
|
|
If you look at the documentation[^], it would be easy.
drexler_kk wrote: For i = 0 to DT.Rows(i).Count - 1
No need of loop here. Select() returns a DataRow array.
drexler_kk wrote: If Test =DT.Select("USERNAME='"& textbox1.text &"'")(i) Then
This is wrong. Test =DT.Select("USERNAME='"& textbox1.text &"'") . Test should be DataRow array.
drexler_kk wrote: Besides,what do you mean by do the user verification in the database? You mean directly use a SELECT statement which depend on the username and userpassword from the server to check if the server have the username with the right password??
Yes. That would be faster than the method you are using. When user clicks on the login button, supply the user details entered to the database. Run a query to select the details. If everything is OK, proceed with login, else display error.
Hope this helps
|
|
|
|
|
Hello Navaneeth,
Yeah,thanks my friend. I have solve this problem by checking the site you provide. Thank You so much for the information and advice share me.
Have a wonderful day.
Regards
Drex
|
|
|
|
|