|
Hi
If you are using the borderstype = none means VB disable the maximised and minimised property so you have to make it enable
Tushar kothari
|
|
|
|
|
Hi Friends,
I need the code to open cash drawer either it will be connected in COM or Serial Port.
Below this code is working VB 6.0.
Open "LPT1" For Output As #1
Print #1, Chr$(27); Chr$(112); Chr$(0)
Close #1
I need the code in VB.NET. Any can change the code to .NET.
Thank's in advance,
Senthil V.
|
|
|
|
|
I believe there is a serial port class in .NET 2.0. But it's new there, so are you using 2.0 or not ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
No we are using .NET 1.0.
|
|
|
|
|
Which port is this drawer connected to? In your original post, you said you wanted the serial port, but yet the code you poasted says its on the Parallel port. There will be a HUGE difference in the two procedures used to send raw data to the drawer based on which port it's connected to.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
how to pass parameter from my windows form to cyrstal report that depend on sql stored procedure
i am using vb.net framework-1.1
|
|
|
|
|
Hi. How can I convert bitmap to JPEG in VB 6.0? Is there any component available?
Thanks in advance
|
|
|
|
|
It's about 5 lines of C++ on a system with GDI+ available, perhaps you could make one ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Can any one tell me the consequences when this devenv.exe gets corrupted due to which type of controls.
Rekha
|
|
|
|
|
What? Would the program itself get corrupted just because you use a specific control in the designer? Do you have any source to something that points in that direction?
---
b { font-weight: normal; }
|
|
|
|
|
Hi, this is how i open a report inside VB6
Sub CreateReport(SQL As String, MyConnection As Connection, ReportPath As String, _
ReportTitle As String, OpenMethod As Integer)
Dim crApp As New CRAXDRT.Application
Dim crRep As New CRAXDRT.Report
Dim Rs As New ADODB.Recordset
On Error GoTo Err_Proc
With Rs
.CursorLocation = adUseClient
.Open SQL, MyConnection, adOpenKeyset, adLockReadOnly
.ActiveConnection = Nothing
If .RecordCount > 0 Then
Set crRep = crApp.OpenReport(ReportPath, OpenMethod)
crRep.Database.SetDataSource Rs
' crRep.Database.LogOnServer "C:\SUKI\Support\crystal\Pdlsql.dll", gStrServer, gStrDatabase
crRep.ReportTitle = ReportTitle
With frmReportViewer
.Caption = crRep.ReportTitle
.WindowState = vbMaximized
.CRViewer.ReportSource = crRep
If OpenMethod = 0 Then 'print directly to printer
crRep.PrintOut False, 1, True
Else
.CRViewer.ViewReport '1=show print layout to user
.Show vbModal
End If
End With
Else
MsgBox "Record(s) not found.", vbExclamation, App.Title
End If
.Close
End With
Set Rs = Nothing
Set crRep = Nothing
Set crApp = Nothing
Exit Sub
Err_Proc:
Call ErrMsg
End Sub
Am i forgetting something cause my report is not working. "physical database not found" is always its error.
geboy
|
|
|
|
|
Hi
If you remove the line .ActiveConnection = Nothing then you problem may get solved
Tushar kothari
|
|
|
|
|
Hi, im having problem with crystal reports 8.5
I've installed a CRM program. the installation is successful but when i tried to run the report an error "physical database not found" occured." I have included all the possible dll's that is needed in the package but still its not working.
what should I do? please help.
geboy
|
|
|
|
|
why dont you use crystal instead. heres the function. hope this would help
Sub CreateReport(SQL As String, MyConnection As Connection, ReportPath As String, _
ReportTitle As String, OpenMethod As Integer)
Dim crApp As New CRAXDRT.Application
Dim crRep As New CRAXDRT.Report
Dim Rs As New ADODB.Recordset
On Error GoTo Err_Proc
With Rs
.CursorLocation = adUseClient
.Open SQL, MyConnection, adOpenKeyset, adLockReadOnly
.ActiveConnection = Nothing
If .RecordCount > 0 Then
Set crRep = crApp.OpenReport(ReportPath, OpenMethod)
crRep.Database.SetDataSource Rs
' crRep.Database.LogOnServer "C:\SUKI\Support\crystal\Pdlsql.dll", gStrServer, gStrDatabase
crRep.ReportTitle = ReportTitle
With frmReportViewer
.Caption = crRep.ReportTitle
.WindowState = vbMaximized
.CRViewer.ReportSource = crRep
If OpenMethod = 0 Then 'print directly to printer
crRep.PrintOut False, 1, True
Else
.CRViewer.ViewReport '1=show print layout to user
.Show vbModal
End If
End With
Else
MsgBox "Record(s) not found.", vbExclamation, App.Title
End If
.Close
End With
Set Rs = Nothing
Set crRep = Nothing
Set crApp = Nothing
Exit Sub
Err_Proc:
Call ErrMsg
End Sub
geboy
|
|
|
|
|
do you mean linking your adodc to crystal or still in data report?
when closing your report make sure that the object is destroyed like in recordset where we issue "set rs = nothing"
then before opening your report refresh your adodc then
set your datareport as new datareport. likethis
Dim rep as datareport
set rep = new report
adodc.refresh
rep.viewreport
sorry cause im not using datareport but this is how i do it in crystal
geboy
|
|
|
|
|
I have VB.NET Project that is Flash game ,I want to click Buttom and play sound along record in Table
I have simple code sound player but I 'nt know to modify with ADO.NET Data Object .
------------------------------------------------------------------------------------------------------------------
simple code play sound
Public Sub Play()
' If a file name has been registered, call WCE_PlaySound,
' otherwise call WCE_PlaySoundBytes.
If Not (m_fileName Is Nothing) Then
WCE_PlaySound(m_fileName, IntPtr.Zero, Fix(Flags.SND_ASYNC Or Flags.SND_FILENAME))
Else
WCE_PlaySoundBytes(m_soundBytes, IntPtr.Zero, Fix(Flags.SND_ASYNC Or Flags.SND_MEMORY))
End If
End Sub
Private Sub btnFile_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnFile.Click
Dim sound As New Sound("Program Files\SoundSample\chord.wav")
sound.Play()
End Sub
-------------------------------------------------------------------------------------------------------------------------------
Thankyou very....
poaj
|
|
|
|
|
Hello all,
Does anyone know how to change a folders icon programatically? I want to be able to replace a folders icon when I click a button.
Thanks!
|
|
|
|
|
I believe the icon for a folder is set by a config file inside the folder. Sorry, I don't recall the details, but assuming I am right, creating/changing that file would be what's needed.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
OK, got it. You need to create a system file called Desktop.ini inside the folder. Here are the contents of the one I created:
[.ShellClassInfo]
IconFile=%SystemRoot%\system32\SHELL32.dll
IconIndex=11
You can right click on a folder and set it's icon, then you need to go into the folder and specify you want to see hidden system files, in order to see the desktop.ini file.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
|
Hi,
I am developing a vb.net cinema ticket booking system. The application is to have the option to let the user to choose which language he wants the application interface to be in. (Either English or Mandrain)
How should I go about changing the language to display?
|
|
|
|
|
I wrote a very simple program that has a sort off similarity.
I made custom controls that access background files that are changeable by another part of the program to more languages or correct spelling mistakes.
Control <----->Class <-------> File: XML/DB(Any type that u can use):confused:
In the Database the tables will look something like this
<code>Language </code>1:Many <code>Caption </code> Many:1 <code>Words</code>(Default Language) :confused: X|
I linked the captions to the system settings file for faster and user diffraction settings for different users and machines.
Hope it helps; Basic fast and relaible
|
|
|
|
|
Do not make custom controls or something like that. All major software products are localized, and hence multi lingual applications are obviously supported by the framework. Unfortunately it's made a bit goofy, but it is still better than a custom solution (as the translation tools work around the goofiness - more or less).
Search for "localization" on Google, here on Codeproject etc for information on how to do it for WinForms, ASP.NET (1.1 and 2.0 differs a bit - most of it is manual in ASP.NET 1.1).
|
|
|
|
|
i need to know how can i make automatic languages translation to my application, for exaple caption on labes and command button, messages etc...
Magno R Vasquez (Gbyte)
|
|
|
|
|
You can get some childish translation though various commercial packages (no, I can't give examples, I have not looked at this for years and you can google "machine translation" as well as I can). They can be useful if you need the user to get an understanding what the text PROBABLY means, nothing more. You might get a semi decent result if you are in a VERY restricted domain (for example it knows all words are related to cars, manufactoring, weather, etc). For anything else, you can just hope the users find the text so amusing that they laugh instead of hunting you down and killing you.
|
|
|
|