|
Hi,
i have two textbox,one button & datagrid.Now i insert datas into DB(access) when i click the button @ the same time show information in datagrid...So retrieve from DB
This result normally ill cme.but last insert datas only missing.
so i want to refresh DB in same button....
Plz give me solution..
Kannan
|
|
|
|
|
This question made absolutely no sense. I have no idea what you're trying to do.
|
|
|
|
|
Best way is reload the data into datagrid.
|
|
|
|
|
Hi
1. I migrated vb6 project to vb.net project.
2. The msdatagrid in vb6 is migrated to vb.net axdatagrid
3. while i tried to bind data to that axgrid like
ReferenceGrid.DataSource = ds.Tables(0)
it shows error as cannot cast .....
4. Then i used this code to caste it
ReferenceGrid.DataSource = CType(ds.Tables(0), msdatasrc.DataSource)
5. still i cannot bind datasource to axgrid getting error as:
Unable to cast object of type 'System.Data.DataTable' to type 'msdatasrc.DataSource'
6. Can any one give me code to bind data to converted axdatagrid.
--------------------------------------------------------------------------------
chandra shekar thota
|
|
|
|
|
You cannot bind a .NET type to the old FlexGrid. Replace the old grid with the DataGridView in the Toolbox and then you can bind that to your .NET DataSet or DataTable object. Of course, if there's other code that manipulates the old grid, you'll have to replace that code with something that does what you need in the DGV.
|
|
|
|
|
Hi Dave,
Excellent Answer. I tried to use new grid and confused whether to use Datagrid or DataGridView. I also found all event which are there in VB6 Grid are not there in VB.Net Grids.Please suggest me some thing to implement this. I am looking for add button control in vb.net grid also.
Suggest me.
modified on Saturday, December 27, 2008 2:57 AM
|
|
|
|
|
There is no button in the grid. Normally, you would supply this button seperately and supply an appropriate input form or control to create a new record in the DataSet/DataTable you have the grid bound to.
|
|
|
|
|
Hi All,
I am creating an application in vb.net 2008 and Sql server 2005
I want to create a shared folder in the Server system, Than can be acceasable from all the Other System.
And This file using all the User Access Rights.
How can I create the Access Rights
Arindam Banerjee
Sr. Software Developer
Rance Computer Pvt Ltd.
Kolkata (India)
|
|
|
|
|
Use following code
Dim strPath As String = "C:\Gaurav"
Dim dir As String = IO.Path.Combine(strPath, "Temps")
Dim dirSecurity As New System.Security.AccessControl.DirectorySecurity
Dim rul As New Security.AccessControl.FileSystemAccessRule("Everyone", Security.AccessControl.FileSystemRights.FullControl, Security.AccessControl.AccessControlType.Allow)
dirSecurity.AddAccessRule(rul)
IO.Directory.CreateDirectory(dir, dirSecurity)
Dim sharename As String = "ServerFolder"
Dim cmdstring As String = "cmd /c net share """ & sharename & """=""" & dir & """" & " /unlimited"
Shell(cmdstring)
|
|
|
|
|
The basic code behind creating a share can be found here[^]. It's in C#, but is easily translatable to VB.NET using any online code conversion tool.
|
|
|
|
|
-------------------------------------------------------------------
:::: Great Indian Developer Summit 2009 - GIDS .Net ::::
:::: 24 April 2009 ::::
:::: J N Tata Auditorium, IISc, Bangalore ::::
:::: http://www.developersummit.com ::::
-------------------------------------------------------------------
Dear Group members,
The economic downturn will run out of steam trying to outdo the 'ready and waiting' software professional. Packed with premium knowledge, action plans and advise from been-there-done-it veterans, creators, and visionaries, the 2009 edition of Great Indian Developer Summit features focused sessions, case studies, workshops and power panels that will transform you into a force to reckon with.
Dot Net Speakers at the 2009 edition of GIDS include: Todd Anglin, Beat Schwegler, Chad Hower, Donald Belcham, Venkat Subramaniam, Kevin Babcock, Stephen Forte, Nikhil Kothari and Prabhu Sunderraman. The conference this year has sessions on Visual Studio 2008 & .NET 3.5, ADO.NET Entity Framework, T-SQL, ASP.NET AJAX 4.0, Databases/SQL Server/Language Integrated Query (LINQ), C# 4.0/WF/WCF/WPF, BizTalk Server/BPM/SOA, SharePoint & Search, Visual Studio Team System, ASP.Net MVC, Silverlight, Spring .NET, DWM, cool and new technologies from the Microsoft Stables. and much more. Please have a look at http://www.developersummit.com/speakers.html for more info on the speakers and the sessions.
Register before the 29th of December for Rs. 1,999/-. Besides the learning at the GIDS.Net conference on Wednesday, the 22nd of April, this fee also includes:
1. Discount of 35% on the standard fee
2. Assured Gift - GIDS 2009 Cult T-shirt (upon receipt of payment on or before Jan 12 2009)
3. Entry into a lucky draw for the following gifts: Sony WEGA 29 inches (1), Mac Air Book (1), Wireless Mouse (50 nos), Apple iPOD 120 GB (5 nos).
4. Lunch and refreshments
5. Conference materials
6. Complimentary invitation to Cyrus Broacha's show at the Great Indian Developer Awards on Saturday, the 25th of April 2009
So hurry up and register now under the GIDS Loyalty discount scheme: http://www.developersummit.com/registration.html
Wishing you and your family a Merry Christmas and a wonderful year ahead.
Thanks,
Shaguf
http://www.developersummit.com/
info@developersummit.com
|
|
|
|
|
Message reported as spam.
|
|
|
|
|
hey, guys i was wondering if anyone can help me debug this code as i have been trying for days and still have not find out the mistake i make. The portion which i have posted is one of the sub in my server application. I edited the code i found so that the server is able to reply to its client and after editing server do make the reply but with some bug. For the 1st request from the client, the reply is perfectly fine but subsequent request, the browser omit 2 front letters of the sentence and i don't understand why.Struck with this error with quite some time already.
Help will be greatly appreciated.
Private Sub doChat()
Dim infiniteCounter As Integer
Dim requestCount As Integer
Dim bytesFrom(10024) As Byte
Dim dataFromClient, DataToClient As String
Dim sendBytes As [Byte]()
Dim serverResponse As String
Dim rCount As String
requestCount = 0
For infiniteCounter = 1 To 2
infiniteCounter = 1
Try
requestCount = requestCount + 1
Dim networkStream As NetworkStream = _
clientSocket.GetStream()
networkStream.Read(bytesFrom, 0, CInt(clientSocket.ReceiveBufferSize))
dataFromClient = System.Text.Encoding.ASCII.GetString(bytesFrom)
dataFromClient = _
dataFromClient.Substring(0, dataFromClient.IndexOf("$"))
msg("From client - " + clNo + " : " + dataFromClient)
rCount = Convert.ToString(requestCount)
serverResponse = "ok"
sendBytes = System.Text.Encoding.ASCII.GetBytes(serverResponse)
networkStream.Write(bytesFrom, 0, serverResponse.Length)
msg("From Server - " + serverResponse)
DataToClient = networkStream.Read(sendBytes, 0, sendBytes.Length)
broadcast(dataFromClient, clNo, True)
broadcast(serverResponse, "Server", True)
Catch ex As Exception
MsgBox(ex.ToString)
End Try
Next
End Sub
|
|
|
|
|
Hi,
your code is hard to read without proper formatting; please use the PRE tags for
code blocks that span several lines, they provide a non-proportional font, and pteserve
formatting (indentation).
Anyhow, networkStream.Write(bytesFrom, 0, serverResponse.Length) looks
suspicious to me: why would serverResponse determine how many bytes from "bytesFrom" should
be written?
|
|
|
|
|
Is tis ok?
Private Sub doChat()
Dim infiniteCounter As Integer
Dim requestCount As Integer
Dim bytesFrom(10024) As Byte
Dim dataFromClient, DataToClient As String
Dim sendBytes As [Byte]()
Dim serverResponse As String
Dim rCount As String
requestCount = 0
For infiniteCounter = 1 To 2
infiniteCounter = 1
Try
requestCount = requestCount + 1
Dim networkStream As NetworkStream = _
clientSocket.GetStream()
networkStream.Read(bytesFrom, 0, CInt(clientSocket.ReceiveBufferSize))
dataFromClient = System.Text.Encoding.ASCII.GetString(bytesFrom)
dataFromClient = _
dataFromClient.Substring(0, dataFromClient.IndexOf("$"))
msg("From client - " + clNo + " : " + dataFromClient)
rCount = Convert.ToString(requestCount)
serverResponse = "ok"
sendBytes = System.Text.Encoding.ASCII.GetBytes(serverResponse)
networkStream.Write(bytesFrom, 0, serverResponse.Length)
msg("From Server - " + serverResponse)
DataToClient = networkStream.Read(sendBytes, 0, sendBytes.Length)
broadcast(dataFromClient, clNo, True)
broadcast(serverResponse, "Server", True)
Catch ex As Exception
MsgBox(ex.ToString)
End Try
Next
End Sub
|
|
|
|
|
That is more code than before, some of it in PRE tags??
And I still don't like the line networkStream.Write(bytesFrom, 0, serverResponse.Length)
As serverResponse contains "ok" its length will always be 2! is that what you intend?
|
|
|
|
|
It is the same amount of code i posted earlier. Those in the PRE tags are those code whereby i think my mistake is at. As for the serverRespone.Length, 2 is not the intended length but i already change it but it seen like there is not much different. The reply i got are all rubbish.
|
|
|
|
|
Hi to All
I want to change the textbox text color When textbox properties enable = False the font in the textbox become gray color. How do I change the gray color to black color ?
Thanx
Khatri Mitesh
~Khatri Mitesh
khatrimitesh@hotmail.com
Bikaner (Rajasthan)
INDIA
|
|
|
|
|
It's not possible to change forecolor when it is disabled.
You can use ReadOnly property instead.
|
|
|
|
|
Simple - you need to create an owner drawn control ( OK, it's not simple ).
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Agreed....and it really isn't that bad to do.
Any suggestions, ideas, or 'constructive criticism' are always welcome.
"There's no such thing as a stupid question, only stupid people." - Mr. Garrison
|
|
|
|
|
You can do one more thing
use if condition when the u done disable operation don't do the disable show as disable.
|
|
|
|
|
hi
iwant to send sms from pc by data cabl conncted to nokia mobil 6300
how can i do it
|
|
|
|
|
There's no support for this built in, typically people pay to use a web service that allows them to send SMS. Your phone iwll have nothing to do with it,
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
I have a form , which contains the button , on clicking the button opens a child form. If I again clicks that button , My program does not
open the duplicate instance , But I have a case when there is a usability issue.
1. If I change the window state of the child form window like I set Normal and afterwards I minimize it.
Then my program assumes that the child form is minimize and change it's state to maximize, But this should not happen ,
It should change the state to restore ,
How should i implement this
If you have an apple & I have an apple and we exchange our apples, then each of us will still have only one apple but if you have an idea & I have an idea and we exchange our ideas, then each of us will have two ideas!
|
|
|
|
|