Are you the publisher? Claim or contact us about this channel


Embed this content in your HTML

Search

Report adult content:

click to rate:

Account: (login)

More Channels


Showcase


Channel Catalog


Channel Description:

Visual Basic Discussions plus .NET, C#, game programming, and more (http://www.VBForums.com)
    0 0
  • 01/10/19--02:48: VS 2015 Write Current Time
  • I want connect to a panel and update the time. Using my port sniffer I get the following when I tell it to update the time from a third party software. 00 09 14 16 01 09 13 06 05 00 a4 the 06 is the hour and the 05 is the minute So I can update the panel using the following code: Code: --------- Buffer = {&H0, &H9, &H14, &H16, &H1, &H09, &H13, &H6, &H5, &H0, &HA4} frmmain.SerialPort1.Write(Buffer, 0, Buffer.Length) --------- I have this code to convert the current time into hex format. Code: --------- Dim xHour As String = Format(DateTime.Now, "HH") Dim xMinute As String = Format(DateTime.Now, "mm") Dim decValue As Integer = 0 Dim hexString As String = Nothing decValue = Int(xHour.Trim) ' convert into hexadecimal hexString = Hex(decValue) Dim HexHour As String = hexString decValue = Int(xMinute.Trim) ' convert into hexadecimal hexString = Hex(decValue) Dim HexMinute As String = hexString --------- So how would I go about putting it together? I have tried Code: --------- dim str as string = "{&H0, &H9, &H14, &H16, &H1, &H09, &H13, &H," & xHour & "&H," & xMinute & "&H0, &HA4} frmmain.SerialPort1.Write(Buffer, 0, Buffer.Length) --------- Any Suggestions

    0 0
  • 01/10/19--03:22: Spoofing Googe
  • This is not a spoofing link...just a link to report on a bug in Google search that allows spoofing. https://wietzebeukema.nl/blog/spoofing-google-search-results It still isn't fixed.

    0 0

    hey i get this message operator + is not defined for types date and integer why? is there any replacement for the + ? this is my code Code: --------- Private SelectDate As Date Control.DayView.ShowDays(SelectDate + 1, SelectDate + 1) --------- tnx for any help salsa :)

    0 0
  • 01/10/19--07:10: What's this all about ?
  • Hi, For a while now I've been getting a warning each time I open this forum, sometimes it adds another warning... the same one, so that I now have 11 such warnings, and I don't know what it's telling me, and I don't know how to remove them. ---Quote--- PHP User Warning: fetch_template() calls should be replaced by the vB_Template class. Template name: bbcode_highlight in ..../includes/functions.php on line 4197 www.developer.com A Developer.com Site __________________________________ ---End Quote--- Oh... Now that I've previewed the post I see there's a URL included, after I've posted this, I'll take a look at the website, it'll probably turn out to be some sort of a scam or maybe an ad. for something. Poppa. PS. Yeah, looks like an ad. looks pretty harmless, I still want to remove them though. Pop.

    0 0

    I have moved some functionality in my vb.net (vs2015) desktop app that I would like to be able to change dynamically to a dll created in a different project. The idea is to be able to distribute a new dll to users to upgrade functionality, kind of a patch (but aimed at customizing rather than updating). Experimenting, since the application directory is read only, I have registered the dll in a folder of my choosing (by adding reference from my main project) and created an interface to replace the dll at runtime from within my app. This works fine. To actually make it work I now need to be able to have my setup project copy the dll to some location (preferably a folder in C:\Users\Public where I am already placing a database used by the app) from where my app will find it. How would I go about that? Sorry for not presenting a lot of info about what I have already tried. I attempted to simply put the dll in the same file system folder in the setup project where the database is copied from. That didnt work and it broke all my dependencies. I now have to rebuild the setup project from scratch and I thought I would ask before I wreck everything again.

    0 0

    Hello, I want to use the DataGrid control in order to show some MS SQL table data into a form, but I'm getting the message: "The subject is not trusted for the specified action". Please suggest a solution, as I cannot get rid of this message. I'm using VB for Applications 7.1. Sorry for posting into VB 6, but I didn't find anything about VB 7 or VB 7.1 Initially I used the ListBox control which worked OK, but I noticed that it's limited to 10 columns and my table has 11.. Thanks for your support. Kind regards, Emil

    0 0

    Hi I have a recordset (using oo40) , my records are from a hierachical querie , I would like put in MSHflexgrid with buttom plus (+) that expand others row. I searched in google, but no find example

    0 0

    Hello.. I have created a login form for my project,I have searched on google and found out to make the integrated security=false but it still doesnt work,and when i install it on another pc it shows me the error : Code: --------- XCEPTION : Handled MESSAGE : Login failed. The login is from an untrusted domain and cannot be used with Windows authentication. SOURCE : .Net SqlClient Data Provider TARGETSITE : Void .ctor(System.Data.ProviderBase.DbConnectionPoolIdentity, System.Data.SqlClient.SqlConnectionString, System.Data.SqlClient.SqlCredential, System.Object, System.String, System.Security.SecureString, Boolean, System.Data.SqlClient.SqlConnectionString, System.Data.SqlClient.SessionData, System.Data.ProviderBase.DbConnectionPool, System.String, Boolean, System.Data.SqlClient.SqlAuthenticationProviderManager) STACKTRACE : at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, DbConnectionPool pool, String accessToken, Boolean applyTransientFaultHandling, SqlAuthenticationProviderManager sqlAuthProviderManager) at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions) at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions) at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection) at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection) at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection) at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection) at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection) at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry) at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry) at System.Data.SqlClient.SqlConnection.Open() at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) at DG.DentneD.LoginForm.button1_Click(Object sender, EventArgs e) in C:\Users\windows\Desktop\New folder (19)\dentned-master\DentneD\LoginForm.cs:line 56 at System.Windows.Forms.Control.OnClick(EventArgs e) at System.Windows.Forms.Button.OnClick(EventArgs e) at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent) at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ButtonBase.WndProc(Message& m) at System.Windows.Forms.Button.WndProc(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) --------- and here is my LoginForm code Code: --------- doctors.last_login = DateTime.Now; string srcConnString = null; var csBuilder = new SqlConnectionStringBuilder(srcConnString); csBuilder.Remove("Integrated Security"); csBuilder.UserID = "sa"; csBuilder.Password = "sasa"; var connString = csBuilder.ToString(); SqlConnection sqlcon = new SqlConnection("data source=DESKTOP-Q8526KR;initial catalog=dentned;integrated security=True;user=sa;password=sasa;MultipleActiveResultSets=True;App=EntityFramework""); string query = "Select * from dbo.doctors Where doctors_username = '" + txtUsername.Text.Trim() + "' and doctors_password = '" + txtPassword.Text.Trim() + "'"; SqlDataAdapter sda = new SqlDataAdapter(query, sqlcon); DataTable dbdoc = new DataTable(); //sda.Fill(dbdoc); if (dbdoc.Rows.Count == 1) { FormMain objfrmMain = new FormMain(); this.Hide(); if(dbdoc.Rows[0][8].ToString()!="admin") { objfrmMain.MainMenuStrip.Items[0].Visible = false; objfrmMain.MainMenuStrip.Items[2].Visible = false; objfrmMain.MainMenuStrip.Items[3].Visible = false; objfrmMain.MainMenuStrip.Items[4].Visible = false; objfrmMain.MainMenuStrip.Items[5].Visible = false; objfrmMain.MainMenuStrip.Items[8].Visible = false; } objfrmMain.Show(); } else { MessageBox.Show("Username-i ose passwordi eshte gabim !!!!!!!!!!!!!!!!!!!"); } } ---------

    0 0

    I recently purvchased an NEC PA27Q. The default recommended display resolution is 2560 x 1440. I have one program that was made with VB6 that is now giving a run time error 6 (overflow) only at this resolution. When I change to any lower resolutions the program opens and functions normally. Is there a reason why? Can anything be done to rectify this other than reducing the display resolution each time I want to open said program?

    0 0

    Can anyone tell me how to check a checkbox in excel using vb.net 2017? I can read/write cells no problem, but attempting to check a checkbox just leaves the cell behind it saying "True". I've looked online and all the solutions I find seem to be from earlier versions of vb.net and 2017 doesn't support any of those solutions. Can anyone help? Thanks.

    0 0
  • 01/10/19--16:37: Need to get an IPv4 block
  • Does anyone know where to get IPv4 space? Any previous experience is appreciated! :wave:

    0 0

    This code on a double-click of my listbox will move the selected item to the top (simple). Code: --------- Private Sub List1_DblClick() Dim ListItem As String ListItem = List1.List(List1.ListIndex) List1.RemoveItem List1.ListIndex List1.AddItem ListItem, 0 End Sub --------- But I would like to move an item up or down in my list (song list in Jukebox) by using the mouse and 'dragging' it to any given location/listindex. As easy??? EDIT---title is misleading...Should read: Moving any Listbox Item to ANY Position.

    0 0

    Syntax for if statement

    0 0

    Hi, I had .rpt files, where connected using DAO to a local Access DB and I was viewing the report in VB6 using CrystaActiveXReportViewer. I have modified the reports to connect using ADO to the the Access file. It is working when I open the .rpt file with Crystal Report and everything seams working. But the problem is I cannot use same VB6 code and control to view the report. I get this error: Attachment 164637 (http://www.vbforums.com/attachment.php?attachmentid=164637) Do you have any idea what is the issue here? Apreciate your help.

    0 0
  • 01/10/19--20:36: Weird Little Glitch
  • Here's a weird glitch I've never run across before: Code: --------- * Option Explicit Enum test a$ b$ c$ End Enum Private Sub Form_Load() Debug.Print c, TypeName(c) End Sub * --------- That code runs just fine, and the Enum variables all report as Long types. I guess the single character typing is ignored.