D
**Developer**
Public Shared Sub junk...
Dim PF2 As Wnd.PARAFORMAT2
PF2.cbSize = Marshal.SizeOf(PF2) 'ERROR HERE
PF2.dwMask = Wnd.PFM_LINESPACING
....snip
I just converted a solution to VS2005 and it is complaining:
Warning 22 Variable 'PF2' is used before it has been assigned a value. A
null reference exception could result at runtime. Make sure the structure or
all the reference members are initialized before use
How do I initialize PF2.
Each of its members?
What is the rational for requiring initialization - simply to document what
the developer wanted?
Thanks
Dim PF2 As Wnd.PARAFORMAT2
PF2.cbSize = Marshal.SizeOf(PF2) 'ERROR HERE
PF2.dwMask = Wnd.PFM_LINESPACING
....snip
I just converted a solution to VS2005 and it is complaining:
Warning 22 Variable 'PF2' is used before it has been assigned a value. A
null reference exception could result at runtime. Make sure the structure or
all the reference members are initialized before use
How do I initialize PF2.
Each of its members?
What is the rational for requiring initialization - simply to document what
the developer wanted?
Thanks