|
You could do something like the following to access the 'RecieveFile' public method...
CType(newForm,frmFileInfo).RecieveFile(filename,True)
Of course, if you can you should simply declare newForm as frmFileInfo instead of as Form, then you could avoid the CType.
|
|
|
|
|
Why not create a constructor that has the FileName etc as parameters
eg.
Public Sub New(ByVal Filename as string, Byval Flag as Boolean)
InitializeComponent()
RecieveFile(Filename, Flag)
End Sub
Steve Jowett
-------------------------
It is offen dangerous to try and see someone else's point of view, without proper training. Douglas Adams (Mostly Harmless)
|
|
|
|
|
Is there a way to monitor resources using any tools with Visual Studios. I have created Stream Readers and Writer but wan to see if they are being closed. Is there a way to do this?
|
|
|
|
|
There's nothing with Visual Studio, but you could Google for "Process Monitor" and find a free one on MS's site that will let you track all file operations for any file.
|
|
|
|
|
Hiii
I want to create a array of panel at run time using vb.net.how will i do this. Please suggest.
Thanx
~Khatri Mitesh
|
|
|
|
|
You have Panel class and can make its objects, so create it...simple
|
|
|
|
|
This is so obviously simple, why can't you figure out how to do it?
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
The form designer in the Visual Studio versions for .NET doesn't support control arrays.
There is basically two ways of getting the controls in an array:
1. Put the panels on the form as usual, then create an array that contains references to the panels:
Dim thePanelArray() As Panel = { Panel1, Panel2, Panel3 }
2. Declare the array, then create the panels in a loop an put them on the form:
Dim thePanelArray(2)<br />
For i = 0 to 2<br />
Dim p As New Panel()<br />
p.Location = New Point(10, 10 + i * 30)<br />
thePanelArray(i) = p<br />
Next
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Hi Guffa,
I had a similar issue which i had solved as the first method. But my problem was that the number of text boxes which i wanted in the array was deferent every time.
Now i am planing to use the second method which u had told. I tried it in a test application but was not able to
Guffa wrote: then create the panels in a loop an put them on the form:
Can you plz help me out..
Regards
Nishkarsh
modified on Tuesday, July 15, 2008 4:07 AM
|
|
|
|
|
Your next question will be how do I manage these panels in a form IE place them where I want them. Take a look at the flowcontrol and think custom control instead of panel
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
--> i want to store an image in a database not by saving its path as string but an image as image... How will i do this using vb.net..?
J A Nasir K
|
|
|
|
|
Hii
If you are using Access data base create a field for store image data type is OleObject. and Convert image in Binary format and try to save in data base.
May this solve your problem
Thanx
~Khatri Mitesh
|
|
|
|
|
first change the image into byte array as following
Public Function imageToByteArray(ByVal ImageIn As System.Drawing.Image) As Byte()<br />
Dim ms As MemoryStream = New MemoryStream()<br />
ImageIn.Save(ms, Imaging.ImageFormat.Bmp)<br />
Return ms.ToArray()<br />
End Function
and store this binary data into data
and for convert byte array to image use following
Public Function ByteArrayToimage(ByVal ImageArray As Byte()) As Image<br />
Dim ms As MemoryStream = New MemoryStream(ImageArray)<br />
Dim ReturnImage As Image = Image.FromStream(ms)<br />
Return ReturnImage<br />
End Function
hope this helps
|
|
|
|
|
Thank you so much. your solution is useful
|
|
|
|
|
i need a video streaming code written in VB.NET applicable on pocket pc.
|
|
|
|
|
..or someone to do your work for you. Write your code, then when it fails, post it for help.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Hi all,
i have develeped a large application in vb6 some years ago and it is runnig perfectly.
now i want to install this application on a machine having Vista.But i could not install it.
Kindly Suggest me the solution.
thanks
rmshah
Developer
modified on Monday, July 14, 2008 4:56 AM
|
|
|
|
|
Firstly you said it well
Years ago.
My Friend this is Year 2008, and Microsoft dont recomend Developers to initiate Development on vb6 and Continue enhancing vb6 aplication because vb6 is Dead , microsoft dont Support it anymore. Most of the People posting questions here , they ask us how to convert those vb6 applications to .NET, thats when we come in, but first you need to show us how far have you gone before we can help you, remember we cannot do your job , you have to do it and get Stuck and we will help you. Look Windows 98 and Look at Vista , are they the Same? No , if so now you have to start writting code that will be Compatable with Vista , is eaither you buy a Book on C#.NET or VB.NET.
Am Sorry vb6 is Doomed.
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
Vuyiswa Maseko wrote: Am Sorry vb6 is Doomed.
Doomed - nah dead, buried, rotting corpse with white gooey things crawling through it.
I am continually astonished at the number of VB6 questions raised in this forum. I can understand support needs but some of them are development questions!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
well it is burried and Dead
Thank
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
hi Vuyiswa Maseko,
Thanks a lot for replying, here i would like to share my new experience that i have done.
i installed VB6 on a machine having Vista and upgraded it with service pack 6 of VB6, placed all codes of my application on it and compile it and make a package which installed successfylly on a second machine having vista.now my application compatible to vista and working perfectly.
Thanks
rmshah
Developer
|
|
|
|
|
hi r_mohd
Thats nice, but still remember you need to rewrite you vb6 app to .net.
Am glad you got a Solution.
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
Hi all...
I am trying to write to a mapped network drive. Firstly creating Directories and then writing to them. The creation process fails and gives me System.IO.DirectoryNotFoundException. I'm thinking that it doesn't pick up the drive but I have no idea what to check except for sucurity settings (which seem fine). If anybody has done this before help would be appreaciated...
Tx
Steve
Stephen Lintott Bsc IT (RAU)
|
|
|
|
|
I found the pkroblem. Here is the thing. The app doesn't see drives that are mapped unless it mapped the drives itself...
Stephen Lintott Bsc IT (RAU)
|
|
|
|
|
If your app is run by a user logged in at the machine, it will inherit the users operating environment, including all mapped drives.
If your app is running as a service, it will NOT get any of the mapped drives that the user sees.
|
|
|
|