Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




How To Get User, Client Information Connected To Citrix Server?


How to get user, client information connected to Citrix server?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Client Information Connected To Citrix Server
Hello,

How can I get user, client information connected to Citrix server?

User will connect to Citrix Server using Web Interface and Windows Login/Password. Once user logs onto Citrix, he will see a kind of Desktop within a Webpage and that desktop shows Icons to run applications. These applications are already published on Citrix Server.

I have a VB 6.0 application published on Citrix Server and user will run it through the Icon shown within Citrix Desktop. When application runs, it will load on user's Windows machine. From this VB 6.0 app, I want to capture user's machine information (Name, IP Address), which has logged onto Citrix and running the application.

I am able to get Windows login username of the user. But if I use gethostname, it gives me machine info of the Citrix server and not of the user machine who is logged onto Citrix.

Can anyone help?

Thanks,
Hardik

Running Over A Citrix Server Or Other Client System
my application current is standalone, and can be run on either a single machine or over a network comfortably, however i have had a request from an organization to have my software run on their network that is running citrix networking. i guess it would be a remote desktop type scenario, where each computer is simply a terminal and gets the apps etc from the server.

what happens is when a user logs into a machine, they dont get a normal desktop so to speak, they see applications available to them, that they are able to run. how would this effect my software, what changes will i need to make and what are the pitfalls.

can someone shed light on this issue for me. my application has a VB6 frontend and Access database backend, so im thinking leave the database eon the server so its available to everyone. if only one copy of the front end is installed, say on the server, and somone opens it, will it be locked to other users by the OS? or is it available at all times? I sue ADO connections in my app to the database, will this allow other users to access, edit, delete and save data to it while other users have it open?

grrrrr so many questions.......... please someone shed light as im flying blind.

Server Connected, Client Not
Ok, my program is using 2 programs, the server and client, the server side is saying that it is connected, however the client isnt, so im assuming its the client code, heres the code:


Code:
MsgBox "Attempting To Connect To Server..."

WinsockMain.Close
WinsockMain.Connect strDataLoaded(2), strDataLoaded(3)

xTimer = Timer + 1
Do While Timer < xTimer
Loop

If Not WinsockMain.State = 7 Then
MsgBox "Could Not Connect! The Server Could Be Offline Or Busy!"
WinsockMain.Close
GoTo NextNext2
End If

If WinsockMain.State = 7 Then
MsgBox "Connection Successful!"
WinsockMain.SendData strDataLoaded(1)
End If

Heres The Variables:
strDataLoaded(1) = "Filepath Here"
strDataLoaded(2) = "127.0.0.1"
strDataLoaded(3) = "6669"

and on the server side, its using localport 6669 and is accepting the clients connection, i cant figure out y the client is not connecting properly

Client Exists But Server Behaves Still Connected
Hi everybody,

I have a problem that I havent figured out the reason behind it yet. When a client connects to my server, and lets say stays connected for an hour or so, the server doesnt realize if the client exits.

But it works when they are connected for respectively small amount of time.

I do not have a ping system to check whether a client is idle or not. Does anybody have any ideas?

How comes a winsock control cant realize that the client is not connected anymore?


EpcH

How To Get All Client IP Address Connected To Server(main Computer)?
we have 3 computers at home, we set-up all computers connected to LAN so we
can share files, my computer serves as the main computer, i just want to get all
IP address of the computers connected to main computer(that is my computer) and list them
in combo box or Listview. How to do this using winsock(VB6)?Need your help. thanks.



Edited by - edd_hills on 6/5/2007 9:43:46 PM

Citrix...when Running An App From A Citrix Server...question...
When running an app using a citrix server is there anyway to get info about the client PC it's running on???

I need to get the PC name/IP address/MAC address of the PC.
But I cant see a way to do it as when I do anything to get any info about the PC it gets the servers details and not the client

Woka

Terminal Server Client Information
Has anyone managed to use VB to get any information from a WTS client session (on Citrix ICA client). What I've trying to do is get the login script to save a load of information to a file so that I can do an audit on the number of WTS clients we have on the network. The problem is that the default reported client name is not the PC's network name so there are duplicates out there from our image roll outs. Anyone got any ideas?

Client - Server Sending Information Problem.
Hi there to all gurus and experts...

Is there any simple code sample or tutorial on this problem that teach us ...

How to code in VB where this Computer A informs Computer B that Computer A is Online and shows its ip address in Computer B's Form.

Illustrated:

