15,897,090 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 Michael Sernal (Top 12 by date)
Michael Sernal
13-Feb-14 4:40am
View
An update Guys, I recoded it, and now I'm having a different error. It goes like this "no. of query values and destination fields are not the same." My table in my ms access database is consist of 3 columns namely, ID, Username, and Password.
Note: ID is auto-numbered by the DB. That's why I only need txtUname.text and txtPass.text to be saved on my DB.
So does anyone have any idea how will be able to save the data with just the 2 since the ID is auto numbered by MS access? Thanks.
Private Sub bAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bAdd.Click
Dim objConn As New OleDb.OleDbConnection
Dim connStr = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Users\Avatar\Documents\Visual Studio 2010\Projects\Invent\Invent\mdbInvent.accdb;User ID=admin"
Dim ins As New OleDb.OleDbCommand
Try
objConn.ConnectionString = connStr
objConn.Open()
ins.Connection = objConn
ins.CommandText = "INSERT INTO tblUsers VALUES(@Username, @Password)"
ins.Parameters.AddWithValue("@Username", txtUname.Text)
ins.Parameters.AddWithValue("@Password", txtPass.Text)
ins.ExecuteNonQuery()
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try
End Sub
Michael Sernal
18-Jul-12 17:44pm
View
Thanks Kschuler,
I'm thinking of the same way, but you see this text object is a comment field and I don't have any idea how many characters a user will input. So if I reduce the width and height of the text-object and the user will input a lot then not all characters will be displayed and if I will increase it's size then it would would consume a lot of space. Does this mean I will make estimates on how big this text-object would be so that I will be able to cater how many lines of text to display?
Michael Sernal
6-Jul-12 14:13pm
View
What if you have multiple rows? do other td's follow to the ones you put the id to? because i already have classes and my table contains multiple rows, thanks.
Michael Sernal
18-Jun-12 9:23am
View
hi vijay bisht,
I think i have already explained it well. I have a crystal reports and it's detail section is divided into 3 like detail section 1, 2, and 3. the problem is when the report is generated there a two extra pages 4 and 5 which are the copy of details section 1 and 2 or shall i say pages 1 and two. For the details on how i divided the detail section into three i think i mentioned it above in section expert. Thanks.
Michael Sernal
15-Jun-12 10:21am
View
hello losmac, hi guys,
i saw two checkboxes under the paging tab of the details section new page after, namely: "end of section" and "visible records". i only checked one which is the end of section and in the formula editor i pasted the code you posted above and i think im doing it wrong because i'm not getting the results i wanted. I also tried doing it with the other checkbox and having the 2 of them checked and still no luck. Do i have to edit something here like this or how is it done? Thanks for being patient.
if recordnumber = 15 then
display only 5 records per page which makes it 3 pages.
Michael Sernal
31-May-12 9:40am
View
hi jackssen,
i removed the msgbox inside the selectedindexchanged and it works fine when i passed it to another variable which im using in another function. the msgbox was just to test if it's correct. Thanks a lot for the help, have a 5, hehe..☺
Michael Sernal
30-May-12 15:06pm
View
hi MugiwaraUK,
No, i don't add the 1 and the other values, i retrieve them from a datatable and then after that in the event selectedindexchanged i want to separate the value of the selectedindex wherein i only want to get the values of the column 0 of the datatable from which i retrieved the items of the dropdown control. Any ideas? Thanks.
Michael Sernal
30-May-12 14:59pm
View
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
For c = 0 To dtinfo.Rows.Count - 1
drpinfo.Items.Add(dtinfo.Rows(c).Item(1) + " " + dtinfo.Rows(c).Item(2) + " " + dtinfo.Rows(c).Item(3))
Next
End Sub
Protected Sub drpinfo_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs) Handles drpinfo.SelectedIndexChanged
Dim i As Integer = 0
Dim numberindex As String = Nothing
While Char.IsDigit(drpinfo.SelectedValue(i))
numberindex += drpinfo.SelectedValue(i)
System.Math.Max(System.Threading.Interlocked.Increment(i), i - 1)
End While
Dim result As Integer = Integer.Parse(numberindex)
msgbox(result)
End Sub
Here is the code, it works but there are times that the msgbox would display the previous selecteditem, thanks.
Michael Sernal
29-May-12 16:02pm
View
hello jackssen,
the above code worked but i encountered some problems. i included a messagebox so that once i already selected an item in the dropdown menu i will be able to see the number. the problem is that there are times that if i haven't finished scrolling down yet a msgbox would already appear with the number of the previous item. have any idea how to fix this? thanks.
Michael Sernal
4-May-12 9:58am
View
got the keycode for spacebar 32, but couldn't find a way to make it work, would you mind showing me in code? thanks.
Michael Sernal
4-May-12 9:51am
View
hi,
i tried to change the below code:
var newtext = thetext.split("\n");
document.getElementById(txtBox.id).rows = therows;
to this:
var newtext = thetext.split(" ");
and this:
document.getElementById(txtBox.id).columns = therows;
but nothing happens to the width or column when i press enter, and also i would like to change the event to spacebar but couldn't the keycode for spacebar, any ideas? thanks.
Michael Sernal
25-Apr-12 10:55am
View
Hi OriginalGriff,
Thanks for sharing your idea but i can't get a clear picture because im not familiar with aspx or asp.net, my bad. And oh, i'm new in code project, and i'm still looking forward from other peoples ideas, am i supposed to accept the solution? or will i save it for later? if you don't mind me asking, thanks.
Show More