Torna indietro   Hardware Upgrade Forum > Software > Programmazione

Lenovo IdeaPad Slim 3: un notebook Snapdragon X economico
Lenovo IdeaPad Slim 3: un notebook Snapdragon X economico
Forte della piattaforma Qualcomm Snapdragon X, il notebook Lenovo IdeaPad Slim 3 riesce a coniugare caratteristiche tecniche interessanti ad uno chassis robusto, con autonomia di funzionamento a batteria che va ben oltre la tipica giornata di lavoro. Un notebook dal costo accessibile pensato per l'utilizzo domestico o in ufficio, soprattutto con applicazioni native per architettura ARM
Recensione OnePlus Watch 3 43mm: lo smartwatch che mancava per i polsi più piccoli
Recensione OnePlus Watch 3 43mm: lo smartwatch che mancava per i polsi più piccoli
OnePlus risponde alle esigenze di chi cerca un dispositivo indossabile dalle dimensioni contenute con OnePlus Watch 3 43mm. La versione ridotta del flagship mantiene gran parte delle caratteristiche del modello maggiore, offrendo un'esperienza completa in un formato compatto. Il suo limite più grande è abbastanza ovvio: l'autonomia non è il punto di forza di questo modello, ma si raggiungono comodamente le due giornate piene con un uso normale.
BOOX Note Air4 C è uno spettacolo: il tablet E Ink con Android per lettura e scrittura
BOOX Note Air4 C è uno spettacolo: il tablet E Ink con Android per lettura e scrittura
BOOX Note Air4 C rappresenta l'ultima incarnazione della categoria dei tablet E Ink a colori di Onyx, e combina le prestazioni di un dispositivo Android con l'ottima tecnologia Kaleido 3 per il display. Con schermo da 10,3 pollici, un processore Qualcomm Snapdragon 750G e 6 GB di RAM, promette un'esperienza completa per lettura, scrittura e produttività. Il prezzo lo posiziona nel segmento premium, ma questo dispositivo è un vero spettacolo!
Tutti gli articoli Tutte le news

Vai al Forum
Rispondi
 
Strumenti
Old 01-01-2005, 03:03   #1
ax89
Senior Member
 
L'Avatar di ax89
 
Iscritto dal: Sep 2004
Messaggi: 2066
Domande di un neofita di Visual Basic 6.0

Salve a tutti.
Allora, dovrei fare queste due cose e mi servirebbe una mano di uno + bravo di me:

1) assegnare ad un CommandButton un link per compilare una e-mail con il campo "Oggetto:" già indicato dallo stesso programma VB. Se sono stato poco chiaro intendo una specie di a href="mailto:xxxxx@xxxx.xx" in html + una voce che riempie subito il campo "oggetto".

2)Leggere ed estrarre info dal registro di win.

Grazie a tutti per gli aiuti.
ax89 è offline   Rispondi citando il messaggio o parte di esso
Old 02-01-2005, 22:56   #2
matpez
Senior Member
 
L'Avatar di matpez
 
Iscritto dal: Aug 2002
Città: Biella
Messaggi: 1882
Mail:

Codice:
Private Const SW_SHOWNORMAL = 1

Private Declare Function ShellExecute Lib "Shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long


Call ShellExecute(0&, vbNullString, "mailto:" & sEmail & "?Subject=" & sSubject, vbNullString, "", SW_SHOWNORMAL)




Registro:
Codice:
'This program needs 3 buttons

Const REG_SZ = 1 ' Unicode nul terminated string
Const REG_BINARY = 3 ' Free form binary

'Tipi di primo livello per le chiavi del registro di configurazione
Public Enum RegKeyRootConstants
  HKEY_CLASSES_ROOT = &H80000000
  HKEY_CURRENT_USER = &H80000001
  HKEY_LOCAL_MACHINE = &H80000002
  HKEY_USERS = &H80000003
End Enum

Private Declare Function RegCloseKey Lib "advapi32.dll" (ByVal hKey As Long) As Long
Private Declare Function RegCreateKey Lib "advapi32.dll" Alias "RegCreateKeyA" (ByVal hKey As Long, ByVal lpSubKey As String, phkResult As Long) As Long
Private Declare Function RegDeleteValue Lib "advapi32.dll" Alias "RegDeleteValueA" (ByVal hKey As Long, ByVal lpValueName As String) As Long
Private Declare Function RegOpenKey Lib "advapi32.dll" Alias "RegOpenKeyA" (ByVal hKey As Long, ByVal lpSubKey As String, phkResult As Long) As Long
Private Declare Function RegQueryValueEx Lib "advapi32.dll" Alias "RegQueryValueExA" (ByVal hKey As Long, ByVal lpValueName As String, ByVal lpReserved As Long, lpType As Long, lpData As Any, lpcbData As Long) As Long
Private Declare Function RegSetValueEx Lib "advapi32.dll" Alias "RegSetValueExA" (ByVal hKey As Long, ByVal lpValueName As String, ByVal Reserved As Long, ByVal dwType As Long, lpData As Any, ByVal cbData As Long) As Long

Function RegQueryStringValue(ByVal hKey As Long, ByVal strValueName As String) As String
    Dim lResult As Long, lValueType As Long, strBuf As String, lDataBufSize As Long
    'retrieve nformation about the key
    lResult = RegQueryValueEx(hKey, strValueName, 0, lValueType, ByVal 0, lDataBufSize)
    If lResult = 0 Then
        If lValueType = REG_SZ Then
            'Create a buffer
            strBuf = String(lDataBufSize, Chr$(0))
            'retrieve the key's content
            lResult = RegQueryValueEx(hKey, strValueName, 0, 0, ByVal strBuf, lDataBufSize)
            If lResult = 0 Then
                'Remove the unnecessary chr$(0)'s
                RegQueryStringValue = Left$(strBuf, InStr(1, strBuf, Chr$(0)) - 1)
            End If
        ElseIf lValueType = REG_BINARY Then
            Dim strData As Integer
            'retrieve the key's value
            lResult = RegQueryValueEx(hKey, strValueName, 0, 0, strData, lDataBufSize)
            If lResult = 0 Then
                RegQueryStringValue = strData
            End If
        End If
    End If