Com A---------------->Com B (Inform A's Online Status)
and
Com A----------------->Com B (Tells Com A's ip address)

Just a small, simple and working code will do..and I'll do the improvising from there...

Thanks again.

GENERAL INFORMATION Streaming A WebCam To A Client/Server Chat App
First off, how do you think MSN Instant Messanger goes about web cam abilities?
How do you think they pull this off?
Are you connection to the users machine w/ IP address and Port Number to gain access to the web cam?
When the web cam is set up, is it setting it up on a server somewhere or is it just client connecting to client?
Anything else you can think of.

Im just curious. I have an idea to build an app, either a client/server chat app w/ web cam abilities are an app that allows the company
to have meetings via web cam, etc.....................

I kind of have both sections completed as stand alone projects but im not sure as how to handle the streaming of the web cam.

Im curious as to if you think there is a delay w/ MSN IM, when viewing the web cam of a couple of seconds are is it pretty much real time.

With the method i have used for streaming the video, i have about a 15 second delay (when i say a 15 second delay i just mean that you see what i did 15 seconds ago. The streaming works fine and is beautiful, i would just like to see more real time)), i would like to get that down to like 1 sec it possible but maybe im blowing this out of poprtion and maybe a 15 sec delay is not that bad. I was under the impression that
MSN Instant messanger was real time and if so how are they able to get it in real time?

Thats really it, i just wanted to pick the minds of everyone and kind of see what they think. I have never done anything like this before and i am quite impressed w/ the progress i have made so far, but i want to be able to implement this in the best way possible so that there are great benefits.

Citrix ICA Client
Ok, anyone familiar or has used this in your apps?

My companyn uses a dialup to connect to our Citrix server. They supplied us with ICA Dialup software, which, when dialed, displays the NT desktop on the server. I wish to add this "screen" within my program once the connection is made. I can make the connection through code, but once logged on, the ICA program takes over...

I want it within my program.

Anyone ever worked in this arena?

I appreciate any help that can be given on this subject.

Has Anyone Integrated The Citrix ICA Client Into A VB App?
I am trying to write a simple VB app that will accept username & password and then launch the Citrix client passing those variables. Any help or suggestions would be greatly appreciated.

Installing Citrix Ica Client On Emulator
Hello all,

Can anybody tell me how can I install ica client on my Emulator while Active Sync doesn't work with my Emulator?

Thank you in advance,
Zorik

How To Open Server From Client Computer By Vb (using User And Password)
Hello
Every one can any one help me how to open server from client
computer using server name and server password not open databse
i m opening server by vb (using user and password).as like when
open a computer then write computer name and computer
password)
Paritosh

Creating Multi-User Client/Server Application
Hi all

I am trying to create a multi-user Client/Server application using winsock can anyone help me to create on as i m getting Connection Time out even everything is working fine and no restriction is there on the server end.

Terminal Server Client With MSRDP.OCX On User Defined Port
hi,

anyone knows how to set a user-defined port when connecting from within VB using the MSRDP.OCX from MS?

thx, cu
waldfee

Network Information Transfer, Client To Client. Real Time
I need to know how difficult it would be to use <programA> to locate all computers on a network, ping them to see if they are running the same <programA>. Then start a connection with that pc.

On top of that transfer data real time. Like a chat program. My idea is to make a battleship like game, but to put both people on the same screen would be pointless.
I've done a search in the forums. And honestly I don't know what to search for anyway.

If it's to much to get into this early, I'm not going to worry about, but if it's relatively easy.
Like I've already done skin loading snap to edge of screen skin with resize desktop clock shell txt i o. Just to give you a basis for my current skill level. lol I'm not too good huh?

Putting VB App On A Citrix Server
Can I put my VB app on a Citrix server and then allow remote users to run it?

Irc Client - Check If Is Connected
while building a small irc client i noticed that while using a router the client didn't showed any error, so it wouldn't fire the error event in the winsock control.
Is there any other way to check if the client is connected? Like using a timer control?

thanks

Winsock, I Made A Server-Client... Now I'm Trying To Make A Server-Client+++
Trying to get this Winsock Chat thing to support more than 1 person. I don't know at ALL what to do... Could anyone push me in the right direction?

Also, I need help getting screen names to work as well. Thanks.

