|
Thanks Steve...ill see wat i can do...thanks again!!
living life on the flip side
|
|
|
|
|
I have a class with a Region property, that I need to serialize/deserialize (using BinaryFormatter)
My class implements ISerializable and uses a second property to do the job
My code so far:
Private Property MyRegionData() As Byte()
Get
Return Me.MyRegion.GetRegionData.Data
End Get
Set(ByVal value As Byte())
Dim reg As New Region
Dim data As Drawing2D.RegionData = reg.GetRegionData
data.Data = value
m_MyRegion = New Region(data)
reg.Dispose()
End Set
End Property
Private m_MyRegion As Region = Nothing
Public Property MyRegion() As Region
Get
Return m_MyRegion
End Get
Set(ByVal value As Region)
If m_MyRegion IsNot Nothing Then
m_MyRegion.Dispose()
End If
m_MyRegion = value
End Set
End Property
Public Sub GetObjectData(ByVal info As System.Runtime.Serialization.SerializationInfo, ByVal context As System.Runtime.Serialization.StreamingContext) Implements ISerializable.GetObjectData
info.AddValue("MyRegion", Me.MyRegionData, GetType(Byte()))
End Sub
Public Sub New(ByVal info As System.Runtime.Serialization.SerializationInfo, ByVal context As System.Runtime.Serialization.StreamingContext)
MyBase.New()
Me.MyRegionData = DirectCast(info.GetValue("MyRegion", GetType(Byte())), Byte())
End Sub
This code works, but i worder if there is a better way to deserialize it.
Region does have a constructor that takes a RegionData, but RegionData doesn't have any public constructor (that's why i use a second region object to get a RegionData).
Thanks for your help
|
|
|
|
|
i have my a program that made from VB and i made it an installer, the program works but it only in june 11 after that i wont work if tha date is not set
i have program made in VB 0.6 and i make and installer but ones i install the program it expire and has reg. code please help
|
|
|
|
|
zero_angel wrote: reg. code please help
No.
"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
|
|
|
|
|
You see you need to explain exacly what you want. you English make it Difficult for us to understand what you want. Please Explain.
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
|
|
|
|
|
Hey
why when i go to declare that ,,
Dim s as System.Management.ManagementObject
,, ManagementObject namespace doesn't exist
thanks ,,
jooooo
|
|
|
|
|
Hi,
before you can use types from System.Management, you must add a reference to the "System.Management" dll.
Right-click your project in the "Solution" pane, and choose "Add Reference...".
|
|
|
|
|
so thanks my friend
now it's ok
jooooo
|
|
|
|
|
I have a textbox that supports only the following alogrthim example.
Where n is a variable number.
AnBnCn.........An
example A3B1C6........A9
How can I do a validation that does not allow that the user to enters Bn after An and
after Bn or An only Cn is ecepted?
Pls can anyone help.
Thank you
|
|
|
|
|
Hi,
provide a KeyDown handler that checks the current content of the TB plus the new key,
and when not acceptable, set both e.Handled and e.SuppressKeyPress true.
if you decide to support text paste (CTRL/V), you must check for that too (you may opt
to do that in the TextChanged handler).
|
|
|
|
|
Hi
please i need to adjust all the DataGrid rows at the same time i am using vb.net 2003 thanks
Mohammad Al Hoss
|
|
|
|
|
|
hi developer
how to chat the two system,but there is located in different location i need the vb.net code.please help me..........
|
|
|
|
|
Hi Pandian062,
dont you know how to use a thing called google? there are lots of examples out there how to do chat apps. it is not the newest concept around.
|
|
|
|
|
csciwiz wrote: know how to use a thing called google?
Welcome to the club
"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
|
|
|
|
|
I have a form that its loading takes several seconds so I use a another form with Graphical objects as a splash . I call the latter one before the former .
it was shown but doesnot show graphical objects so it is a simple form .
please help me .
thanks in advanced . enMahdi.
|
|
|
|
|
We cannot help if we do not see the code behind that Form
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
|
|
|
|
|
I call the forms by these codes .
Dim frmsp As New Form1 ' may splash form with graphical objects
frmsp.MdiParent = Me
frmsp.Show()
Dim frmUser As New FrmUserInfo ' my form that its loading takes several seconds
frmUser.MdiParent = Me
frmUser.Show()
frmsp.Close() 'after showing the form I close the splash .
|
|
|
|
|
but why do you have to Parentme a Form. remove the Statemet in Both the Splash and the user form. you dont need that.A Splsh should not have a arent, it should appear for few seconds and disappear, i suggest you use timer control for it, after its done, mybe you can choose to display an MDI form ythat will be the parent of the forms,but remember that the Splash is out of memory, and dont lie to your selff thinking that if you have written .close method you have dispose it. and try running it again
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
|
|
|
|
|
thanks . my problem was solved .
can you help me if I want to crate a thread and run my second form in a different thread .
|
|
|
|
|
Hii
I want to get the version ( means office 2002,2003 or 2007) of office that are installed on my computer.
Please suggest.
Thanx
~Khatri Mitesh
|
|
|
|
|
Read through the registry and it should show you everything that is installed. How to do this in code is left as a programming exercise
"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
|
|
|
|
|
how to converting windows application to server based application
i did a windows application in vb.net 2.0 which runs for every system
but now i want it to run thru server
i place my application in server
from it every user should access it and run the application
but it is asking the permissions
i dont have idea of converting this application to server based application
plz help me
thanks in advance
vijay
|
|
|
|
|
it is very intresting for me . please tell me how you do that convert .
it is my problem . I have winApps that I want to convert them to server based program .
thanks in advanced . enmahdi. 
|
|
|
|
|
Guys
Lets Understand Something First before we call something a Server , Can you Define what is a Server for me, then i will understand why did you say you want to convert an application to be a Server. Please be very carefull with your terms
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
|
|
|
|