15,883,883 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Jean-Claude ADIBA (Top 24 by date)
Jean-Claude ADIBA
21-Aug-21 9:39am
View
Amen 🙏🙏🙏
Jean-Claude ADIBA
21-Aug-21 9:38am
View
No Matter
Jean-Claude ADIBA
3-Jul-17 10:03am
View
depending of the Tools you use to create the Template you can get the HTML(tags) of the result Template from that Tools and save it as string in your database
Jean-Claude ADIBA
19-Dec-16 15:42pm
View
Great. if it help you can you mark my answer as approved solution.
Jean-Claude ADIBA
11-Dec-16 4:41am
View
we need cooooode to help you ;)
Jean-Claude ADIBA
15-Oct-16 13:22pm
View
yes it's possible to enter credential informations when you create the report (to locate the database), but i recommend you to do it in code to make dynamic because it's not sure that the credential of your dev environnement will be the same in production environment.
it's not best pratice but you can set your report credential directly in the production environment. and copy the file in application folder
you must do it manually for all reports and subreports (i suppose)
Jean-Claude ADIBA
2-Nov-14 8:59am
View
Hi i hope you found a solution to your problem if not. do you try the solution i gave below with the
AssignConnection(rpt As ReportDocument)
method ?
Jean-Claude ADIBA
2-Dec-13 5:38am
View
I desagree I'm sorry, i inform you that after your post i don't edit the solution
you can see the editions history (http://www.codeproject.com/script/Articles/ListVersions.aspx?aid=690513)
yes i have edit just 20mn after my first publish jusT to add some precision but your comment was send later. i accept to be correct but please read before comment and downvote
Jean-Claude ADIBA
2-Dec-13 2:02am
View
Have you read my answer with his logic ? Solution 1 use TimeSpan and i show it. but he post his question in VB.NET Section so i wrote the answer in VB.net and i show the Existence of DateDiff (Dim timeDiff As Long = DateDiff(DateInterval.Hour, objDate1, objDate2)
).
He ask 2 Questions i try to give answer for these 2 question but Sergey no so ...
My answer don't need conversion any time. i show ealer how to get the part of time in the date as string (he uses a textbox) : Dim objTime As String = objDate.ToShortTimeString()
after i give how have difference between two date with TimeSpan
Dim objDate1 As DateTime = Date.Now()
Threading.Thread.Sleep(3000)
Dim objDate2 As DateTime = Date.Now()
Dim span As TimeSpan = objDate2 - objDate1
Console.WriteLine(span.TotalSeconds)
Jean-Claude ADIBA
1-Dec-13 3:27am
View
OK AS I TRY TO EXPLAIN YOU LATER, TO DELETE RELATED DATA IN YOUR SQLSERVER DATABASE YOU HAVE 2 SOLUTIONS
1. IN SQLSERVER ADD -ON DELETE CASCADE-STATEMENT TO YOUR FOREIGN KEY GuestId IN BOOKING TABLE BY USING SQL LANGAGE OR YOU CAN USE SQLMANAMENT STUDIO TO ADD IT WITH THE DESIGNER
ALTER TABLE [Booking] ADD CONSTRAINT FK_Booking_Guest_GuestId FOREIGN KEY( GuestId)
REFERENCES [Guest] ( GuestId)
ON DELETE CASCADE;
-ON DELETE CASCADE- PERMIT YOU TO DELETE AUTOMATICALY ALL RELATED ROWS IN BOOKING TABLE WHEN YOU DELETE THE GUEST.
BUT YOU CAN DO IT MANUALLY.
2. IN C# BEFORE DELETE A GUEST ROW.
- COUNT THE ROWS IN BOOKING TABLE WHICH HAVE THE ID OF THE GUEST ROWS YOU WANT TO DELETE
- IF COUNT >0 DELETE ALL THE DATA IN BOOKING TABLE WHICH HAVE THE ID OF THE GUEST ROWS YOU WANT TO DELETE
- NOW YOU CAN DELETE THEN GUEST ROW
Jean-Claude ADIBA
30-Nov-13 23:35pm
View
no matter ! so mark that your question has been solve by the solution 1 ! it remove your question to the unanswered questions liste ;)
Jean-Claude ADIBA
30-Nov-13 23:27pm
View
what laguage do you want to use to delete the data in your two table ?
Jean-Claude ADIBA
30-Nov-13 22:36pm
View
OK Don't use this line System.Data.SqlClient.SqlConnectionStringBuilder(ConnectionString)
sqlclient is for sqlserver database
all you have to do is to remove this line form AssignConnection method
Dim con As New System.Data.SqlClient.SqlConnectionStringBuilder(YourConnectionString)
and provide your MYSQL DATABASE CONNECTION TO THE CRYSTAL REPORT ConnectionInfo Object
like this
connection.DatabaseName = "YourDataBaseName" 'myDataBase
connection.ServerName = "YourServerAdress" '127.0.0.1
connection.UserID = "UserID" 'root
connection.Password = "Password" '12345
Let's me know
i improve the assignconnection method
Jean-Claude ADIBA
30-Nov-13 21:19pm
View
ok let's go slowly what SGBD do you use (MYSQL OR SQL SERVER)
Jean-Claude ADIBA
30-Nov-13 20:50pm
View
hi i have improve the next solution for you by adding AssignTableConnection implementation and i try to reorder your code i hope it's help
<pre lang="vb">
Dim sqlQuery As String = "SELECT * FROM security_log where Middle_Name= '" & TextBox1.Text & "'"
Dim sqlAdapter As New MySqlDataAdapter
Dim sqlcommand As New MySqlCommand
Dim ds As New DataSet
Dim cryRpt As New ReportDocument
Dim rptDoc As CrystalDecisions.CrystalReports.Engine.ReportDocument
rptDoc = New CrystalReport3
With sqlcommand
.CommandText = sqlQuery
.Connection = sqlcon
End With
With sqlAdapter
.SelectCommand = sqlcommand
.Fill(ds, "security_log")
End With
' in the AssignConnection i used System.Data.SqlClient.SqlConnectionStringBuilder(ConnectionString)
'to get the connection by providing the connectionstring in parameter
'BUT YOU MUST USE YOUR MYSQL CONNECTION sqlcon
AssignConnection(rptDoc)
rptDoc.SetDataSource(ds)
ds.WriteXml("D:\secl.xml", XmlWriteMode.WriteSchema)
'YOU MUST ALLWAYS PROVIDE CONNECTION INFO TO YOUR REPORTDOCUMENT BEFORE OPEN IT
Form6.CrystalReportViewer1.ReportSource = rptDoc
Form6.Show()
</pre>
Jean-Claude ADIBA
12-Dec-12 22:33pm
View
Thank you for your reply, I hope they will have tools to export from 10.1.18 build 8330 or upgrade to Universe 11.1. Let me know. THANK YOU
Jean-Claude ADIBA
12-Dec-12 21:37pm
View
i have no tools to do this. if there is one tools i think it will be possible
Jean-Claude ADIBA
12-Dec-12 21:35pm
View
there is no tools to export table
Jean-Claude ADIBA
12-Dec-12 14:37pm
View
hi i have istall sql server 2012 and Rocket U2 Toolkit for .NET but when sql server 2012 try to extract data it doesnt see tables. i think its because the version of universe server is 10.1.18.0
How can i do ?
Jean-Claude ADIBA
11-Dec-12 12:34pm
View
I don't have SQL SERVER 2012 I WORK ON SQL SERVER 2008 IS IT POSSIBLE ?
Jean-Claude ADIBA
25-Nov-12 7:38am
View
no matter you are welcome.
Jean-Claude ADIBA
23-Nov-12 12:35pm
View
you cannot to be notified when an item change because ObservableCollection<t> collection only fires the CollectionChangedEvent.
Because you implement INotifyPropertyChanged, you will see changes to the items in the view (WPF does this automatically if you ), but if you need to execute manual actions when an item changes, you can use BindingList<t> and suscribe to BindingList.ListChanged event. with ListChangedEventArgs ( ListChangedEventHandler's proprety) you can manupulate your data in easy way.
Also you can always use ObservableCollection Class and handle datagrid CellEditEnding event like this:
private void dg_CellEditEnding(object sender, DataGridCellEditEndingEventArgs e)
{
if (e.Column == yourColumn)
{
if (e.EditAction == DataGridEditAction.Commit)
{
TextBox t = e.EditingElement as TextBox; // Assumes columns are all TextBoxes
yourObject = e.Row.Item; //you must cast
yourObject.Property1 = t.Text ; // the value of the cell
}
}
}
Jean-Claude ADIBA
20-Nov-12 18:55pm
View
Thanks for trying my solution. you know the binding system of WPF take sense with these classes because without them you will use WPF like any winform application.
I agree with you when you want to build your business classes as POCO without any of these kind of classes. To go further more you must build your application with MVVM architecture to take advantage of WPF binding. you must wrap your List<timesegment> object in ObservableCollection<timesegment> object in a viewmodel which will bind to your UI. follow this link to have more information about the MVVM pattern
http://msdn.microsoft.com/en-us/magazine/dd419663.aspx
regards
Jean-Claude ADIBA
19-Nov-12 13:46pm
View
;) thank you for your precision
Show More