As you will see, I attempted to add multiple connections myself... I failed. =[

I'm using VB6.

Code:Option Explicit
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
Private Const EM_LINESCROLL = &HB6
Dim ClientNum As Integer
Private Sub cmdSend_Click()
    Dim strdata As String
    strdata = "Server : " & txtmsg.Text
    tcpServer(0).SendData strdata
    Text1.Text = Text1.Text & strdata & vbCrLf
    txtmsg.Text = ""
    SendMessage Text1.hwnd, EM_LINESCROLL, 0, 10
End Sub

Private Sub Form_Load()
    Dim s As String
    s = InputBox("Server Port Number: ")
    tcpServer(0).Close
    tcpServer(0).LocalPort = s
    tcpServer(0).Listen
End Sub

Private Sub Form_Activate()
    txtmsg.SetFocus
End Sub

Private Sub tcpServer_ConnectionRequest(Index As Integer, ByVal requestID As Long)

    If Not tcpServer(0).State = sckConnected Then
        ClientNum = ClientNum + 1
        tcpServer(ClientNum).Close
        Load tcpServer(ClientNum)
        tcpServer(ClientNum).Accept requestID
        Text1.Text = "User has entered the server..." & vbCrLf
        SendMessage Text1.hwnd, EM_LINESCROLL, 0, 10
    End If
End Sub

Private Sub Form_Unload(Cancel As Integer)
    MsgBox "Wanna-Be AIM"
    tcpServer(0).Close
End Sub
Private Sub tcpServer_DataArrival(Index As Integer, ByVal bytesTotal As Long)
    Dim strdata As String

    tcpServer(0).GetData strdata
    Text1.Text = Text1.Text & strdata & vbCrLf
    SendMessage Text1.hwnd, EM_LINESCROLL, 0, 10
End Sub

Well - Citrix Server W / VB App And Access Backend
Anybody ever ran into the situation before? My IT Dpeatement want to put my app (stand-alone at the moment) on a Citrix server, and allow multiple users access. Other than making sure that my database connections/recordsets allow for multiple access, which other issues might I have to address?

SendData Works Only With Last Connected Client
Well i am trying to send data to all connected clients.But the winsock sends only to the last coneected client.

Dim i As Long
For i = 1 To Winsock.Ubound
If (Winsock(i).State = sckConnected) Then
Winsock(i).SendData "HelloWorld"
End If
Next i

Thanks

Displaying Images On Terminal Server Or Citrix
The refresh on these seems to be very slow. Has anybody had any experience with using images on a client running Terminal Services or Citrix

Installing VB Package On Citrix (2003) Server
Using the Package and Deploy wizard, I have made a package to install an
app I'm working with. I got the dreaded

"Setup cannot continue because some system files are out of date on your
system. Click OK if you would like setup to update these files for you
now. You will need to restart Windows before you can run setup again.
Click cancel to exit setup without updating system files. "

error, which I've seen before. (http://support.microsoft.com/kb/191096)
Of course, once you get this, it keeps saying the same thing after you
reboot, and never installs the program.

Usually it was caused by making a package on Win XP SP2 and trying to
install it on XP SP1. Upgrade the offending computer to SP2, and away it
went. However, this time I am trying to install the package on a Citrix
server with Windows Server 2003 (SP1 I believe) and I am getting the exact
same error. I made sure the correct version of MDAC was included, and
tried all the other suggestions, but to no avail. Someone I work with
said they remember it happening before and it was a DLL that wasn't
necessary, and once they took that out of the install package, it worked
fine, but I can't seem to find out which one. I can't find any other info
besides basically what is in the KB article above.

Has anyone ran into this and found a fix?

Thanks!
-Al

Is It Possible To Run Visual Source Safe On A Citrix Terminal Server?
Hello All!

I have a question concerning VSS: can this be run off a CItrix terminal Server?

All help is most welcome


Best regards

RoyM

Winsock Adding Clients Connected To Client List
Ok well the simplest way to do this I thought was when the sentdata of users names was received by a client, the client would remove all the users in the user list box, then update every few seconds and add all the clients connected to the server. However I know this isn't very smart if the server were to have a lot of clients connected. I was trying to figure out a method to compare the user list with the received data of connected users. All I could think of was to array all the clients in the list box, then compare that with all the clients from the server, and then add or remove users. But I wasn't entirely seeing how to write that out. If there is a better way to do this, please, I'll take it lol Would be very helpful. Here is what I was doing below... (Trying to compare the listbox array (Local) with the getdata (Remote))


Code:
'Now Collect All Clients In Client List
Dim ClientNamesToAdd() As String
ReDim ClientNamesToAdd(0 To ClientList.ListCount - 1)
For AllInClientList = 0 To ClientList.ListCount - 1
ClientNamesToAdd(AllInClientList) = ClientList.List(AllInClientList)
Next

'Compare Clients With Client Data Arrived
Dim ClientAlreadyInList As Boolean
Dim CompareArray1 As Long
Dim CompareArray2 As Long
For CompareArray1 = 0 To UBound(ClientNamesToAdd)
For CompareArray2 = 0 To UBound(ClientArrayNames)
If ClientNamesToAdd(CompareArray1) = ClientArrayNames(CompareArray2) Then
ClientAlreadyInList = True '(Code maybe here or after this section
' for add or removing items from client listbox.)
Else
End If
Next
Next

Is User Connected ???
Hi all,
Is there any API to which I pass User name and it will return the status whether particular user is connected to this server or not?

Any suggestions will be of great help.

Getting The NT Domain For The Connected User
Ok. I have managed to use the GetUserName API to retrieve the user who is currently logged into Windows NT.

Now I need to get the Domain that they logged in with.

I know there exists a function LookupAccountSID that can retrieve it for me but all the examples are in C... was wondering if anyone knew of one in VB so I don't have to waste time converting it all.

Thanks in advance

Check If User Is Connected To The Internet
How to check if user is connected to the internet.
(supports <dial up> Modem, Lan, DSL, Cable Modem, Internet Receiver Card<+Dish> etc...)
Regards.

User Are Connected To Database Access2000
Hi all,

I wonder if there is a way to disconnect all user from my database.
Thats the situation : I have a database that needs to be updtaed twice a week, means all data are going to be removed and new data are put inmto the database. To perform this action the DB shouldn't be accessed by anyone at this time. The bad thing is my guy's access it 24/7 and they are even lazier then I am so they just don't close the db they just lock their machines and go home. I found a nice articel in the techpages to determine who is connected, one point for me. But this is a pretty large building and I'm not interested to run twice a week thru it to shutdown 5 or 6 pc's. ok i could log them off remotely but that may cause some lose of data.
So my question is is there a way to disconnect them all at once ?

Thanks in advance
Mike

Is Access Client Server?? What Is Client Server?
If I use visual basic to query an Access 97 database, this is what I find:

The SQL query only selects one number from a large table - ie the total info required is 4 bytes.

However, when I analyse the network traffic to my computer I find that 17,000 bytes get downloaded when running this query.

I am using ADODb connections and coding them manually in visual basic. I do not know if this is relevant, but my question is:

I thought using client server that all that went up the wire was the SQL statement and all that went down the wire was the resultant data.

Is this just Access? Does a query have a minimum package of 17,000 bytes? Anything I can do to make the performance better (as my application has to run over a 56K line)?

What about if I used SQL server?

Object Is Not Connected To Server
I get the following error when I try to run an executable:

Run-time error '-2147220995 (800401fd)':

Automation Error
Object is not connected to server


Anyone any ideas?

Checking To See If I'm Connected To Server
I want my VB application to see if my Winsock control is connected to a server than sendthedata but if it isn't display a message box saying that your not connected.
I know how to do the sending data and displaying the message box. The only problem is the checking to see if the app is connected to the server.

Thanx,
Ben

Get Client Information
Hi people,
I want to make a simulation of the clients that a re currently logged on to the LAN similar as for instance when on loggs in to the yahoo messenger his status is popped up like "xyz is now on line".
same way i want that the server is going to be on,now when a client loggs on his status should be popped. Similarly when the admin makes a broadcast that who all r up the list should also be displayed.
Expecting for some assistance in VB6 .
Thanx in adv.
Any e.g. will be appreciated .
--saurabh.

ODBC Error:[Microsoft][ODBC SQL Server][SQL Server]Server User Not A Valid User
I have been facing a problem with Crystal Sub Reports.
In my Report I am using SQL Server Data base. The report contains main report and a sub report.
I am connecting to the database 'masstest'. The report is working fine on 'masstest' Database . If I change to connect
'masstetdump' database, the report is not executed showing an error , ODBC error:[Microsoft][ODBC SQL Server][SQL Server]Server user 'masstetdump' is not a valid user in database 'masstest' .
If I remove the Subreport then the report is working well on any database. The problem is only with sub report.

any body please help me.

How To Share Database Connected To VB User Interface:urgent
Hi,
I am new here , actually I registerd coz I have this question ^.^ , I dunna if this is the correct place but I hope u will help me
I want to implement a software connected with database, I will use vb6 and MS access as database , I want to install the software after it finish to five pcs connected to the same newtwork. The problem that ,if I make any change in database or if I insert a new data into database, i want to make sure that other pcs will have the last change ( up to data with the changes) without need to go to each pc and insert the data. I need some sycnorization so the change will happen to all pcs. I hope u understand me

P.S: I am not influent english speaker so sorry for any mistake

(+_+!)

Want To Restrict User To Connect Internet When Computer Is Connected
I am working with visual basic programming and want to restrict users to connect internet if computer is connected to internet.
i want to make a application when i permit a user than only he/she can use the internet facility.
so if you know what API used for this application then tell me.
thanx

*** How To Determine Computers Connected To A Server ***
Hi to all!!! i would make an application that displays in a combo or a listbox the name of the workstations connected to a workgroup...

e.g. i have a workgroup called "work" and many clients called client1work / client2work / client3work etc...
i wanna to displays a list of these computers in a combobox or a listbox...

can u help me?

pleaseee


TIA

simons

Search Form Connected To SQL Server
Hi

Nothing really is happening when i click on the search button in my form

THe form has 6 text box, the first 3 text boxes are linked to specific column and the last 3 text boxes the user can search for any information for that table specific.

Everything i search for an ID nothign happens. Can someone please help.


VB Code:
Option Explicit Private rsSearch As ADODB.RecordsetPrivate conSQL As ADODB.Connection Private Sub frmHandsetSearch_Load()        LoadTheGrid "SELECT * FROM Handsets"End Sub Private Function GetRecordset(ByVal strSQL1 As String) As ADODB.Recordset                Set conSQL = New ADODB.Connection     Dim strSQLServer As String    Dim strSQLDatabaseToOpen As String    Dim strConnectString As String    Dim rsRecords As ADODB.Recordset         strSQLServer = "sfdaqsql1"        strSQLDatabaseToOpen = "techlog_copy"        strConnectString = "Provider=sqloledb;" & _               "Integrated Security=SSPI;" & _               "Data Source=" & strSQLServer & ";" & _               "Initial Catalog=" & strSQLDatabaseToOpen & ";"                 conSQL.CursorLocation = adUseClient                                conSQL.Open (strConnectString)                Set rsSearch = New ADODB.Recordset                rsSearch.CursorLocation = adUseClient                                  Set rsSearch = conSQL.Execute(strSQL1)                'rsSearch.Close            Set rsSearch.ActiveConnection = Nothing                conSQL.Close            Set GetRecordset = rsSearchEnd Function Private Sub LoadTheGrid(ByVal strSQL1 As String)    Dim rs As ADODB.Recordset    Dim iCol As Integer, iRow As Integer    Dim fld As ADODB.Field        Set rs = GetRecordset(strSQL1)            iRow = 0        Me.MSFlexGrid1.Rows = rs.RecordCount        Me.MSFlexGrid1.Cols = rs.Fields.Count        Do Until rs.EOF            iCol = 0        For Each fld In rs.Fields            If IsNull(fld.Value) = True Then                Me.MSFlexGrid1.TextMatrix(iRow, iCol) = vbNullString            Else                Me.MSFlexGrid1.TextMatrix(iRow, iCol) = fld.Value            End If                iCol = iCol + 1                Next fld                iRow = iRow + 1                rs.MoveNext                Loop '                With Me.MSFlexGrid1'                    .ColWidth(0) = 3000'                    .ColWidth(1) = 3000'                    .ColWidth(2) = 3000'                    .ColWidth(3) = .Width - 8000''                    .Row = 0'                    .Text = "abcd"'                    .Col = 1'                    .Text = "Handset Date"'                    .Col = 2'                    .Text = "Telephia_Asset_Number"'                    .Col = 3'                    .Text = "ESN"'                    .Col = 4'                    .Text = "SIM_ID"'                    .Col = 5'                    .Text = "Min"'                    .Col = 6'                    .Text = "Phone_Plan"'                    .Col = 7'                    .Text = "Phone_Minutes"'                    .Col = 8'                    .Text = "Type"'                    .Col = 9'                    .Text = "Model"'                    .Col = 10'                    .Text = "Carrier"'                    .Col = 11'                    .Text = "Unit"'                    .Col = 12'                    .Text = "City Activation"'                    .Col = 13'                    .Text = "Cost"'                    .Col = 14'                    .Text = "Andrew RGA"'                    .Col = 15'                    .Text = "DT For Qualification"'                    .Col = 16'                    .Text = "DT Qualified"'                    .Col = 17'                    .Text = "D Dispatched"'                    .Col = 18'                    .Text = "Market"'                    .Col = 19'                    .Text = "DT Shipped"'                    .Col = 20'                    .Text = "DT Returned"'                    .Col = 21'                    .Text = "Date_purchased"'                    .Col = 22'                    .Text = "Status"'                    .Col = 23'                    .Text = "Type_mobile_test"'                    .Col = 24'                    .Text = "PO_number"'                    .Col = 25'                    .Text = "Comments"'                End WithEnd Sub Private Sub cmdSearch_Click() Dim strSQL1 As String, strWhere As StringstrSQL1 = "SELECT * FROM Handsets" If Text1.Text <> vbNullString Then    strWhere = strWhere & " AND [Telephia_Asset_Number_Handset] LIKE '" & Text1.Text & "*'"End IfIf Text2.Text <> vbNullString Then    strWhere = strWhere & " AND [ESN] LIKE """ & Text2.Text & "%"""End IfIf Text3.Text <> vbNullString Then    strWhere = strWhere & " AND [MIN] LIKE """ & Text3.Text & "%"""End If'If Text4.Text <> vbNullString Then'    strWhere = strWhere & " AND [Keyword LIKE """ & Text4.Text & "*"""'End If'If Text5.Text <> vbNullString Then'    strWhere = strWhere & " AND [Location In Unit] LIKE """ & Text5.Text & "*"""'End IfIf strWhere <> vbNullString Then    strSQL1 = strSQL1 & " WHERE " & Mid$(strWhere, 5)End IfLoadTheGrid (strSQL1)Debug.Print strSQL1End Sub Private Sub frmSearch_Unload(Cancel As Integer)rsSearch.CloseconSQL.CloseSet rsSearch = NothingSet conSQL = NothingEnd Sub


Thanks

ActiveReport W/ADO (by Code) Connected To SQL Server

I hope I can explain the issue I'm having suffiently ... in any case here it is:

I connected to the SQL server successfully but I'm having problems generating my reports anyway. And I suspect it's due to the & "" below ... but if I remove them I get an error too.

CODEField1.DataValue = !SumOfASal & ""
Field2.DataValue = !SumOfAAwd & ""
Field3.DataValue = !SumOfABen & ""
Field4.DataValue = !SumOfAOT & ""

Need Example Vb-source That Is Connected To Sql Server 2000
we are developing a desktop application for mutual funds, using VB-Access but the transactions are exceeding over lakhs of entries and that is why the system got slower, so we have decided to upgrade in sql server after 5 yrs, now i don't have any idea for the indexes that was we used in dao (existing) application.

e.g.,
in a dao application

rs.index = "<indexName>"
rs.seet "=", <key-value>

if rs.nomatch=false then
  ...
  ...
else
  ...
  ...
end if

the above e.g. is faster then the select query for lakhs of records in a table, but to perform such a fast activity i am not getting what to do with sql-server as dao not supported for sql-server.


thanks,

Check How Many Users That Are Connected To An SQL Server Database
Is there any way from VB code to check how many computers/users that are connected to an database on an SQL server 7.

I have a program that i have developed in VB that works against an SQL server. Now i want to implement an licens check, so if a customer has 5 license the program will only allow 5 simultanious users against the server.

Is there any easier/better way of solving this problem?
Thaks


5000 Computers All Connected To 1 Server Share Using Vb App
Hi, I have created a vb application, and I have 5,000 users using this application all at the same time...  Right now I have this application using:

if fso.fileexists(app.path & " est.txt") then 'etc

The application has a timer which runs every 30 seconds, and checks for this file using fso.. Well as you can imagine, it bogs down the server.  Normally the files test.txt is not there.. Its only there about 3 times a day.

Is there a better way to check for the existance of this file?  Can I have 5,000 computers monitoring the share for a newly created file called test.txt, or will this kill the server?

Thanks

Trouble Connecting From .NET 2.0 App On Win2000 Server Client To Remote SQL Server 2005 DB
Hi,

Has anyone experienced similar problems trying to connect under the stated configuration? Were you able to resolve?

This looks like some type of security or permissions issue on the client side but I don't know where to start looking. The login is correct and I don't have any issues when the client is XPSP2.

Additional info:

The Windows 2000 Server client is running SP4.
The 'Data Link' application used to configure the connection string from the client tests successfully.
Can't even connect as Administrator from the client.

Any guidance would be greatly appreciated.

Scott

Accessing Client Machine Information
i have a task in ASP , how can i get the client computer information as follows

1) Computer name of the client ( Not Done)

2) Host Name ( Done By Server Variable )

3) BIOS Info ( Not Done)

if any one have idea please give me reply as soon as possible

Thanks in advance

Jay





Retrieve Non-client Area Information.
I posted a question on how to get certain information, about objects in the non-client area (NCA), and found that no one had replied. Finally after much searching I found this code. I presume that this is not well known (since I didn't get any replies). However it is pretty useful when designing programs using skins.

This enables you to retrieve the standard scrollbar height and width, the forms border width, the height and width of the forms captions, the fonts of various parts of the NCA, and menu widths and heights.

First make a new class, called clsNCAInfo

Within it paste the following code:
Code: Private Const SPI_GETICONMETRICS = 45
Private Const SPI_GETICONTITLELOGFONT = 31
Private Const LF_FACESIZE = 32
Private Const LF_FULLFACESIZE = 64

' Normal log font structure:
Private Type LOGFONT
   lfHeight As Long
   lfWidth As Long
   lfEscapement As Long
   lfOrientation As Long
   lfWeight As Long
   lfItalic As Byte
   lfUnderline As Byte
   lfStrikeOut As Byte
   lfCharSet As Byte
   lfOutPrecision As Byte
   lfClipPrecision As Byte
   lfQuality As Byte
   lfPitchAndFamily As Byte
   lfFaceName(LF_FACESIZE) As Byte
End Type

Private Enum CNCMetricsFontWeightConstants
   FW_DONTCARE = 0
   FW_THIN = 100
   FW_EXTRALIGHT = 200
   FW_ULTRALIGHT = 200
   FW_LIGHT = 300
   FW_NORMAL = 400
   FW_REGULAR = 400
   FW_MEDIUM = 500
   FW_SEMIBOLD = 600
   FW_DEMIBOLD = 600
   FW_BOLD = 700
   FW_EXTRABOLD = 800
   FW_ULTRABOLD = 800
   FW_HEAVY = 900
   FW_BLACK = 900
End Enum

' For some bizarre reason, maybe to do with byte
' alignment, the LOGFONT structure we must apply
' to NONCLIENTMETRICS seems to require an LF_FACESIZE
' 4 bytes smaller than normal:

Private Type NMLOGFONT
   lfHeight As Long
   lfWidth As Long
   lfEscapement As Long
   lfOrientation As Long
   lfWeight As Long
   lfItalic As Byte
   lfUnderline As Byte
   lfStrikeOut As Byte
   lfCharSet As Byte
   lfOutPrecision As Byte
   lfClipPrecision As Byte
   lfQuality As Byte
   lfPitchAndFamily As Byte
   lfFaceName(LF_FACESIZE - 4) As Byte
End Type

Private Type NONCLIENTMETRICS
   cbSize As Long
   iBorderWidth As Long
   iScrollWidth As Long
   iScrollHeight As Long
   iCaptionWidth As Long
   iCaptionHeight As Long
   lfCaptionFont As NMLOGFONT
   iSMCaptionWidth As Long
   iSMCaptionHeight As Long
   lfSMCaptionFont As NMLOGFONT
   iMenuWidth As Long
   iMenuHeight As Long
   lfMenuFont As NMLOGFONT
   lfStatusFont As NMLOGFONT
   lfMessageFont As NMLOGFONT
End Type

Private Const SPI_GETNONCLIENTMETRICS = 41
Private Const SPI_SETNONCLIENTMETRICS = 42
Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, lpvParam As Any, ByVal fuWinIni As Long) As Long
Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" ( _
   lpvDest As Any, lpvSource As Any, ByVal cbCopy As Long)
Private Declare Function GetDeviceCaps Lib "gdi32" (ByVal hDC As Long, ByVal nIndex As Long) As Long
Private Const LOGPIXELSY = 90 ' Logical pixels/inch in Y
Private Declare Function CreateFontIndirect Lib "gdi32" Alias "CreateFontIndirectA" (lpLogFont As LOGFONT) As Long
Private Declare Function DeleteObject Lib "gdi32" (ByVal hObject As Long) As Long

Private m_tNCM As NONCLIENTMETRICS
Private m_tLF As LOGFONT

Public Enum CNCMetricsFontTypes
   IconFont = 1
   CaptionFont = 2
   SMCaptionFont = 3
   MenuFOnt = 4
   StatusFont = 5
   MessageFont = 6
End Enum

Public Function GetMetrics() As Boolean

Dim lR As Long
   ' Get Non-client metrics:
   m_tNCM.cbSize = 340
   lR = SystemParametersInfo( _
     SPI_GETNONCLIENTMETRICS, _
     0, _
     m_tNCM, _
     0)
   If (lR <> 0) Then
     ' Get icon font:
     lR = SystemParametersInfo( _
       SPI_GETICONTITLELOGFONT, _
       0, _
       m_tLF, _
       0)
     GetMetrics = (lR <> 0)
   End If
End Function

Property Get Font( _
     ByVal hDC As Long, _
     ByVal eFontNum As CNCMetricsFontTypes _
   ) As StdFont
Dim lR As Long
Dim tLF As LOGFONT

   Select Case eFontNum
   Case StatusFont
     CopyMemory tLF, m_tNCM.lfStatusFont, LenB(m_tNCM.lfStatusFont)
   Case SMCaptionFont
     CopyMemory tLF, m_tNCM.lfSMCaptionFont, LenB(m_tNCM.lfSMCaptionFont)
   Case MessageFont
     CopyMemory tLF, m_tNCM.lfMessageFont, LenB(m_tNCM.lfMessageFont)
   Case MenuFOnt
     CopyMemory tLF, m_tNCM.lfMenuFont, LenB(m_tNCM.lfMenuFont)
   Case IconFont
     CopyMemory tLF, m_tLF, LenB(m_tLF)
   Case CaptionFont
     CopyMemory tLF, m_tNCM.lfCaptionFont, LenB(m_tNCM.lfCaptionFont)
   Case Else
     Exit Property
   End Select

   ' This demonstrates how to return a VB style font.
   ' If you want an API hFont, just do this:
   ' hFont = CreateFontIndirect(tLF)
   ' Remember to use DeleteObject hFont when you've
   ' finished with it.
   Dim sFnt As New StdFont
   pLogFontToStdFont tLF, hDC, sFnt
   Set Font = sFnt

