|
Hi Steve!
I already grant user everyone, system,service, local service,network service to full control.
Account ServiceProcessInstaller for this service is Local system.
but still can't work , get below error message --Access to the path "E:\" is denied.
Any idea?
Thanks!
|
|
|
|
|
The Local System account doesn't have rights to see any network drives, even you you grant them. You MUST change the account from Local System to a user account specifically setup to run this service.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Also, there are 2 places for permissions: share permissions, and folder permissions. If the user does not have permissions for the share (set up on the sharing tab when you right click on the shared folder and click properties), they won't be able to access files even if they have security permissions for the folder or files. Although, if Dave is correct (and he usually is) it won't help.
|
|
|
|
|
As far as i remember drive mappings are specific to the user and are stored as part of the users profile. A service generally runs under the system account (so it can still function if no user is logged on). In this case you will need to use the format \\server\sharename to access files on a remote PC.
Jon
|
|
|
|
|
Thanks Dave and Scott. Yes, it's working now with configuration of granted share permission and the service runs under a user account who has the privilege to that mapped folder.
By the way, in what condition, we should assign service's user account to NetworkService, localservice?
Hi Jonathan15! it's still not working if the service runs under local system account, even though using format \\server\sharename.
Thanks, everyone!
|
|
|
|
|
if the service doesn't runs under DOMAIN user account who has the privilege to that mapped folder, any other ways that we can access to Mapped Folder or Network Drive?
Need guide, Thanks!
|
|
|
|
|
Everyone,
I'm using Crystal Reports that came with VS 2003. I'm using a recordset as the datasource to show for the report. The problem I'm getting is I am getting duplicate records. The data is coming from a PostGres database. What I'm trying to show are transactions for people who prepay to a card. Some people might recharge more than once in a day. When that happens, duplicate records occur. Here is the code to get the recordset.
dim rsReport as New Adodb.Recordset
strSearch = "SELECT c.crd_id, c.membernumber, c.firstname, c.lastname, u.moneyadded, u.dateadded, u.timeadded FROM userbalance u inner join transaction t on u.transid = t.transid inner join card_user c on c.crd_id = t.transcardid WHERE u.dateadded >= '" & dtFrom & "' AND u.dateadded <= '" & dtUntil & "' AND t.transid <> '0' "
strTester = strSearch
With rsReport
.CursorLocation = ADODB.CursorLocationEnum.adUseClientBatch
.Open(strSearch, conConnect, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockOptimistic)
End With
The code to link recordset to report.
rptMoneyAdded.SetDataSource(rsReport)
rptV1.ReportSource = rptMoneyAdded
rptV1.RefreshReport()
I checked the recordset in a datagrid and it comes out fine. I know about the "SuppressIfDuplicate" but I can't use that because if 2 transactions are back to back by the same person, then the report will supress the second transaction. Any help will be nice. Thanks.
|
|
|
|
|
Try using distinct keyword in the sql query .
abhinav
|
|
|
|
|
Sorry that did not work. Any other ideas?
|
|
|
|
|
Hi
I need to start a connection to a linux box from a VB 6.0 application? Is it possible at all? If yes, how? I tried looking at the Winsock API but couldn't gather how to use it?
Thanks
|
|
|
|
|
You going have to be more specific. What are your tring to connect to? How are you tring to connect? Is it a database, shared folder?
|
|
|
|
|
I just want to start a shell on a linux machine where i can type in commands to do stuff. I should be able to see the results of those commands and any error messages.
Thanks
|
|
|
|
|
I have a DropDownList and a Button on a form. The user selects an item from the DropDownList and clicks the button. I want to check the text value of the DropDownList in the Button_click event with the following code.
If Me.DropDownList1.SelectedItem.Text = "" Then
' do something
End If
But no matter what item I select in the DropDownList Me.DropDownList1.SelectedItem.Text always equals "". How can I get the text value of the item selected?
|
|
|
|
|
Most probable cause - your Page_Load is setting a data source for the drop down, and is doing it every time ( which resets the selection ). You should do this in Page_Prerender anyhow, but either way, it shoud be in a block to make sure it only happens with IsPostback = false
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
|
I need to do an "AND" statment in my selection formula
CrystalReportViewer1.SelectionFormula = "{events.ddate} = " & (moddate) & "" And "{child.name} = '" & (modname) & "'"
each formula works on its own but when I run them togther I get an error about child.name can not be converted to a long
I have also tried
CrystalReportViewer1.SelectionFormula = "{events.ddate} = " & (moddate) & "" & "{child.name} = '" & (modname) & "'"
That gives me an error that say "The rest of the statement does not look apart of the formula"
HELP!
1. Out of clutter, find simplicity.
2. From discord, find harmony.
3. In the middle of difficulty lies opportunity.
Albert Einstein
three rules of work
|
|
|
|
|
Hi all;
I am not expert in vb.net so
I need Tutorial or source code to open
web cam on vb.net form (application)
and capture picture form it and save
it ofcourse as bitmap image.
I searched and I didnt found any thing.
THANKS
AMR-CIS
|
|
|
|
|
|
I have been having this issue for some time now. Some may remember seeing my posts over the course of the last few months.
Issue: Everything seems to work with the exception of deleting rows from the datagrid.
Err - You can delete rows if you start from the topmost record and work your way down. ??
I have posted the full code for one of the offending forms here
Ideas/advice needed and appreciated. If more information is needed, please let me know.
|
|
|
|
|
u can delete rows from datagrid
try this:
If dataset.Tables("SearchResult").Rows.Count > 0 Then
dataset.Tables("SearchResult").Rows.RemoveAt(dgrid.CurrentRowIndex)
dgrid.Refresh()
Else
MsgBox("No Data To Delete")
End If
when u populate the grid with data declare the dataset with general scope.
this worked for me. i was also going mad for months. good luck.
|
|
|
|
|
I think that the datagrid in question is a bit too complex for this to work. I tried what you had posted in the DataGrid1_KeyDown event...
If e.KeyCode = Keys.Delete Then.....
but I still immediately receive:
************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at System.Windows.Forms.DataGrid.ResetSelection()
at System.Windows.Forms.DataGrid.ResetUIState()
at System.Windows.Forms.DataGrid.SetDataGridRows(DataGridRow[] newRows, Int32 newRowsLength)
at System.Windows.Forms.DataGrid.DeleteDataGridRows(Int32 deletedRows)
at System.Windows.Forms.DataGrid.DeleteRows(DataGridRow[] localGridRows)
at System.Windows.Forms.DataGrid.ProcessGridKey(KeyEventArgs ke)
at System.Windows.Forms.DataGrid.ProcessDialogKey(Keys keyData)
at System.Windows.Forms.Control.ProcessDialogKey(Keys keyData)
at System.Windows.Forms.TextBoxBase.ProcessDialogKey(Keys keyData)
at System.Windows.Forms.Control.PreProcessMessage(Message& msg)
at System.Windows.Forms.ThreadContext.System.Windows.Forms.UnsafeNativeMethods+IMsoComponent.FPreTranslateMessage(MSG& msg)
|
|
|
|
|
I am posting the full code that worked for me. it is written for a button_click event. if u want it for key_press please wait for a few days. i will ask around and tell u. the code that worked for me is:
Imports System.Data
Imports System.Data.SqlClient
Imports System.Data.SqlDbType
Public Class Form5
Inherits System.Windows.Forms.Form
.
.
.
.
Dim dsdata2 As New DataSet
Private Sub Form5_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim sqlcon2 As New SqlConnection(constr)
Dim sqladp2 As New SqlDataAdapter
Dim cmdstr1 As New SqlCommand
Dim strq1 As String
sqlcon2.Open()
strq1 = "select * from Doctor"
Try
sqladp2.SelectCommand = cmdstr1
sqladp2.SelectCommand.CommandText = strq1
sqladp2.SelectCommand.Connection = sqlcon2
dsdata2.Clear()
sqladp2.Fill(dsdata2, "SearchResult")
If dsdata2.Tables("SearchResult").Rows.Count > 0 Then
DataGrid1.DataSource = dsdata2
DataGrid1.DataMember = "SearchResult"
DataGrid1.Refresh()
End If
cmdstr1.Dispose()
sqlcon2.Close()
sqlcon2.Dispose()
sqladp2.Dispose()
Catch empexp As SqlException
MessageBox.Show(empexp.Message)
End Try
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If dsdata2.Tables("SearchResult").Rows.Count > 0 Then
dsdata2.Tables("SearchResult").Rows.RemoveAt(DataGrid1.CurrentRowIndex)
DataGrid1.Refresh()
Else
MsgBox("No Data To Delete")
End If
End Sub
End Class
Hope this will help u.
|
|
|
|
|
I am building a web form that connects to an Access database. When the DataAdpater tries to fill the DataTable the following error occurs:
The Microsoft Jet database engine cannot open the file 'C:\Inetpub\wwwroot\Database\InternalUseLog\db1.mdb'. It is already opened exclusively by another user, or you need permission to view its data.
I'm the only one using the database so I think I need to get permission. What do I need to do to get permission?
Thanks
|
|
|
|
|
That looks like a directory under the IIS. Are you sure your db isn't already locked up by another process? What happens if you try to open it simply with Access?
|
|
|
|
|
I ran into this problem a few years back. The issue was that the folder did not provide proper NTFS permissions to rwx the file.
Hope it helps.
|
|
|
|