|
Dave Kreskowiak wrote:
Actually, Christian is right. Access is crap for any multiuser system.
Since its completely file based, it must be accessed using the underlying file system. This results in FAR more network traffic than using SQL Server, and is MUCH slower at doing the same job.
When used properly - i.e a small system, both speed and network traffic are rarely issues with Access.
Security is not a major problem with Access if you set up work groups security. Even if a person copies the database they cannot access it outside of the workgroup.
If you are so anti-Access, what are you doing using it where you work. Surely you can sway everyone's opinion against Access since it is after all, "such a piece of crap"?
Dave Kreskowiak wrote:
What case? I did it with a couple of small operations. If the backup operation is setup correctly, automated correctly, and stored in an appropriate site, it's not a problem. I could even fix any problem remotely, if needed.
Backing up and restoring a single database is not particularly difficult. A full SQL Server restore? Different story. I would not want to have to try to walk a non-IT person through the process of a rebuilding an entire SQL Server. Good thing you can fix any problem remotely.
Many businesses successfully rely on Access every day.
I think some of you guys allow your personal prejudices about what's "good" and what's "crap" to allow you to make poor architectural decisions.
For every person out there who says Access is a piece of sh*t and SQL Server is a "real database" there is another person who will tell you that SQL Server is piece of sh*t and Oracle is a "real database". And it's true that SQL Servers choke on tasks that Oracle burns through in no time.
But so what? It's not about "faster" or "better". It's about picking tools and platforms that are appropriate for the end use.
I never give a client something that is much more complicated than they need or is less suitable for their operation's ability to support just because I think it is "better".
Robert
|
|
|
|
|
rwestgraham wrote:
When used properly - i.e a small system, both speed and network traffic are rarely issues with Access.
Security is not a major problem with Access if you set up work groups security. Even if a person copies the database they cannot access it outside of the workgroup.
Not to mention workgroups in Access are a pain in the ass to use and administer. BTW: On my wire around here, the more I can reduce the chatter, the better. And yes, I've been in client sites where that was a concern. Now, it's a mandatory consideration in all the development I do.
rwestgraham wrote:
If you are so anti-Access, what are you doing using it where you work.
I didn't say I was using it. I haven't used it in MY development work in years, and refuse to go back. I find the control and supportability of MSDE/SQL Server much easier to deal with, but more importantly, much less likely to screw up in the first place.
rwestgraham wrote:
Surely you can sway everyone's opinion against Access
I didn't develop the system. I just have to keep it running somehow. And, no, I can't sway the opinion to get off Access. Believe me, with all the problems this thing has, I'd love to be able to rip it out and replace it with an SQL Server solution.
rwestgraham wrote:
Backing up and restoring a single database is not particularly difficult. A full SQL Server restore? Different story.
Same goes for a machine hosting an Access database, so I fail to see your point here. Since a total machine failure would have me out there rebuilding it either way...
rwestgraham wrote:
I think some of you guys allow your personal prejudices about what's "good" and what's "crap" to allow you to make poor architectural decisions.
Actually, it's not out "personal prejudices", but our "personal experiences" that dictate our architectural decision. Reliability, Supportability, and Scalability are the biggest factors I have to deal with in my work.
rwestgraham wrote:
It's about picking tools and platforms that are appropriate for the end use.
Reliability, Supportability, and Scalability...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Dave Kreskowiak wrote:
Not to mention workgroups in Access are a pain in the ass to use and administer. BTW: On my wire around here, the more I can reduce the chatter, the better. And yes, I've been in client sites where that was a concern. Now, it's a mandatory consideration in all the development I do.
Workgroups are pretty easy to administer. People can do them in house easily. Much less difficult than setting up a SQL Server.
And if network traffic is an issue at a client site, then Access is probably not the correct choice anyway. You seem intent on ignoring the fact that I stress Access is only appropriate for small systems.
Dave Kreskowiak wrote:
Same goes for a machine hosting an Access database, so I fail to see your point here. Since a total machine failure would have me out there rebuilding it either way...
Absolutely not true. The person simply reinstalls Windows, reinstalls the application, pulls out the optical disk or whatever they copy their backups to, and copies the last Access backup to the working directory. If they have security they recreate the workgroups. The system is fully restored.
But I do agree about one thing. With MSDE or SQL Server yes, you are probably out there rebuilding it yourself. That's a luxury not everyone has. I am in Atlanta GA. Most of my clients are in Austin TX. If I had to fly out there to reinstall an application for a user group of 5 people because their hard drive crashed, somebody would be pissed, and rightfully so.
Dave Kreskowiak wrote:
Reliability, Supportability, and Scalability are the biggest factors I have to deal with in my work.
Key word YOUR work.
As far as reliability, I've had no real problems with Access. As far as supportability, as I've pointed out in length, my small application users can support themselves with Access. If I were to substitute MSDE this would no longer be the case.
My large application users have the either the resources in house to support a SQL Server or can afford the resources to have me support it for them.
Scalability is NOT a criteria in all systems. I recently did a pay-for-performance system for a client. It accesses their main database (A proprietary one that comes with their operations management system) and calculates some numbers and puts them into an Access database because that is a convenient way to spit out a report. The Operations manager can run it for the entire staff. An individual can run only their own data. It's not an application where scalability ever matters because the tasks run quickly, very little data is actually stored in Access, and there will never be more than a few people at most running reports at any given time.
This is exactly the sort of scenario where use of Access is appropriate.
What advantages would added by doing such an application with MSDE? None. The disadvantages? Well for starters I would have to create a more complicated build to install the MSDE service, plus create a build for the MSDE database itself, plus I would have additional support issues that my client would find unacceptable for such a simple application. MSDE is simply not appropriate for this particular application.
The key word is NOT always scalability. If scalability is a major criteria Access is not appropriate. The key word is always appropriate.
What part of the term appropriate do you not understand? You just don't get it do you?
|
|
|
|
|
Great. Since our experiences are so different, we agree to disagree...
For you, Access is an option. For me, I don't find it appropriate for any multi-user system.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Dave Kreskowiak wrote:
For you, Access is an option. For me, I don't find it appropriate for any multi-user system.
But I knew that all along. It's futile to argue with a fencepost about the hole that it's in.
I engage in these discussions only for the benefit of people who are open to evaluation of arguments that are more technically compelling than "it is a piece of sh*t" .
Robert
|
|
|
|
|
Yes we can develop Client server application in VB by using Access
rs.CursorLocation = adUseClient
rs.Open sBuildQuery, cnn, adOpenKeyset, adLockOptimistic
use above string
i think u understand..
Abhay
|
|
|
|
|
payal sheth wrote:
Its giving me Error like "Database is Exclusively locked by other User."
Someone has the DB open directly through access and that locks it to one person. I personally am running a .net program with 15 users with access to the DB with out a problem. The only trick i had to set up was to refresh the DB to the user once and a while. but no problems for me.
James Kennelly
|
|
|
|
|
I am creating an application that will create a notify window similar to outlook 2003 notify popup. I am making an asyncronous remoting call using system.thread that raises an event to show the form. However, the form shows up as a black box and then immediately disappears when the event is called. If I call the function through a menu item or button, it works fine. Here's the popup code:
Private Sub ATU_RetrieveDone(ByVal e As AsyncUpdater.AsyncUpdaterEventArgs) Handles ATU.RetrieveDone
Me.UpdateTimer.Enabled = False
If e.Forums Is Nothing Then
UpdateTopicListView(e.Results) ' Updates a list view and
' displays the popup.
Else
UpdateForumListView(e.Forums)
End If
Me.UpdateTimer.Enabled = True
End Sub
Private Sub UpdateTopicListView(ByVal Topics As ResultsCollection)
For index As Integer = 0 To Topics.Count - 1
...
Next
Dim Message As String
Message = "{0} new topic updates have been retrieved from {1}"
Me.ShowPopup(String.Format(Message, Topics.Count, ClientSettings.WebURL))
End Sub
Private Sub ShowPopup(ByVal Message As String, Optional ByVal TimeOut As Integer = 0)
Dim displaytime As Integer
If TimeOut < 1000 Then
displaytime = ClientSettings.PopupTime * 1000
Else
displaytime = TimeOut
End If
Dim PW As New PopupWindow
PW.SetProperties(NewMessagePopup.Blend, Message, displaytime)
PW.ShowPopup()
End Sub
And here's routine that creates the popup using a seperate windows form.
Public Sub ShowPopup()
Dim tbl As TaskBarLocation
Dim workingArea As Rectangle
Dim pt As Point
pt = New Point
pt.X = 0 : pt.Y = 0
workingArea = SystemInformation.WorkingArea
tbl = GetTaskBarLocation() ' Gets an enumerator
' indicating the windows task bar
' location.
Select Case tbl
Case TaskBarLocation.Bottom
pt.X = workingArea.Right - Me.Width
pt.Y = workingArea.Bottom - Me.Height
Case TaskBarLocation.Left
pt.X = workingArea.Left
pt.Y = workingArea.Bottom - Me.Height
Case TaskBarLocation.Right
pt.X = workingArea.Right - Me.Width
pt.Y = workingArea.Bottom - Me.Height
Case TaskBarLocation.Top
pt.X = workingArea.Right - Me.Width
pt.Y = workingArea.Top
End Select
Me.Visible = False
Me.Show()
Me.Top = pt.Y
Me.Left = pt.X
Me.Visible = True
tmrStartFade.Enabled = True ' Wait until elapsed to begin form fadeout
End Sub
Any ideas why this might be occuring?
Thanks!
|
|
|
|
|
I've done some more research and it appears the problem is caused using timers. I've used both System.Timers.Timer and System.Windows.Forms.Timer and both give the same result, a black box that appears and then disappears. If I call the ShowPopup subroutine by clicking a button, it displays correctly. If the timer causes the form to be displayed, I get the black box.
Here's the logic steps used:
1) Timer.Tick event occurs
2) Tick Handler creates a new AsyncUpdater and invokes the GetUpdate method
3) GetUpdate creates a new thread and begins the remoting call
4) Once GetUpdate has completed the remoting call, the event RetrieveDone is raised.
5) The main form handles the event causing a list view to update it's list of items.
6) The ShowPopup method is called to display the popup.
Any help or ideas would be greatly appreciated. I can't understand why the manual invoking (pressing a button) works but the event handler doesn't.
Thanks!
|
|
|
|
|
Greetings
How can I use vb6 to connect using ip to a SQL database?
Thanks,
---- Mike
|
|
|
|
|
It's no different than any other connection to an SQL server. All you need to do is supply either the full DNS name to the server or the servers IP address:
Dim DBcon As New ADODB.Connection
Dim objCmd As New ADODB.Command
Dim objparameter As New ADODB.Parameter
Dim objRs As New ADODB.Recordset
DBcon.ConnectionString = "Provider=sqloledb;" & _
"server=[ServerName or IP Here];uid=UserId;pwd=Password;database=MyDatabase
DBcon.CursorLocation = adUseClient
DBcon.Open
objparameter.Direction = adParamInput
objparameter.Type = adVarChar
objparameter.Size = 5
objparameter.Value = "hello"
objCmd.Parameters.Append objparameter
objCmd.ActiveConnection = DBcon
objCmd.CommandType = adCmdStoredProc
objCmd.CommandText = "s_mysp"
Set objRs = objCmd.Execute ' objCmd.Execute for no resultset
set objRs.ActiveConnection = Nothing
Set objCmd = Nothing
DBcon.Close
Code snippet lifted from Nigel Rivett[^], without permission, of course.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi Dave,
Thanks for your post.
In VB6 I put the code in the form load sub.
I get the error "Compile error: User-defined type not defined" when I run thr project.
Am I missing a 'reference' or what?
Thanks again....
--- Mike
Private Sub Form_Load()
Dim DBcon As New ADODB.Connection
Dim objCmd As New ADODB.Command
Dim objparameter As New ADODB.Parameter
Dim objRs As New ADODB.Recordset
DBcon.ConnectionString = "Provider=sqloledb;" & _
"server=[ServerName or IP Here];uid=UserId;pwd=Password;database=MyDatabase"
DBcon.CursorLocation = adUseClient
DBcon.Open
End Sub
|
|
|
|
|
Problem solved.
I answered my own question.
I put the control Adodc1 on a form & the code connected to the database.
Thanks again for the help.
--- Mike
|
|
|
|
|
Oops! I forgot to mention that little tidbit. The code should work if you add a reference to the "Microsoft ActiveX Data Object Library" or something very similar. I can't remember the name off the top of my head.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi,
I am trying to write a program to control a Digital Poteniometer via parallel. I was doing fine until I tried to work out how to read back some data from the device. I send a command to the chip, which then returns a serial stream of data out of a pin, which I have connected to S3 (status register) on the parallel port. I have been able to read the status register and then isolate S3 from this, but S3 is meant to be changing, so how can I make my program look for an event change in this register, ideally every x seconds or something??
Any help would be greatly appreciated.
Regards,
Adam.
|
|
|
|
|
have you tried a timer. I use it to make clocks on my apps by telling it to read the system time every second.
James Kennelly
|
|
|
|
|
This is what I use for a precision timer:
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/Q172/3/38.asp&NoWebContent=1
How To Use QueryPerformanceCounter to Time Code
|
|
|
|
|
Sorry, Here is the one for vb.net:
http://support.microsoft.com/default.aspx?scid=kb;en-us;306978
How To Use QueryPerformanceCounter to Time Code in Visual Basic .NET
|
|
|
|
|
Here is one more that might be of help:
http://msdn.microsoft.com/msdnmag/issues/04/02/TimersinNET/default.aspx
Timers
Comparing the Timer Classes in the .NET Framework Class Library
|
|
|
|
|
Intelligent graphic image analysis and comparison
Hi,
I’m thinking if there is any way to compare two or images and see if they have let’s say have more than 80% common parts, which mean that they are probably the same?
At his moment I want to write an app that will stupidly see if the image is identical, well maybe there was some resizing, or quality reduction and or some other minor changing. In another words I wanna mach them up.
I think I need to use bit structure / analysis, but I have no idea how that works.
Thanks!
|
|
|
|
|
I have to do an Exercise by tomorrow but i don't know how to do it
Here is the exercise from the book:
In this excercise, you create an application from Premium Paper. The aplication allows the sales manager to enter the company's income and expense amounts. The number of income and expenses amounts may vary each time the application is started. For example, the user may enter five income amounts and 3 expense amounts. The application should calculate and display the company's total income, total expense, and profit(or loss). Use the InputBox function to get the individual income and expense amounts.
More instructions:
1. Design an appropiate interface. Use label controls to display the total income, total expenses, and profit(or loss). Display the calculated amounts with dollar sign and two decimal places. If the company experienced a loss,display the amount of the loss using red font. otherwise, display the profit using black ink.
CAN SOMEONE HELP AND SEND ME THE CODE FOR THAT? PLEASE!!!!
|
|
|
|
|
Please Tell me you dont want someone else to do your homework?
Isnt that cheating?
any ways you should be able to do it if you set your text boxes to 0 add and subtract the proper text boxes. As for the color use a if then statement like if textbox1.text < 0 then
textbox1.forcolor=system.drawing.color.red
else
textbox1.forcolor=system.drawing.color.Black
end if
very easy project if it is giving you this much trouble you might want to try a different field of research.
James Kennelly
|
|
|
|
|
joseuri21 wrote:
CAN SOMEONE HELP AND SEND ME THE CODE FOR THAT? PLEASE!!!!
This better be a joke...
If you have no idea how to do it, what on earth have you been doing in class all this time? And why did you wait till the last possible minute to start on this?
You're going down on this project and it's your own damn fault. None of us are going to bail you out by just handing you the entire project. We don't get anything for the work and all you're going to get is busted for plagerism. Since everyone's coding style is unique, your prof will instantly know that you didn't write the code.
We will help you with YOUR code. We will NOT write your code for you.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I'm using the ShellExecute API, but it is not opening any file with its associated program.
here is my coding:
Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _
(ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, _
ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd _
As Long) As Long
Public Sub RunProgram(ByVal strProgram As String)
Dim lRet As Long
lRet = ShellExecute(vbNull, "Open", strProgram, "", "", 1)
If lRet <= 32 Then
MsgBox("Error Running Program")
End If
End Sub
Public Sub btmView_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnview.Click
RunProgram(file_location)
end sub
It doesn't give me the error either. PLEASE HELP!
Lisa
|
|
|
|
|
It perfectly works in my pc. You might wanna check what is inside of the strProgram variable.( maybe there is a space in side?) try with the note pad like the following if it works.
Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
Private Sub Command1_Click()
Dim lRet As Long
lRet = ShellExecute(vbNull, "Open", "C:\WINDOWS\SYSTEM32\notepad.exe", "C:\mytext.txt", "", 1)
If lRet <= 32 Then
MsgBox ("Error Running Program")
End If
End Sub
|
|
|
|
|