End Property

Private Sub pLogFontToStdFont(ByRef tLF As LOGFONT, ByVal hDC As Long, ByRef sFnt As StdFont)
   With sFnt
     .Name = StrConv(tLF.lfFaceName, vbUnicode)
     If tLF.lfHeight < 1 Then
       .Size = Abs((72# / GetDeviceCaps(hDC, LOGPIXELSY)) * tLF.lfHeight)
     Else
       .Size = tLF.lfHeight
     End If
     .Charset = tLF.lfCharSet
     .Italic = Not (tLF.lfItalic = 0)
     .Underline = Not (tLF.lfUnderline = 0)
     .Strikethrough = Not (tLF.lfStrikeOut = 0)
     .Bold = (tLF.lfWeight > FW_REGULAR)
   End With
End Sub

Property Get CaptionHeight() As Long
   CaptionHeight = m_tNCM.iCaptionHeight
End Property

Property Get CaptionWIdth() As Long
   CaptionWIdth = m_tNCM.iCaptionWidth
End Property

Property Get MenuHeight() As Long
   MenuHeight = m_tNCM.iMenuHeight
End Property

Property Get MenuWidth() As Long
   MenuWidth = m_tNCM.iMenuWidth
End Property

Property Get ScrollHeight() As Long
   ScrollHeight = m_tNCM.iScrollHeight
End Property

Property Get ScrollWidth() As Long
   ScrollWidth = m_tNCM.iScrollWidth
End Property

Property Get SMCaptionHeight() As Long
   SMCaptionHeight = m_tNCM.iSMCaptionHeight
End Property

Property Get SMCaptionWIdth() As Long
   SMCaptionWIdth = m_tNCM.iSMCaptionWidth
End Property

Property Get BorderWidth() As Long
   BorderWidth = m_tNCM.iBorderWidth
End Property


Now in your form add the following:
Code:Private NCAInf As clsNCAInfo

Private Sub Form_Load()
Set NCAInf = New clsNCAInfo
NCAInf.GetMetrics
End Sub

Now all you have to do is retrieve the values from NCAInf

Code:Private NCAInf As clsNCAInfo
Private SBWidth As Integer

Private Sub Form_Load()
Set NCAInf = New clsNCAInfo
NCAInf.GetMetrics

SBWidth = NCAInf.ScrollWidth
End Sub

Hope this is of some help to someone out there... I know it was a big help to me!


Twisted|Soul

Transcending even the highest forms of digital spirituality.

Telnet Server, RF Client Bar Code Reader, Working With A VB Application Thin Client Application
> Hello To All,
>
> I need a little advice and direction.
>
> I trying to build and application where a RF (Radio Frequency 900mhz
> hand held Bar Code Reader) device would connect and enter and retrieve
> information from a VB application.
>
> Example of Screen:
> Updating Inventory:
>
> Invoice Number:_____________
>
> Part Number: _____________
>
> Quantity: _____________
>
> Press F2 to Save and Continue.
>
> How Do you build a Telnet or VT100 or VT220 Server application in VB
> that can create the Example and except the individual entries.
>
>
> The hand held device can connect to a server in Telnet (ANSI), but I
> just lost and can find anything solid on the web.
>
>
> Steven

Using Faxcomexlib To Create An XP Fax Client Using Windows 2003 Server As Fax Server
1) Can anyone help me clarify the syntax for computer name when the FaxServer and remoteFaxClient are deployed within a domain?

2) If item 1) above is not the problem then does anyone have suggestions on how to properly setup the Fax software (remote Fax Client and the Fax Server)?

The following code works fine for creating a local FAX Client on XP and Windows 2003 Server. However, I want to use the XP node as the Fax Client and the 2003 Server node as the FaxServer.

Whenever I try to use the XP node as the remote Fax Client ot the Windows 2003 Server FaxServer, I get the following error code:

Error -2147024894 (80070002)

This error occurs on the line where the faxjob is submitted. I get the same error on both fax sumissions (JOBID and sumbission without retrieving the JobID):
    'submit and get JovID
    JobID = objFaxDocument.ConnectedSubmit(objFaxServer)

    ' submit without retrieving the JobID
    'objFaxDocument.Submit (objFaxServer.ServerName)

