Search Results

Showing results 1 to 40 of 710
Search took 0.04 seconds.
Search: Posts Made By: Teme64
Forum: VB.NET Aug 7th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Add declaration
Dim ImageByteArr(0) As Byte ' An array to hold image (bytes)
right before calling
Image2Byte(DrawingForm.BitmapCanvas, ImageByteArr)
' and after that
SaveByteArray(ImageByteArr,...
Forum: VB.NET Aug 7th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
No. Just more debugging needed.

Here's the same code with four messagebox "dumps" added
Public Sub Image2Byte(ByVal NewImage As Image, ByRef ByteArr() As Byte)
'
Dim ImageStream As...
Forum: VB.NET Aug 6th, 2009
Replies: 4
Views: 400
Posted By Teme64
No, it isn't because your WindowsApplication2.exe instance is already running.

You could use sockets (http://msdn.microsoft.com/en-us/library/system.net.sockets%28VS.80%29.aspx) for inter-process...
Forum: VB.NET Aug 5th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Yes, the image isn't saved correctly. Did you use adatapost's code (Post #9 in Saving Drawing on PictureBox to SQL Database (http://www.daniweb.com/forums/post911402-9.html)) for saving the image?
...
Forum: VB.NET Aug 5th, 2009
Replies: 8
Views: 522
Posted By Teme64
You did write your own icon library, right? Are you sure your DLL contains valid resources i.e. ico-files?

I still suggest taking a look at Retrieving Resources in Satellite Assemblies...
Forum: VB.NET Aug 4th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
I made a mistake in previous post. The code should have been
' Loads the image to the picture box control from SQL Server
Dim ImageByteArr(0) As Byte ' An array to hold image (bytes)
Dim patientIC...
Forum: VB.NET Aug 4th, 2009
Replies: 9
Views: 508
Posted By Teme64
Nothing to do with arrays.

I slightly modified the code
Else
g = l1.CreateGraphics
s = g.MeasureString(array1(j) & ": " & frag_des(1, d), l1.Font)
g = Nothing
l1.Height =...
Forum: ASP.NET Aug 3rd, 2009
Replies: 6
Views: 368
Posted By Teme64
Change
If ckbox.Selected = True Then

to
If ckbox.Checked Then

I think that's what you want.

HTH
Forum: C# Aug 3rd, 2009
Replies: 2
Views: 253
Posted By Teme64
Sorry, wrong forum. Post your question to DaniWeb's C# forum (http://www.daniweb.com/forums/forum61.html).
Forum: VB.NET Aug 3rd, 2009
Replies: 14
Views: 818
Posted By Teme64
Common way to receive email is a POP3 server. .NET doesn't provide a built-in POP3 server so you'll have to write one of your own or get a third-party POP3 server. To get you started, try googling...
Forum: VB.NET Aug 3rd, 2009
Replies: 39
Views: 3,191
Posted By Teme64
I tested your code and it worked fine (Page2 form's code). I had to comment out all the data retrieval for labels to test btnSearch_Click but I don't believe that effects anything.

First, you did...
Forum: VB.NET Aug 3rd, 2009
Replies: 9
Views: 508
Posted By Teme64
That's why you use ReDim Preserve to resize array/matrix and to preserve previously entered data.


First dimension has to be fixed. You can only change the second dimension.

Here's another...
Forum: VB.NET Aug 3rd, 2009
Replies: 8
Views: 755
Posted By Teme64
One way to export data to an (existing) Excel file is to use OleDb (namespace System.Data.OleDb). Check out Connection strings for Excel (http://connectionstrings.com/excel) how to form a proper...
Forum: VB.NET Aug 3rd, 2009
Replies: 9
Views: 508
Posted By Teme64
ReDim works fine unless you have to resize 2-dimensional array more than once and preserve the previous content. That's a limitation by design.

For example
Dim Matrix(,) As Integer

ReDim...
Forum: VB.NET Aug 2nd, 2009
Replies: 9
Views: 508
Posted By Teme64
Yes you can
Dim MyList As New ArrayList()
Dim Arr1() As Integer = {1, 2, 3}
Dim Arr2() As Integer = {4, 5, 6}

MyList.Add(Arr1)
MyList.Add(Arr2)

MsgBox(CType(MyList.Item(1), Integer())(2)) '...
Forum: VB.NET Aug 2nd, 2009
Replies: 8
Views: 346
Posted By Teme64
Just my guess. It's 256 bit AES key. They would be 64 hex characters (like you posted).
Forum: VB.NET Aug 1st, 2009
Replies: 3
Views: 562
Posted By Teme64
Neither did I get this :)

But if you don't know the number of array elements at the compile time, pass it to the constructor of your (partial) class.

I would do something like this
Partial...
Forum: VB.NET Aug 1st, 2009
Replies: 2
Views: 186
Posted By Teme64
Here's a few things to fix first:

- add Option Strict On and Option Explicit On lines at the beginning of vb-file
- line 19: you refer to draggedlabel but you haven't declared it. Is it a label...
Forum: VB.NET Aug 1st, 2009
Replies: 11
Views: 683
Posted By Teme64
Hi danielagaba,
do you still have this problem unsolved? If it is, could you please post your current code? I've installed (finally) VB.NET 2008 so I could try to reproduce your scenario.
Forum: VB.NET Aug 1st, 2009
Replies: 5
Views: 431
Posted By Teme64
Like I said, I'm not (technically) familiar with sending SMS in VB.NET.

One thing you could do, is to check the actual number of Ascii characters
Dim TempStr As String

TempStr =...
Forum: VB.NET Aug 1st, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Just for testing I had a main form (Form1) and a separate drawing form (Form2). You can use just one form. In that case you have to copy the drawing routines from (my) Form2 to your main (drawing)...
Forum: VB.NET Aug 1st, 2009
Replies: 5
Views: 761
Posted By Teme64
Convert currency back to decimal value
Dim Money As Double = 1234.56
Dim MoneyStr As String
MoneyStr = String.Format("{0:C}", Money)

' DEBUG
MsgBox(MoneyStr)

Dim MoneyToUpdate As Double...
Forum: VB.NET Jul 28th, 2009
Replies: 6
Views: 613
Posted By Teme64
I did some googling and found out that InkPicture control does not even have Image property :)

InkEdit control has SaveFile method (see Using InkEdit, InkPicture, and Enhancing the Appearance of...
Forum: VB.NET Jul 28th, 2009
Replies: 5
Views: 431
Posted By Teme64
I haven't ever done SMS sending but noticed one point in your code:
serialPort.Write("AT+CMGS=" & RichTextBox1.Text & vbCrLf & TextBox1.Text & Chr(26)) 'set command message format to textAre you...
Forum: VB.NET Jul 28th, 2009
Replies: 5
Views: 761
Posted By Teme64
Use string classes Format method:
Dim Money As Double = 1234.56
MsgBox(String.Format("{0:C}", Money))

HTH
Forum: VB.NET Jul 25th, 2009
Replies: 6
Views: 613
Posted By Teme64
Ok, here's a step-by-step test which control is not set
If InkPicture1 IsNot Nothing Then
If InkPicture1.Image IsNot Nothing Then
InkPicture1.Image.Save(IO.Directory.GetCurrentDirectory() &...
Forum: VB.NET Jul 25th, 2009
Replies: 8
Views: 522
Posted By Teme64
I guess you didn't use ResourseManager.


Assuming your assembly ends up to same directory as the main executable, you get the path to your dll in this way
Dim StartUpFolder As String
' Get the...
Forum: VB.NET Jul 23rd, 2009
Replies: 8
Views: 522
Posted By Teme64
The code doesn't work "as is". You have to modify it for your purposes like you do with any other sample code. Just drop OpenFileDialog and Picture Box controls on the form.

I didn't test...
Forum: VB.NET Jul 23rd, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Got it. The very basic principle is not to draw on a (picture box) control. Instead, you have to use some in-memory buffer (i.e. bitmap). You draw to the buffer and then display the buffer in the...
Forum: VB.NET Jul 22nd, 2009
Replies: 3
Views: 335
Posted By Teme64
Absolutely not. Arrays in VB.NET are zero based. Index value 6 would give an out-of-bounds error.


The first For Next loop loops first "column" and the second loops second "column". That's...
Forum: VB.NET Jul 22nd, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Damn :-O

Ok, I can think of two options. User drawings should be somehow merged to image before saving. They seem to be separate objects right now. I don't have code for that at the moment but...
Forum: VB.NET Jul 22nd, 2009
Replies: 11
Views: 329
Posted By Teme64
Basically you're readind serial data from COM-port and that is equally easy (or difficult) task with VB.NET, VB6 and C++ (or C#).

Most of your application will deal with other things. Like UI,...
Forum: VB.NET Jul 22nd, 2009
Replies: 11
Views: 683
Posted By Teme64
That didn't happen to me :-/ Nothing was copied to Bin\Debug folder, at least the mdf file wasn't copied at any point of execution of the code. Besides, at the run-time (not in IDE) where would that...
Forum: VB.NET Jul 21st, 2009
Replies: 11
Views: 683
Posted By Teme64
I doubt it. Inserting data to a DB is an elementary thing to do and any bugs would have been fixed by now.


In your code
Dim comm As New SqlCommand("SET IDENTITY_INSERT Housing ON;INSERT INTO...
Forum: VB.NET Jul 21st, 2009
Replies: 3
Views: 335
Posted By Teme64
Your code actually works i.e. midtermLabel and finalLabel variables will hold the desired values.


Your Do-loop is obsolete. The code finds the highest values in the For Next loops (in the first...
Forum: VB.NET Jul 20th, 2009
Replies: 11
Views: 683
Posted By Teme64
Try to dump out insert statement. I also added connection object to data adapter creation
Dim conn As New SqlConnection("Data Source=.\SQLEXPRESS;...
Forum: VB.NET Jul 18th, 2009
Replies: 6
Views: 613
Posted By Teme64
I don't have a tablet PC to test with, but if things work in the same way as with WinForms, your code should be following
InkPicture1.Image.Save(IO.Directory.GetCurrentDirectory() & "\test_out.jpg",...
Forum: VB.NET Jul 18th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
If the code works, don't change it (if it ain't broke, don't fix it, you know ;) ) And like I posted before, Adatapost's code is pretty much same as mine.



I used the same form. That's why I...
Forum: VB.NET Jul 16th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Here's a complete (example) code for saving a picture box control's image to SQL Server and loading it back
Option Strict On
Option Explicit On

Imports System.Drawing.Imaging ' Image related...
Forum: VB.NET Jul 15th, 2009
Replies: 39
Views: 3,191
Posted By Teme64
Here's the repainting code. All the user drawings are saved on the arrays. On the picture box's paint event all the saved user drawings are repainted from the arrays
' "Drawing" arrays
Private...
Showing results 1 to 40 of 710

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC