Search found 63 matches
- by SumCode
- Mon Dec 22, 2014 7:25 pm
- Forum: Coding Help & Support
- Topic: Multi-Threading - problem
- Replies: 6
- Views: 2283
So what I am saying is that instead of creating a new delegate (in your case 'NoteDelegate') you can use a pre made delegate called MethodInvoker . So where you wrote Me.Invoke(New NoteDelegate(AddressOf Note)) one could write Invoke(New MethodInvoker(AddressOf Note)) Not that big of a deal though. ...
- by SumCode
- Mon Dec 22, 2014 6:10 pm
- Forum: Coding Help & Support
- Topic: Multi-Threading - problem
- Replies: 6
- Views: 2283
I'm also a noob with multi-threading in VB.NET, but from this link , this is what I understand should be used: Dim Note = New Thread(AddressOf Note) Private Delegate Sub NoteDelegate() Private Sub Note() If Me.InvokeRequired Then Me.Invoke(New NoteDelegate(AddressOf Note)) Else Try Dim TXT1 As Stri...
- by SumCode
- Mon Dec 22, 2014 4:39 pm
- Forum: Tutorials
- Topic: Python Basics: String Formatting
- Replies: 2
- Views: 8629
Also, if I remember correctly, you can format strings using '%s'. So like this
Code: Select all
IMO this method is much simpler than 'str.Format', however, I also think that this method isn't as powerful in capabilities in comparison.print 'The cat is %s the bag' % 'out'
- by SumCode
- Thu Dec 18, 2014 12:17 am
- Forum: Coding Help & Support
- Topic: listbox/textbox help
- Replies: 6
- Views: 2245
Very sorry for taking so long to reply had a busy... How to use the regex : Ok so to explain to you the Regex, lets say you receive this text: shopkeeper.admin Create and modify admin shops. op-only shopkeeper.bypass Modify player shops that you do not own. op-only shopkeeper.reload Use the /shopke...
- by SumCode
- Tue Dec 16, 2014 2:51 pm
- Forum: Coding Help & Support
- Topic: listbox/textbox help
- Replies: 6
- Views: 2245
Am I the only one who gets confused by regex?, its like sitting through a quantum physics class. Some type of mathematical formula for solving the mysteries of the universe :lol: I don't know. For me I saw an great importance in learning regex so I went to learning it. The way I learn is through my...
- by SumCode
- Tue Dec 16, 2014 5:10 am
- Forum: Coding Help & Support
- Topic: listbox/textbox help
- Replies: 6
- Views: 2245
I think what you're trying to do is get the values using Regex. And although I don't know exactly what you want, I'll post Regex for each value I think you're trying to receive. ^((?:\.?<?\w+>?\.?)+) // For the shopkeeper values ((?:\-?\w+)+)$ // For the op-only, everyone, and none values (?:\.<?\w+...
- by SumCode
- Sun Nov 30, 2014 9:09 pm
- Forum: Coding Help & Support
- Topic: [HELP] Chross-Thread PictureBox PointToScreen
- Replies: 10
- Views: 3685
yes i save graphics from g, where g is printscreen from rectangle where i put picture box. So if i put picturebox top left with height 50 and width 50, it will save it top left screen(it take picture from picturebox). If i put middle of screen so it will take it too. But with lambda expresion, it t...
- by SumCode
- Sat Nov 29, 2014 6:57 am
- Forum: Coding Help & Support
- Topic: [HELP] Chross-Thread PictureBox PointToScreen
- Replies: 10
- Views: 3685
albertuschw wrote: yes it is not error anymore, but it is not work like before... hmm any idea what happen? dunnno;Well it really depends on what you mean by 'it doesn't work like before'. Is something supposed to be happening? As far as I know all your code does is store the graphics from the screen in 'g'
- by SumCode
- Thu Nov 27, 2014 10:05 pm
- Forum: Coding Help & Support
- Topic: [HELP] Chross-Thread PictureBox PointToScreen
- Replies: 10
- Views: 3685
So under a Backgroundworker work event you can write: Invoke( DirectCast(Sub() Using bitmap As New Bitmap(CameraView.Width, CameraView.Height) Using g As Graphics = Graphics.FromImage(bitmap) ' Get the paramters to call g.CopyFromScreen and get the image Dim rectanglePanelVideoPreview As Rectangle ...
- by SumCode
- Wed Nov 26, 2014 7:29 pm
- Forum: Coding Help & Support
- Topic: [HELP] Chross-Thread PictureBox PointToScreen
- Replies: 10
- Views: 3685
So under a Backgroundworker work event you can write: Invoke( DirectCast(Sub() Using bitmap As New Bitmap(CameraView.Width, CameraView.Height) Using g As Graphics = Graphics.FromImage(bitmap) ' Get the paramters to call g.CopyFromScreen and get the image Dim rectanglePanelVideoPreview As Rectangle =...
Copyright Information
Copyright © Codenstuff.com 2020 - 2023