|
in reports , can i show the graph .i mean, suppose i have three fields , which have their respective percentage.
like a 10%
b 40%
c 50%
so graph should show
a 10% in red
b 40% in green
c 50% in yellow
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
Google for "ZedGraph" and you'll find a free graphing library that can do this.
|
|
|
|
|
yes! u can certainly do that in vb.net itself i hav done that
U just click the graph button in u r crystal report u will be popped up
with a window there u can select u r fields to "Show Value(s)" which is to be shown in Graph, But don't Forget to select the Field to "On change of"
b,coz based on this field u r graph are being displayed.
how it helped , reply !
Prabumj
-- modified at 14:21 Thursday 9th August, 2007
prabumj@gmail.com
-- modified at 0:26 Friday 10th August, 2007
|
|
|
|
|
can we able to put a camera function in vb.net sistem.I want to use camera so that the user can take picture from the system and saved it.Is it posible to do so?
do anyone have any idea how?
@h3aR
|
|
|
|
|
|
I have an article on remote controlling Canon cameras. Just taking a basic picture is doable with most digital cameras with WIA
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
i have made sql statement
this stamene between 2 dates I mean between datepicker 1 and datepicker2
and i use the results to show it in report
what i need is how to put this 2 dates in the report to spacify this report between these two dates
so that the report will be this is the results from date1 to date2
and the results is 2467,2378,238732 and so on
|
|
|
|
|
hi
you can create 2 formula field in report and set their values from code like this
report.fielddefinition.formulafields(fDateindex).text = "Date (yy, MM, dd)"
report.fielddefinition.formulafields(tDateindex).text = "Date (yy, MM, dd)"
the other is you can create 2 parameters in report and set their values form code like this
report.fielddefinition.parameterfields(fDateindex) = "Date (yy, MM, dd)"
report.fielddefinition.parameterfields(tDateindex) = "Date (yy, MM, dd)"
best of luck
Salman Sheikh
|
|
|
|
|
Hello,
I think u using the datetimepicker from the form means. We will send the datetimepicker's value as argument to the Report.
Consider
Dim objcrpdetail As New CryReprot
objcrpdetail.SummaryInfo.ReportTitle = "'"& DateTimePicker1.value &"'
objcrpdetail.SummaryInfo.ReportComments = "'"& DateTimePicker2.value &"'
objcrpdetail.SetDataSource(Dset.Tables(0))
CrystalReportViewer1.ReportSource = objcrpdetail
Here objcrpdetail is Report name as object instant.Then We passing Crystal Report's ReportTitle as DateTimePicker1.value and ReportComments = DateTimePicker2.value as argument to the report called CryReprot. And iam using Dset for data sending to the report.
In the crystal report -> Special Fields -> ReportTitle, ReportComments are available. Click n drag n use it in ur report..
Pls send me ur opinions to me.......
Senthil S
Software Engineer
|
|
|
|
|
hi frnds,
i want to enter only numeric values in a textbox, how can i ?.. like 123.256 or -123.456 ...
cheers..
|
|
|
|
|
use the textchanged event of the textbox and check if it is numeric with isnumeric function (returns a boolean)
|
|
|
|
|
Hello,
I think this is the solution for ur qustion. Pls reply wat ever u got, Ok
If (Asc(e.KeyChar)) = 46 Or (Asc(e.KeyChar)) = 45 Or (Asc(e.KeyChar)) = 8 Then
e.Handled = False
ElseIf e.Handled = Char.IsNumber(e.KeyChar) = True Then
e.Handled = True
End If
Senthil S
Software Engineer
|
|
|
|
|
Senthil S wrote: (Asc(e.KeyChar))
What is this ?
Senthil S wrote: ElseIf e.Handled = Char.IsNumber(e.KeyChar) = True Then
What does this do ?
The solution is to check Char.IsNumber and Char.IsControl, if both fail, then e.Handled should be true.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hello,
I got the out put without any exception. I checked n then only i displayed this msg...
(Asc(e.KeyChar))
is return to check the "." n "-" key. If the user may not need to find the entered value to be number.
ElseIf e.Handled = Char.IsNumber(e.KeyChar) = True Then
if both condition fails then it return nothing in that textbox.
Use that code n check in vb.net 2005. N blame me....
Senthil S
Software Engineer
|
|
|
|
|
in keypress event you can write as follows
If Not Char.IsNumber(e.KeyChar) And Not Char.IsControl(e.KeyChar) And Not e.KeyChar = "." Then
e.Handled = True
ElseIf e.KeyChar = "." Then
If Me.Text.IndexOf(e.KeyChar) > 0 Then
e.Handled = True
End If
End If
Salman Sheikh
|
|
|
|
|
check out my article from the link in my signature on a self validating textbox...the numeric field doesn't handle negative but it wouldn't be hard to change that.
|
|
|
|
|
pretty sure this is the way to do it:
on key press:
if char.isdigit(e.keychar) = false then
if e.keychar = cchar("-") or e.keychar = cchar(".") then
e.handled = false
else
e.handled = true
end if
else
e.handled = false
end if
|
|
|
|
|
You need to make sure only one . or - is entered, and that a - is at the very front of the string.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Ah yes an oversight on my part. Thankyou.
|
|
|
|
|
A correction to my previous post:
if char.isdigit(e.keychar) = false then 'check if it's a number if its not do below:
if e.keychar = cchar("-") then ' if its a minus
if me.textbox1.selectionstart = 0 then 'check if the cursor is at the start
if me.textbox1.text.contains("-") = false then 'check if there is one already
e.handled = false 'allow it if its at the start and the only one
else
e.handled = true 'otherwise don't allow it
end if
else
e.handled = true 'if its not at start don't allow it
end if
elseif e.keychar = cchar(".") then ' if its a decimal place
if me.textbox1.text.contains(".") = false then 'check if there is one already
e.handled = false 'allow it if there is not one already
else
e.handled = true 'if there is one already don't allow it
end if
else
e.handled = true 'if its not a number, a minus or a decimal point, don't allow it
end if
end if
|
|
|
|
|
That is still not exact for several reasons:
- you may have different symbols for decimal point (see regional settings);
- you may want to allow a plus sign;
- you may want to allow thousands separators;
- you may want to allow floating-point notation as in -1,234,567e-23
My conclusion is it is not really worthwhile trying to predict the result of TryParse;
except for a sole minus sign, a sole plus sign, and a partially entered floating-point
number, all partially entered valid numbers are valid numbers on their own.
So I suggest you take care of those exceptions, and work with textchanged event only.
BTW: IMO there is no need to set e.handled=false, it is false to start with.
this seems a good place if any to use multiple exits.
Luc Pattyn [Forum Guidelines] [My Articles]
this weeks tips:
- make Visual display line numbers: Tools/Options/TextEditor/...
- show exceptions with ToString() to see all information
- before you ask a question here, search CodeProject, then Google
|
|
|
|
|
yes i agree, in my article and my textbox control i take much of this into consideration except for floating point and i understand the internationalisation requirements but i just gave him what he asked for, nothing more, its up to him if he want it to be more complex...i don't know what his user require.
|
|
|
|
|
An alternate approach would be to let the user enter whatever they wanted and then validate it by attempting to cast it to a decimal value:
Try
Dim i As Decimal = CDec(TextBox1.Text)
TextBox2.Text = i
MsgBox("Ok!")
Catch ex As Exception
MsgBox("Doh!")
End Try
If you are in ASP.NET then you could also use a CompareValidator (Set the operator to DataTypeCheck and the Type to Double). When the textbox loses focus the validator will fire.
=======================================
There are 10 type of people in the world....
those who understand Binary, and those who don't!
=======================================
|
|
|
|
|
hello boss,
Dim con As New SqlConnection("database=deltadatabase;user id=sa;pwd=sa;server=localhost")
con.Open()
Dim cmd As New SqlCommand("select * from tbl_adminlogin", con)
DataGridView1.DataSource = cmd.ExecuteReader,
i am using the above code.
there is no error execution
but not binding the data
is there anything that is missing?
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
try this plse
Dim con as new sqlConnection("server=local;database=me;user=sa;pwd=sa;")
dim cmd as new sqlcommand("select * from tbl",con)
dim objds as new dataset
objds=cmd.executenonquery()
datagrid.datasource=objds.table(0)
happy.....
cooollll...
|
|
|
|