esquima Posted October 15, 2007 at 04:24 PM Report Share #140210 Posted October 15, 2007 at 04:24 PM Tou a fazer uma consulta a bd e queria mostrar os dados no meu programa..a melhor manerira de mostrar e por uma datagrid ou ha outra maneira melhor? Link to comment Share on other sites More sharing options...
Asgorath Posted October 15, 2007 at 04:31 PM Report Share #140211 Posted October 15, 2007 at 04:31 PM Sim datagrid são muito pratico para mostrar dados quando tems muitas colunas. "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
Weasel Posted October 15, 2007 at 04:50 PM Report Share #140216 Posted October 15, 2007 at 04:50 PM Em PHP+Html para "mostrar" 2700 registos demora +/- 1 minuto ou mais...nem tive a contar Em VB.NET usando a DatagridView demora menos de 3 segundos Estou a falar de PostgreSQL como base de dados... Knowledge to the masses Link to comment Share on other sites More sharing options...
esquima Posted October 15, 2007 at 05:12 PM Author Report Share #140223 Posted October 15, 2007 at 05:12 PM Digam me so uma coisa queria mandar uma msgbox com botao de ok e cancel, so eu que tenho de dar as indicaçoes do codigo que vai fazer quando carrego no ok ou no cancel?? Link to comment Share on other sites More sharing options...
Weasel Posted October 15, 2007 at 05:17 PM Report Share #140224 Posted October 15, 2007 at 05:17 PM Para isso fazes assim: If (MsgBox("executar?", MsgBoxStyle.OkCancel) = MsgBoxResult.Ok) Then 'Carregou no OK Else 'Carregou no Cancel End If Knowledge to the masses Link to comment Share on other sites More sharing options...
Asgorath Posted October 16, 2007 at 08:53 AM Report Share #140374 Posted October 16, 2007 at 08:53 AM If MessageBox.Show("ola", "titulo", MessageBoxButtons.YesNo) = Windows.Forms.DialogResult.No Then Else End If "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
Weasel Posted October 16, 2007 at 09:20 AM Report Share #140378 Posted October 16, 2007 at 09:20 AM Asgorath, colocas-te o código apenas....mas podias dizer, se esse é melhor do que o que eu dei, e já agora, porque (assim também aprendo coisas novas 😉 ) Knowledge to the masses Link to comment Share on other sites More sharing options...
Asgorath Posted October 16, 2007 at 09:50 AM Report Share #140381 Posted October 16, 2007 at 09:50 AM Esqueci de mencionar que usar comandos vb6 em .net tem pior desepenho de que usar o equivalente .net. Por exemplo usar CInt em vez de Convert.ToInt32. Outra sugestão poe Option Explicit On (que te obriga a declarar tudo) antes dos imports de cada form. poe tambem Option Strict On (que te obriga a fazer a conversao de tipos, late bindind tem pior desenpenho de que early binding) com o Strict off o seguinte codigo compila Private Sub MenuItem3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem3.Click Dim posguia, guia, posenc, grupo, traduz, lingua, chave As Int32 guia = Me.ComboBox1.Text End Sub Com o strict on es obrigado a mudar o codigo para Private Sub MenuItem3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem3.Click Dim posguia, guia, posenc, grupo, traduz, lingua, chave As Int32 guia = Convert.ToInt32(Me.ComboBox1.Text) End Sub "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
Weasel Posted October 16, 2007 at 10:36 AM Report Share #140398 Posted October 16, 2007 at 10:36 AM Não explicas-te a do MsgBox :dontgetit: Knowledge to the masses Link to comment Share on other sites More sharing options...
Asgorath Posted October 16, 2007 at 11:10 AM Report Share #140413 Posted October 16, 2007 at 11:10 AM msgbox é vb6 messagebox é vb-net "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
AKueda Posted October 16, 2007 at 11:33 AM Report Share #140418 Posted October 16, 2007 at 11:33 AM não... msgbox também dá para .NET eu uso assim e dá na mesma... Link to comment Share on other sites More sharing options...
Tiago Salgado Posted October 16, 2007 at 12:47 PM Report Share #140431 Posted October 16, 2007 at 12:47 PM não... msgbox também dá para .NET eu uso assim e dá na mesma... O que o Asgorath disse, também era a minha ideia. Fiquei confuso foi ver na MSDN recomendarem o uso da MsgBox em vez da MessageBox. Link to comment Share on other sites More sharing options...
Weasel Posted October 16, 2007 at 12:53 PM Report Share #140433 Posted October 16, 2007 at 12:53 PM :dontgetit: afinal em que ficamos ? 😉 Knowledge to the masses Link to comment Share on other sites More sharing options...
NuGuN Posted October 16, 2007 at 01:20 PM Report Share #140450 Posted October 16, 2007 at 01:20 PM ... O que o Asgorath disse, também era a minha ideia. Fiquei confuso foi ver na MSDN recomendarem o uso da MsgBox em vez da MessageBox. Se não estou a fazer confusão, já vi algures no forum um utilizador que dizia que MsgBox não éra a melhor solução porque lhe dava alguns problemas, e utilizava outra forma que não me lembro (isto se não for em VB6....) Cumps Link to comment Share on other sites More sharing options...
Asgorath Posted October 16, 2007 at 01:34 PM Report Share #140457 Posted October 16, 2007 at 01:34 PM Façam download desde fanstastico livro 'Improving .NET Application Performance and Scalabily' Ja conhecia muitas dicas contidas nele sobre String por exemplo. http://www.microsoft.com/downloads/details.aspx?familyid=8a2e454d-f30e-4e72-b531-75384a0f1c47&displaylang=en "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
Weasel Posted October 16, 2007 at 02:31 PM Report Share #140485 Posted October 16, 2007 at 02:31 PM Thanks Asgorath 😉 Knowledge to the masses Link to comment Share on other sites More sharing options...
Tiago Salgado Posted October 16, 2007 at 05:06 PM Report Share #140569 Posted October 16, 2007 at 05:06 PM Asgorath já o leste ? Link to comment Share on other sites More sharing options...
Asgorath Posted October 16, 2007 at 10:36 PM Report Share #140615 Posted October 16, 2007 at 10:36 PM Certas partes , o único inconveniente para alem das 1100+ paginas e é para .NET 1.1 em ves 2.0 "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now