Skip to content

Visual Basic

Visual Basic Questions

This category can be followed from the open social web via the handle visual-basic@forum.codeproject.com

34.4k Topics 120.1k Posts
  • Map network drives--Plzz replyy

    question csharp sysadmin
    2
    0 Votes
    2 Posts
    0 Views
    P
    Here Try this. This is the code to add the network Drive Dim WshNetwork as Object WshNetwork = CreateObject("WScript.Network") WshNetwork.MapNetworkDrive("L:", "\\Server\Resource") Of course you can have the letter be whatever and just fill in your resource Here is the Code to remove it after the object is created WshNetwork.RemoveNetworkDrive("L:") And of course it the letter that you specified earlier. I hope this helps
  • crystal reports

    tutorial
    3
    0 Votes
    3 Posts
    0 Views
    J
    OK, here's what I did in VB6 w/ Cr8.5: Set crystalApplication = New CRAXDDRT.Application Set crystalReport = crystalApplication.OpenReport(strReportFile, 1) With crystalReport .ExportOptions.DiskFileName = strExportFile .ExportOptions.DestinationType = crEDTDiskFile .ExportOptions.FormatType = crEFTWordForWindows ' crEFTPortableDocFormat .ExportOptions.WORDWExportAllPages = True .DisplayProgressDialog = False .ParameterFields(1).AddCurrentValue strGroupName ' .RecordSelectionFormula = strSelection .Export False End With Set crystalReport = Nothing Set crystalApplication = Nothing FYI, to the best of my knowledge, this requires CR 8.5 developer edition. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
  • Visual Basic 6.0 Skinning??

    help tutorial question
    4
    0 Votes
    4 Posts
    0 Views
    W
    hey, if u wanna make ur life easy just use activeskin v4.3 by softshape or better skincrafter. Both of these are activex controls and are very easy to use. Just download and install them. Or u could use VBskinner it's easier u just have to place the control over your form and voila u get a skinnable application. u can also give it an XP or Win 2003 look and feel if u wish complete with menus and buttons. :eek:;):rolleyes:
  • Converting Binary Files

    question
    2
    0 Votes
    2 Posts
    0 Views
    D
    Are you talking about reverse engineering someones .DLL? A question like this from an Anonymous user. I'll stand back and watch to see if anyone bites on this... RageInTheMachine9532
  • Get domains & workgroups-reply plzzzz

    question csharp sysadmin
    4
    0 Votes
    4 Posts
    0 Views
    J
    I think the key is to enumerate the Properties collection of each child node in the collection of DirectoryEntry children. While there may be a more elegant way of doing so, the way that I was able to get a list of users, for example, was to do something like this: Dim entry As New DirectoryServices.DirectoryEntry For Each child As DirectoryServices.DirectoryEntry In entry.Children Dim propertyValue As Integer = 0 Try propertyValue = CType(child.Properties("UserFlags").Value, Integer) Catch ex As Exception ' if it throws an exception, it's not a user item propertyValue = 0 End Try If (propertyValue = 513) Then Console.WriteLine(child.Name) End If Next If you look at the property names in the Properties collection, you should be able to isolate which ones are Domains, which ones are workgroups and which ones are users, etc. I believe there may be a more elegant solution, but I haven't found the best reference for that solution yet. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
  • vbscript compiler error

    question help
    2
    0 Votes
    2 Posts
    0 Views
    J
    Although I'm not entirely sure what your asking, the whole enchilada can be found here[^] What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
  • What is ADO.NET?

    question csharp tutorial
    2
    0 Votes
    2 Posts
    0 Views
    J
    Once upon a time, Microsoft created a standard set of API's that allowed programmers to access SQL and ODBC databases through a common programming interface. Since Microsoft's flagship technology at the time was known as ActiveX, they called it Active Data Objects, or ADO. When they decided to create a whole framework for developers to extend or implement in their code (.NET), they updated the acronym to comply with the new framework terminology, so they called it ADO.NET. MSDN: ADO.NET provides consistent access to data sources such as Microsoft SQL Server, as well as data sources exposed through OLE DB and XML. Data-sharing consumer applications can use ADO.NET to connect to these data sources and retrieve, manipulate, and update data. In VB.NET, this means that you can use the classes in System.Data (SqlClient and OleDb and their children) to access data stored in databases. What a piece of work is man, how noble in reason, how infinite in faculties, in form and moving how express and admirable . . . and yet to me, what is this quintessence of dust? -- Hamlet, Act II, Scene ii.
  • icons of task manager??

    json tutorial question
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • open a document

    tutorial
    4
    0 Votes
    4 Posts
    0 Views
    A
    sorry,but the link don't work, can you give me an other link. thank you
  • Determining Hardware in machine

    hardware tutorial question
    2
    0 Votes
    2 Posts
    0 Views
    L
    can you specify which hardware you want? you can try use the wmi ;P
  • How can I Display of File Creation Dates

    help
    2
    0 Votes
    2 Posts
    0 Views
    N
    use the FileInfo method provided in the system.IO class. copy and paste the following code into a new project, test it out, and edit. edit: oh ya, this is for a console application. Imports System.IO Module Module1 Sub Main() Dim myFileName As String = "C:\file.txt" Dim myFileInfo As New FileInfo(myFileName) 'print time created on 24 hour scale Console.WriteLine( _ myFileInfo.CreationTime.Hour _ & ":" _ & myFileInfo.CreationTime.Minute _ & ":" _ & myFileInfo.CreationTime.Second) 'print the date created in YYYY/M/D form Console.WriteLine( _ myFileInfo.CreationTime.Year _ & "/" _ & myFileInfo.CreationTime.Month _ & "/" _ & myFileInfo.CreationTime.Day) Console.ReadLine() End Sub End Module ------------------------ Jordan. III
  • Debug COM+ call to .NET

    debugging csharp com workspace
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • class variable name

    question csharp
    8
    0 Votes
    8 Posts
    0 Views
    B
    There is no way to do this in C#. System.Diagnostics.StackFrame gets the closest, but it does not know about instance information; only types. There is a probably a more natural way to get what you want. Maybe passing in an object which has Address members and letting CallingSomething iterate it's members looking for them? Then it could output all the members which have a certain type by name. Without knowing more about the requirements, it's hard to say. -- Aaron
  • unhandled exception

    question
    9
    0 Votes
    9 Posts
    0 Views
    L
    owh....ok...thanx man...sorry for taking your time
  • please some help... net sends

    help tutorial question
    6
    0 Votes
    6 Posts
    0 Views
    N
    maybe this will help http://www.eggheadcafe.com/PrintSearchContent.asp?LINKID=572[^]. research a little. ------------------------ Jordan. III
  • How To inserT merge module in deploymenT?

    sysadmin tutorial question workspace
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • free tutorials

    csharp
    2
    0 Votes
    2 Posts
    0 Views
    L
    try this link below http://www.dotnetspider.com/technology/ http://www.programmingtutorials.com/vbnet.aspx http://www.vbdotnetheaven.com/Sections/Tutorials.asp most of the site teach u by showing example.....you can learn from the examples....;)
  • My Network Places

    sysadmin help tutorial
    5
    0 Votes
    5 Posts
    2 Views
    L
    lol
  • Make vbKeyReturn equivalent to vbKeyTab

    question
    5
    0 Votes
    5 Posts
    0 Views
    C
    I don't know why, but KeyPress tends to work better for this (for me, at least) than KeyDown. ' include whatever controls you want to have this functionality Private Sub KeyPressed(ByVal sender As Object, ByVal e As KeyPressEventArgs) Handles _ TextBox1.KeyPress, TextBox2.KeyPress, TextBox3.KeyPress, TextBox4.KeyPress If e.KeyChar = ChrW(13) Then ProcessTabKey(True) e.Handled = True End If End Sub This isn't the only way to do what you want, but it works. Charlie if(!curlies){ return; }
  • Get the application icon

    tutorial question
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied