I don’t achieve to show notification on Windows and Sketchup 2025 .
This code show a notification on mac but not on PC.
I add a put to be sure to a a sketchup_extension
extensions = Sketchup.extensions
sketchup_extension = extensions.detect do |extension|
extension.name == ‘Addesign’
end
puts sketchup_extension
message =‘is it working ??’
@notification = UI::Notification.new(sketchup_extension, message)
@notification.show
Works for me. If it has no buttons it will be only one line and it may look like the status bar and the user may not notice it. I suggest to use an icon to make the notification more noticeable.
module Denis
extensions = Sketchup.extensions
message = "is it working ??"
@notification = UI::Notification.new(extensions[1], message)
@notification.on_accept("Okay") { puts "Okay was clicked" }
@notification.show
end
1 Like
I try you code on my pc, and it’s work but only the first time ? !
Works on my PC, repeatedly. (When copy/pasted into console.)
Correct. I did not code it to show multiple times.
Why would you wish it to show more than once?