|
Hi All,
I am new to TAPI and MSComm.I will be greatful if you could
spare some time for me to help me in this regard.
Problem:
I need my phone to go OffHook and OnHook using Visual Basic.
I am able to collect the Device Info(D-Link DFM562E++ Modem)
using my code.
I have read somewhere that,
'You could try doing a lineMakeCall() with a ";" dial string. I
believe this should take the phone off hook and create a new dialtone
call. It may timeout after some time and transition to IDLE or you
may be able to drop it with lineDrop'
I tried this but it didnt work.
I placed one MSComm control and :
MSComm1.Settings = "56000,N,8,1"
MSComm1.CommPort = 2
MSComm1.InputLen = 0 'Default anyway
MSComm1.RThreshold = 1
MSComm1.PortOpen = False
MSComm1.Output = "ATE0" & vbCr
But there was no Offhook Signalling sound generated.
Can anybody please suggest me a solution for this
Thanks
Nishanth
|
|
|
|
|
Hello! I have a picturebox1 and its sizemode is set to strechimage. So the actual image size is bigger than the picturebox1 size. My aim is to draw the image as big as picturebox1 size as streched to see all image not a part of the image. Somethig is wrong in the code below because it only draws the area (Picturebox1 size) of the image. I am not able to scale the image.
Any help!
Thanks!
BJ
Private Function DrawImageCallback(ByVal callBackData As IntPtr) As Boolean
'Test for call that passes callBackData parameter.
If callBackData.Equals(IntPtr.Zero) Then
' If no callBackData passed, abort DrawImage method.
Return True
Else
' If callBackData passed, continue DrawImage method.
Return False
End If
End Function
' Copy the watermark image over the result image.
Private Sub DrawWatermark(ByVal watermark_bm As Bitmap, _
ByVal result_bm As Bitmap, ByVal x As Integer, ByVal y As Integer)
Dim imageCallback As New Graphics.DrawImageAbort(AddressOf DrawImageCallback)
Dim imageCallbackData As New IntPtr(1)
' Create rectangle for adjusted image.
Dim destRect2 As New Rectangle(PictureBox1.Location.X, PictureBox1.Location.Y, PictureBox1.Width, PictureBox1.Height)
Dim es As Graphics = Graphics.FromImage(result_bm)
' Create image attributes and set large gamma.
Dim imageAttr As New ImageAttributes()
'imageAttr.SetGamma(4.0F)
' Draw adjusted image to screen.
' Draw adjusted image to screen.
es.DrawImage(watermark_bm, destRect2, PictureBox1.Location.X, PictureBox1.Location.Y, PictureBox1.Width, PictureBox1.Height, GraphicsUnit.Pixel, imageAttr, imageCallback, imageCallbackData)
imagination is the seed value of creation!
|
|
|
|
|
Private Function DrawImageCallback(ByVal callBackData As IntPtr) As Boolean
'Test for call that passes callBackData parameter.
If callBackData.Equals(IntPtr.Zero) Then
' If no callBackData passed, abort DrawImage method.
Return True
Else
' If callBackData passed, continue DrawImage method.
Return False
End If
End Function
' Copy the watermark image over the result image.
Private Sub DrawWatermark(ByVal watermark_bm As Bitmap, _
ByVal result_bm As Bitmap, ByVal x As Integer, ByVal y As Integer)
Dim imageCallback As New Graphics.DrawImageAbort(AddressOf DrawImageCallback)
Dim imageCallbackData As New IntPtr(1)
' Create rectangle for adjusted image.
Dim destRect2 As New Rectangle(PictureBox1.Location.X, PictureBox1.Location.Y, PictureBox1.Width, PictureBox1.Height)
Dim es As Graphics = Graphics.FromImage(result_bm)
' Create image attributes and set large gamma.
Dim imageAttr As New ImageAttributes()
'imageAttr.SetGamma(4.0F)
' Draw adjusted image to screen.
' Draw adjusted image to screen.
es.DrawImage(watermark_bm, destRect2, PictureBox1.Location.X, PictureBox1.Location.Y, PictureBox1.Width, PictureBox1.Height, GraphicsUnit.Pixel, imageAttr, imageCallback, imageCallbackData)
|
|
|
|
|
hi. i'm a new bie in vb.net. I'm currently developing a multilingual project. I'm unable to change the regional language settings when the current thread changes from one language to the other. If anybody could help me, please find a solution for this.
-Ganesh Pradeep.R
|
|
|
|
|
hi dear friends programmers
i need a program or some code such as an email in windows form vb.net that i want the clients can send and receive file from eachother in the lan in one department.
i am not master in vb.net and i have to solve this problem immediately.
please help me . untile now i cant find functional and good code for it to use.
thanks alot for your care and help.
(i use visual studio 2003)
i am await for your helps....
pantea
|
|
|
|
|
Look up System.Web.Mail.SmtpMail/MailMessage classes. They have methods and properties that allow you to specify attachments/relay server etc.
- Malhar
|
|
|
|
|
Hi And Thanks for your care
but iam new in programming vb.net and really i dont know how to use or make it.
please describe more ,if you can
thanks alot
|
|
|
|
|
The following code in VB shows the error : "Undefined function 'round' in expression".
[CODE]
DataEnvironment1.Commands(1).CommandText="Select Round(Altitude,2) from Alt"
[\CODE]
Here, Altitude is a variable of type 'Number-Double'
Alt is a table in MS-Access Database.
Help me regarding this.
Thanks in advance.
-- modified at 2:18 Wednesday 1st February, 2006
|
|
|
|
|
Try:
DataEnvironment1.Commands(1).CommandText="Select Round(" & Altitude & ", 2) from Alt"
|
|
|
|
|
Altitude is not a variable used in VB. Altitude is a Field in table Alt.
|
|
|
|
|
I tried using Round in a query in Access, and that works fine, just as expected.
Are you sure that it is an Access database that the connection is connecting to?
Are you sure that the query that you have shown is causing the error? The code you show can never cause that error by itself, there has to be som code that runs the query also.
---
b { font-weight: normal; }
|
|
|
|
|
It is in access database only.
I am getting the values if i use the query without using round function.
It is showing error when i use the round function
|
|
|
|
|
What is the complete error message?
What databasedriver are you using, e.g. what does your connectionstring look like?
---
b { font-weight: normal; }
|
|
|
|
|
Error Message : "Undefined function 'round' in expression".
Connection String : Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Premalatha\30_01_06-VrefAnalysis\VrefAnalysis.mdb; Persist Security Info=False
Database Driver : Microsofy.Jet.OLEDB.4.0
-- modified at 7:07 Wednesday 1st February, 2006
|
|
|
|
|
PremalathaP wrote: Select Round(Altitude,2) from Alt
Try:
SELECT ROUND(Alt.[Altitute], 2) FROM Alt
|
|
|
|
|
Does anyone know how to capture webcam images using avicap32.dll and not save the images to the clipboard. I would like to be able to actually stream the images 'into' the a picture box or any other control capable of holding an image, and then retrieve an image at any given time by way of the Image property. I do not want to use the clipboard because in my app a user may be using it for other things such as text editing, etc.. I have used DirectShow but avicap32.dll in my case would be better suited.
Any help at all would be appreciated.
-Jason
|
|
|
|
|
|
My whole post was about avoiding the clipboard, when reading the documentation, it says there are alternatives to the clipboard, but i have yet to make any of them work.
Since my app should allow for text editing in other areas of the app, I do not want to use the clipboard, for this reason...
I was using the clipboard to start, but then when testing, i realized that I was losing some stuff that I had copied and had been replaced with an image.
So then I decided as a workaround to right before I save the image to clipboard, I would copy the contents in the clipboard to memory, then send the image to it, retrieve the image back, then reset the contents of the clipboard back to its original contents. Most of the testing I did like this worked ok, but every now and then, the contents would get mixed up and where it should be saving an image it was saving text that was copied into the clipboard and vice versa.
The documentation states that you can save it to some sort of an independant bitmap, but I do know how to go about doing that.
Any suggestions?
-Jason
|
|
|
|
|
|
Thanks for the link, but I had already found that and it like many others use the clipboard for capturing still shots. For example, that articles code for the function to capture an image uses...
'---copy the image to the clipboard---
SendMessage(hWnd, WM_CAP_EDIT_COPY, 0, 0)
'---retrieve the image from clipboard and convert it
' to the bitmap format
data = Clipboard.GetDataObject()
I have found an alternative to that scheme but now I am having problems forcing that window to paint it self or atleast think it is painted when it is hidded, as sometimes i get a black capture image.
-Jason
|
|
|
|
|
hello,
i am making use of table control and when i am creating a new cell ia setting colors ,height,width dynamically but it is not effecting please can anybody tell how to convert table cell string into float i have used convert function but it is showing me error
thanks & regards
Nagalakshmi
|
|
|
|
|
Your request does not make any sense. Perhaps it would be better if you split it up to use many sentences instead of one very long sentence.
ColinMackay.net
"Man who stand on hill with mouth open will wait long time for roast duck to drop in." -- Confucius
"If a man empties his purse into his head, no man can take it away from him, for an investment in knowledge pays the best interest." -- Joseph E. O'Donnell
|
|
|
|
|
My comp is a Product based company,i have developed a project in VB.NET,i need to include my project in our existing product.I dont have that much space to include .NET Framework into the package. Is't sufficient that only with the supporting DLL's to run the project,so that no need to include .NET framwork inside the package
Sathiyaraj Ganesan
|
|
|
|
|
Sathiyaraj Ganesan wrote: Is't sufficient that only with the supporting DLL's to run the project,so that no need to include .NET framwork inside the package
I really don't know where some of you guys who ask such questions get the idea that you can take short cuts like this
You have developed a program in VB.NET - right? VB.NET uses the .NET Framework - right? The 'supporting DLLs' ARE the framework - right? Ergo you need the .NET Framework on the client machines - right?!
If it is not already installed, you need to get the user to somehow install it - whether you include this in your distributable package or not (if permissable by your Microsoft agreement) or let the user download it from Microsoft is irrelevant. You MUST have the framework to run your program.
...Steve
"Give a man a fish and you've fed him for a day. Teach him how to fish and you've fed him for life." (Translation: I'll show you the way, but not write the code for you.) I read that somewhere once
|
|
|
|
|
What kind of media that you are going to distribute? CD-ROM or post on the web? If you distribute via the CDROM and the size is not enough then, distribute it into 2 CDROM and make your installation process require for disk 1 and disk 2.
|
|
|
|