|
Thanks Luc for that clarification! I knew there was something I was missing.
That makes sense now.
|
|
|
|
|
You're welcome.
|
|
|
|
|
Hello !
in vb.net 2010 what references should add on my project , to work with crystal report ?
and what should i import on my form ?
i try to add all references with name starting with " CrystalDecisions....." , but when i try to use import on my form like this :
imports CrystalDecisions.CrystalReports.Engine
imports CrystalDecisions.Shared
imports CrystalDecisions.Windows.Forms
imports CrystalDecisions.ReportSource
i get error on all imports lines : " Namespace or type specified on imports doesn;t contain any public memeber and cannot be found"
what can i do ?
thank you.
|
|
|
|
|
|
Hi,
I need to know how to run an application from a central location?
Thanks and Regards
|
|
|
|
|
Double-click its icon?? Seriously, that's not enough information to go on.
Are you asking how to install it to a network share? How to share files the app needs? ...? ...?
|
|
|
|
|
1) Install software in server : (C:\Program files\MyApp)
2) Share that (C:\Program files\MyApp)
3) Browse that (C:\Program files\MyApp) from client machine
4) Right click on App Icon and click on "Send to Desktop"
5) It will create shortcut on client desktop
6) Run that shortcut.
Make sure that if you are using any database connection then it should connect using IP of Server instead of "local"
Thanks
Dr.Kitanjal
|
|
|
|
|
I have assigned my combo box with the information needed but my code to calculate is not working my button need to compute the total of runners that is added from my .txt, the average age of the runners and the total funds raised. Help would greatly be appreciated, I have been going at this all week, Let me know if you need more info.
Public Class frmContributions
'Class Level Private variables
Private _intLifeOfItems As Integer = 5
Public Shared _intSizeOfArray As Integer = 21
Public Shared _strInventoryItems(_intSizeOfArray) As String
Private _strName(_intSizeOfArray) As String
Private _decAmountRaised(_intSizeOfArray) As Decimal
Private _intAge(_intSizeOfArray) As Integer
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'The Form1 load event reads the inventory text file and fills the Combobox object with the
'inventory items
Dim objReader As IO.StreamReader
Dim strLocationAndNameOfFile As String = "e:\earthdayrun.txt"
Dim intCount As Integer = 0
Dim intFill As Integer
Dim strFileError As String = "The file is not available. Restart when the file is available"
'Verify the file exists
If IO.File.Exists(strLocationAndNameOfFile) Then
objReader = IO.File.OpenText(strLocationAndNameOfFile)
'Read the file line by line until the file in completed
Do While objReader.Peek <> -1
_strName(intCount) = objReader.ReadLine()
_intAge(intCount) = CInt(objReader.ReadLine())
_decAmountRaised(intCount) = Convert.ToDecimal(objReader.ReadLine())
intCount += 1
Loop
objReader.Close()
For intFill = 0 To (_strName.Length - 1)
lstRunners.Items.Add(_strName(intFill))
Next
Else
MsgBox(strFileError, , "Error")
End If
End Sub
Private Sub btnCompute_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCompute.Click
'The btnCompute click event calls the contribution Sub procedures
Dim intCountOfRunners(21) As Integer
Dim intFundsRaised() As Integer = {175.5, 534.0, 1023.0, 655.5, 178.0, 633.0, 135.0,
178.5, 500.0, 122.0, 190.25, 16.0, 721.0, 463.0, 15.0, 189.0, 78.0, 0.0,
602.0, 10.0}
Dim intAges As Integer
Dim intAdd As Integer
Dim intTotal As Integer
Dim decRunners As Decimal
For intAges = 0 To (intCountOfRunners.Length - 1)
intTotal += intCountOfRunners(intAges)
Next
For Each decRunners In intCountOfRunners
lstRunners.Items.Add(decRunners.ToString("C"))
Next
lblCountOfRunners.Text = intTotal.ToString("C2")
lblTotal.Text = (intTotal / intCountOfRunners.Length).ToString("C2")
|
|
|
|
|
First of all, please enclose your code samples in pre tags. This will make your questions much easier to read.
I think this is your problem...
Member 8479418 wrote: Dim intFundsRaised() As Integer = {175.5, 534.0, 1023.0, 655.5, 178.0, 633.0, 135.0,
178.5, 500.0, 122.0, 190.25, 16.0, 721.0, 463.0, 15.0, 189.0, 78.0, 0.0,
602.0, 10.0}
Try changing the Integer type to Double
I don't speak Idiot - please talk slowly and clearly
'This space for rent'
Driven to the arms of Heineken by the wife
|
|
|
|
|
Thanks Andy,
I tried doubles but it did not work, the results reading 0
|
|
|
|
|
Try setting a breakpoint in the code at the place I suggested. Press F5 and the program will stop at the breakpoint.
You will then be able to inspect the values of your variables and track down where the issue is.
I don't speak Idiot - please talk slowly and clearly
'This space for rent'
Driven to the arms of Heineken by the wife
|
|
|
|
|
Hi,
I am trying to fill the gridview with the data from an Access table for a range of dates.
Dim cmd1 As String = "Select * from " & inpTable & " Where mdateTime = '29/09/2011'"
MsgBox("cmd= " & cmd1)
Dim da As OleDbDataAdapter
Try
da = New OleDbDataAdapter(cmd1, myConnection)
Catch ex As Exception ' Catch the error.
MsgBox(ex.ToString) ' Show friendly error message.
End Try
Try
Dim table As New DataTable
da.Fill(table)
DataGridView1.DataSource = table
Catch ex As Exception
MsgBox(ex.ToString)
End Try
myConnection.Close()
Command as it appears in the MsgBox
Select * from rawClimateData Where mdateTime > 30/09/2011 10:45:00 AM
The query works if I am not filtering the data base; however, with filter I get the syntax error "missing operator".
Any suggestion??
|
|
|
|
|
dates are in "sqldateformat"
#mm-dd-yyyy#
Jan
|
|
|
|
|
Rewrite this as a parameterized query and you won't have to worry about what "format" the datetime objects are in.
Just Google for ".NET Sql parameterized query" and you'll find tons of exampels.
|
|
|
|
|
use this will work
Dim cmd1 As String = "Select * from " & inpTable & " Where convert(datetime,mdateTime,101) = convert(datetime,'09/29/2011',101)"
|
|
|
|
|
Hi, I'm trying to ask a "Exit Form?" question when the user clicked red close button at the top right of the form.
If the user clicked No, then the form won't close.
The problem is, i don't know where to put my coding.
I've tried to put it on Form event "FormClosing" but both Yes and No question close the form.
This is the code I use.
Private Sub MainForm_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
If MessageBox.Show("Exit Program ?", "Message", MessageBoxButtons.OKCancel, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2) = Windows.Forms.DialogResult.Cancel Then
Return
End If
Application.Exit()
End Sub
Thank's before..
|
|
|
|
|
FormClosing is the correct event for this. Its second parameter has a Cancel property, if you set that true, the closing action will not go on (and FormClosed will not fire).
BTW: there is no need to call Application.Exit() in a FormClosing or FormClosed event handler (and it sure won't help you in keeping the form open!)
Suggestion: when interested in an event, always look at the second parameter; just use Intellisense (or MSDN documentation) to have an idea about the available information; what one needs typically is available right there.
|
|
|
|
|
to abort the close enter the following
e.cancel = true
|
|
|
|
|
Hi,
I have created in vb.net 2010 this picture
How can I create a picture without crossing other lines. I now maybee i can find something with google. But for that i need some clear pointers and I'm not a genius in English ( in other languages needer )
I have an even more difficoult picture Here
|
|
|
|
|
I suggest you start by reading WGE[^].
|
|
|
|
|
..can you pls help me to have a code in using a tree view,, thankz..
|
|
|
|
|
Have a read of this Treeview Example[^]
Lobster Thermidor aux crevettes with a Mornay sauce, served in a Provençale manner with shallots and aubergines, garnished with truffle pate, brandy and a fried egg on top and Spam - Monty Python Spam Sketch
|
|
|
|
|
Hi,
I am using vb.net 2008. & 2003 ms access database.
how i connect my vb.net application to remote ms access database.
Thanks & Regards
Form :-
Vikash Yadav
Mob : 773785977
|
|
|
|
|
|
Public con As New OleDbConnection("Provider=MS Remote; Remote Server=http://shpl.co.in;Remote Provider=Microsoft.Jet.OLEDB.4.0; Data Source=d:\DBSMSoft.mdb;" & "Jet OLEDB:Database Password=3010329431;")
not working
Thanks & Regards
Form :-
Vikash Yadav
Mob : 9210907172
|
|
|
|