Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Ok heres the thing...

 

I am creating a text box style control. When adding a 'Text' property as a string all works well however i have created a 'lines' property as a string array and set the values at design time, if I build the solution it clears the contents :mad:

 

I have tried two methods of implementing this but the result is the same

 

 

Private MyLines() As String

Public Shadows Property Lines() As String()

Get

Return MyLines

End Get

Set(ByVal Value As String())

MyLines = Value

Me.Refresh()

End Set
End Property

And...

 

Private MyLines As String

Public Shadows Property Lines() As String()

Get

Return Split(MyLines, vbCrLf)

End Get

Set(ByVal Value As String())

MyLines = Join(Value, vbCrLf)

Me.Refresh()

End Set
End Property

anyone any ideas where i am going wrong?

 

Thanks in advance

 

Dill

Posted

Worked a treat!

 

had to read it twice tho!

 

and my appologies for duplicating a thread (impatience on first post i suppose :D)

 

thanks again

 

Dill

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...