End Function

Function GetString(hKey As Long, strPath As String, strValue As String)
    Dim Ret
    'Open the key
    RegOpenKey hKey, strPath, Ret
    'Get the key's content
    GetString = RegQueryStringValue(Ret, strValue)
    'Close the key
    RegCloseKey Ret
End Function

Sub SaveString(hKey As Long, strPath As String, strValue As String, strData As String)
    Dim Ret
    'Create a new key
    RegCreateKey hKey, strPath, Ret
    'Save a string to the key
    RegSetValueEx Ret, strValue, 0, REG_SZ, ByVal strData, Len(strData)
    'close the key
    RegCloseKey Ret
End Sub

Sub SaveStringLong(hKey As Long, strPath As String, strValue As String, strData As String)
    Dim Ret
    'Create a new key
    RegCreateKey hKey, strPath, Ret
    'Set the key's value
    RegSetValueEx Ret, strValue, 0, REG_BINARY, CByte(strData), 4
    'close the key
    RegCloseKey Ret
End Sub

Sub DelSetting(hKey As Long, strPath As String, strValue As String)
    Dim Ret
    'Create a new key
    RegCreateKey hKey, strPath, Ret
    'Delete the key's value
    RegDeleteValue Ret, strValue
    'close the key
    RegCloseKey Ret
End Sub

Private Sub Command1_Click()
    Dim strString As String
    'Ask for a value
    strString = InputBox("Please enter a value between 0 and 255 to be saved as a binary value in the registry.", App.Title)
    If strString = "" Or Val(strString) > 255 Or Val(strString) < 0 Then
        MsgBox "Invalid value entered ...", vbExclamation + vbOKOnly, App.Title
        Exit Sub
    End If
    'Save the value to the registry
    SaveStringLong HKEY_CURRENT_USER, "KPD-Team", "BinaryValue", CByte(strString)
End Sub

Private Sub Command2_Click()
    'Get a string from the registry
    Ret = GetString(HKEY_CURRENT_USER, "KPD-Team", "BinaryValue")
    If Ret = "" Then MsgBox "No value found !", vbExclamation + vbOKOnly, App.Title: Exit Sub
    MsgBox "The value is " + Ret, vbOKOnly + vbInformation, App.Title
End Sub

Private Sub Command3_Click()
    'Delete the setting from the registry
    DelSetting HKEY_CURRENT_USER, "KPD-Team", "BinaryValue"
    MsgBox "The value was deleted ...", vbInformation + vbOKOnly, App.Title
End Sub

Private Sub Form_Load()
    Command1.Caption = "Set Value"
    Command2.Caption = "Get Value"
    Command3.Caption = "Delete Value"
End Sub
__________________
"Analizzando e valutando ogni giorno tutte le idee, ho capito che spesso tutti sono convinti che una cosa sia impossibile, finchè arriva uno sprovveduto che non lo sa e la realizza!"
A. Einstein
matpez è offline   Rispondi citando il messaggio o parte di esso
 Rispondi


Lenovo IdeaPad Slim 3: un notebook Snapdragon X economico Lenovo IdeaPad Slim 3: un notebook Snapdragon X ...
Recensione OnePlus Watch 3 43mm: lo smartwatch che mancava per i polsi più piccoli Recensione OnePlus Watch 3 43mm: lo smartwatch c...
BOOX Note Air4 C è uno spettacolo: il tablet E Ink con Android per lettura e scrittura BOOX Note Air4 C è uno spettacolo: il tab...
Recensione Sony Xperia 1 VII: lo smartphone per gli appassionati di fotografia Recensione Sony Xperia 1 VII: lo smartphone per ...
Attenti a Poco F7: può essere il best buy del 2025. Recensione Attenti a Poco F7: può essere il best buy...
Google presenta i nuovi Pixel 10: con il...
Google lancia Pixel Watch 4 e altre novi...
Arriva la conferma: Xiaomi vuole vendere...
Workday vittima di attacco, penetrato un...
Italia e fotovoltaico, superati i 2 mili...
Qualcomm svela lo Snapdragon 7s Gen 4: b...
ROG Xbox Ally: svelata la data di uscita...
Meta porta il doppiaggio AI per i Reel d...
Gemini Storybook: la funzionalità che tr...
La storia di Nikola non è ancora ...
Capcom infiamma la Gamescom con Resident...
Effetti personalizzati e più cont...
Beyerdynamic presenta le nuove cuffie wi...
WhatsApp Android Beta: test per i link v...
Dawn of War IV riportato in vita: il leg...
Chromium
GPU-Z
OCCT
LibreOffice Portable
Opera One Portable
Opera One 106
CCleaner Portable
CCleaner Standard
Cpu-Z
Driver NVIDIA GeForce 546.65 WHQL
SmartFTP
Trillian
Google Chrome Portable
Google Chrome 120
VirtualBox
Tutti gli articoli Tutte le news Tutti i download

Strumenti

Regole
Non Puoi aprire nuove discussioni
Non Puoi rispondere ai messaggi
Non Puoi allegare file
Non Puoi modificare i tuoi messaggi

Il codice vB è On
Le Faccine sono On
Il codice [IMG] è On
Il codice HTML è Off
Vai al Forum


Tutti gli orari sono GMT +1. Ora sono le: 19:51.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Served by www3v