I am wondering if I am using the correct name for the FaxServer. The computer name is "medserver" but the full name (path and computername) is "medserver.domain1.local". I tried using "\medserver", "//medserver", "\mdeserver.domain1", "\medserver.domeain1.local" and I still am not able to connect to the server and send the test fax. Using a blank name for the FaxServer "" or using the local computer name while running the Fax Client VB routine local to the Server works just fine. I get through the connection call but I get the 80070002 error when I submit the fax from a remote Fax Client to the FaxServer.

============================================

Private Sub cmd_SendFaxComEx_Click()
    Dim objFaxDocument As New FAXCOMEXLib.FaxDocument
    Dim objFaxServer As New FAXCOMEXLib.FaxServer
    Dim objSender As FaxSender
    Dim JobID As Variant
    
    strFaxNumber = Me.txt_toFaxNumber.Text 'Any valid faxphone#
    'strFileName ="C:Program DATA FilesVB TestsFax ClientHello World.doc"
    strFileName = Me.txt_attachment.Text 'Any valid text/fax file
    strFaxMachine = Me.txt_FaxServerName.Text 'FaxMachine Name = "\FaxServer"
    
    'Error handling
    On Error GoTo Error_Handler
    
    'Connect to the fax server
    objFaxServer.Connect strFaxMachine '"" for default
    
    'Set the fax body
    objFaxDocument.Body = strFileName '"c: empmsg.txt"
    
    'Name the document
    objFaxDocument.DocumentName = "TMR Test Fax"
    
    'Set the fax priority
    'objFaxDocument.Priority = fptHIGH
    
    'Add the recipient with the fax number 12225550100
    'objFaxDocument.Recipients.Add "12225550100", "Bud"
    objFaxDocument.Recipients.Add strFaxNumber, Me.txt_RecipientName
    
    'Choose to attach the fax to the fax receipt; set to false for no attachment
    objFaxDocument.AttachFaxToReceipt = True
    
    'Set the cover page type and the path to the cover page
    'objFaxDocument.CoverPageType = fcptSERVER
    'set objFaxDocument.Coverpage = fcptNONE for no coverpage
    objFaxDocument.CoverPage = "generic"
    
    'Provide the cover page note
    objFaxDocument.Note = "Here is the info you requested"
    
    'Provide the address for the fax receipt
    objFaxDocument.ReceiptAddress = "someone@example.com"
    
    'Set the receipt type to email
    'objFaxDocument.ReceiptType = frtMAIL
    
    'Specify that the fax is to be sent at a particular time
    'objFaxDocument.ScheduleType = fstSPECIFIC_TIME
    'CDate converts the time to the Date data type
    'objFaxDocument.ScheduleTime = CDate("4:35:47 PM")
    
    objFaxDocument.Subject = "Today's fax"
    
    'Set the sender properties. For the EMR this will be the Dr. Office Info.
    objFaxDocument.Sender.Title = "Dr"
    objFaxDocument.Sender.Name = "TMR"
    objFaxDocument.Sender.City = "Phoenix"
    objFaxDocument.Sender.State = "AZ"
    objFaxDocument.Sender.Company = "TMR"
    objFaxDocument.Sender.Country = "USA"
    objFaxDocument.Sender.Email = "Dr@TMR.com"
    objFaxDocument.Sender.FaxNumber = strFaxNumber
    objFaxDocument.Sender.HomePhone = "1-602-555-5555"
    objFaxDocument.Sender.OfficeLocation = "Downtown"
    objFaxDocument.Sender.OfficePhone = "1-602-555-5553"
    objFaxDocument.Sender.StreetAddress = "123 Main Street"
    objFaxDocument.Sender.Tsid = "Office fax machine"
    objFaxDocument.Sender.ZipCode = "12345"
    objFaxDocument.Sender.BillingCode = "23A54"
    objFaxDocument.Sender.Department = "TMR EMR"
    
    'Save sender information as default
    objFaxDocument.Sender.SaveDefaultSender
    
    'Submit the document to the connected fax server and get back the job ID.
    JobID = objFaxDocument.ConnectedSubmit(objFaxServer)
    
    'Use the following line to submit the fax document w/o getting a job ID.
    'objFaxDocument.Submit (objFaxServer.ServerName)
    
    MsgBox "The Job ID is :" & JobID(0)
    'Exit Sub
    objFaxServer.Disconnect
    
Error_Handler:
        'Implement error handling at the end of your subroutine. This implementation is for demonstration purposes
        'MsgBox "Error number: " & Hex(Err.Number) & ", " & Err.Description
        objFaxServer.Disconnect

End Sub

How To Fetch Ipaddress Of The Terminal As Soon It Is Connected To The Main Server.
i am working on vb and asp. using visual basic i have to fetch the ipaddresses of all the terminals connected to the main server as soon as they get connected.

Creating A Database To Store Client Information.
Hi I have created a database at work to store client information, I need a way to track who has logged into the database. Is there any way to log the computers name that logged in.

I also need to make a button that when clicked adds the next sequention number in a series IE the field is curretly at 12 and when clicked it moves to 13 then 14 ect...

Im using MS Access 2000 on windows XP.

Thanks so much.

Copyright © 2005-08 www.BigResource.com, All rights reserved